getExposedInfo method
Implementation
FSExposedInfo? getExposedInfo() {
if (this.exposure_flag != null) {
// Create map for exposeFlag
Map mapFlag = json.decode(this.exposure_flag ?? "");
// create Expose Flag
var p1 = ExposedFlag(mapFlag["key"], mapFlag["value"],
mapFlag["defaultValue"], FlagMetadata.withMap(mapFlag["metadata"]));
if (this.exposure_visitor != null) {
// Create map for visitor expose
Map mapVisitorExposure = json.decode(this.exposure_visitor ?? "");
// Create visitor Expose
var p2 = VisitorExposed(mapVisitorExposure["id"],
mapVisitorExposure["anonymousId"], mapVisitorExposure["context"]);
// Return the final object
return FSExposedInfo(exposedFlag: p1, visitorExposed: p2);
}
}
return null;
}