AiutaDataProvider class
Data provider to manage data of the Aiuta SDK.
This allows you to store and retrieve data (such as user consent, uploaded images, generation history) from your own data source. If not provided, the Aiuta SDK uses the built-in data provider that stores data in local storage on the device. Default data storage is not linked to the user and is not shared between different devices. Will be deleted when the app is uninstalled. Creating a custom data provider allows you to store data in your own data source and link it to the user.
- Annotations
-
- @JsonSerializable()
Constructors
-
AiutaDataProvider({required ValueListenable<
bool> isUserConsentObtained, required ValueListenable<List< uploadedImages, required ValueListenable<AiutaHistoryImage> >List< generatedImages, required AiutaDataListeners listeners})AiutaHistoryImage> > - Create a new instance of AiutaDataProvider.
-
AiutaDataProvider.fromJson(Map<
String, dynamic> json) -
Create a new instance of AiutaDataProvider from a json map.
factory
Properties
-
generatedImages
→ ValueListenable<
List< AiutaHistoryImage> > -
List of images generated by the Aiuta.
Images are displayed in the order as-is, without any sorting.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
isUserConsentObtained
→ ValueListenable<
bool> -
Indicates whether the user has given consent to use the Aiuta SDK.
final
- listeners → AiutaDataListeners
-
Listeners for various data events in the Aiuta SDK.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
uploadedImages
→ ValueListenable<
List< AiutaHistoryImage> > -
List of images uploaded by the user.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Convert this object to a json map.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited