DefaultSplitClient class

Implemented types

Constructors

DefaultSplitClient(SplitioPlatform _platform, String _matchingKey, String? _bucketingKey)

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

clearAttributes() Future<bool>
Removes all bound attributes.
override
destroy() Future<void>
Removes the client from memory and stops its synchronization tasks.
override
flush() Future<void>
Forces the client to upload all queued events and impressions.
override
getAttribute(String attributeName) Future
Retrieves an attribute previously saved.
override
getAttributes() Future<Map<String, dynamic>>
Retrieves a Map of every attribute currently bound. Keys are attribute names, and values their respective values.
override
getTreatment(String featureFlagName, [Map<String, dynamic> attributes = const {}]) Future<String>
Performs an evaluation for the featureFlagName feature flag.
override
getTreatments(List<String> featureFlagNames, [Map<String, dynamic> attributes = const {}]) Future<Map<String, String>>
Convenience method to perform multiple evaluations. Returns a Map in which the keys are feature flag names and the values are treatments.
override
getTreatmentsByFlagSet(String flagSet, [Map<String, dynamic> attributes = const {}]) Future<Map<String, String>>
Convenience method to perform multiple evaluations by flag set. Returns a Map in which the keys are feature flag names and the values are treatments.
override
getTreatmentsByFlagSets(List<String> flagSets, [Map<String, dynamic> attributes = const {}]) Future<Map<String, String>>
Convenience method to perform multiple evaluations by flag sets. Returns a Map in which the keys are feature flag names and the values are treatments.
override
getTreatmentsWithConfig(List<String> featureFlagNames, [Map<String, dynamic> attributes = const {}]) Future<Map<String, SplitResult>>
Convenience method to perform multiple evaluations. Returns a Map in which the keys are feature flag names and the values are SplitResult objects.
override
getTreatmentsWithConfigByFlagSet(String flagSet, [Map<String, dynamic> attributes = const {}]) Future<Map<String, SplitResult>>
Convenience method to perform multiple evaluations by flag set. Returns a Map in which the keys are feature flag names and the values are SplitResult objects.
override
getTreatmentsWithConfigByFlagSets(List<String> flagSets, [Map<String, dynamic> attributes = const {}]) Future<Map<String, SplitResult>>
Convenience method to perform multiple evaluations by flag sets. Returns a Map in which the keys are feature flag names and the values are SplitResult objects.
override
getTreatmentWithConfig(String featureFlagName, [Map<String, dynamic> attributes = const {}]) Future<SplitResult>
Performs and evaluation and returns a SplitResult object for the featureFlagName feature flag. This object contains the treatment alongside the feature flag's configuration, if any.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeAttribute(String attributeName) Future<bool>
Removes a specific attribute from storage.
override
setAttribute(String attributeName, dynamic value) Future<bool>
Stores a custom attribute value to be used in all evaluations.
override
setAttributes(Map<String, dynamic> attributes) Future<bool>
Stores a set of custom attributes to be used in all evaluations.
override
toString() String
A string representation of this object.
inherited
track(String eventType, {String? trafficType, double? value, Map<String, dynamic> properties = const {}}) Future<bool>
Enqueue a new event to be sent to Split data collection services.
override
whenReady() Future<SplitClient>
Returns Future that is completed when the most up-to-date information has been retrieved from the Split cloud.
override
whenReadyFromCache() Future<SplitClient>
Returns Future that is completed once the SDK has been able to load definitions from cache. This information is not guaranteed to be the most up-to-date, but all the functionality will be available.
override
whenTimeout() Future<SplitClient>
Returns Future that is completed if the SDK has not been able to get ready in time.
override
whenUpdated() Stream<SplitClient>
Returns Future that is completed when changes have been made, such as creating new feature flags or modifying segments.
override

Operators

operator ==(Object other) bool
The equality operator.
inherited