InternalSessionUtils class

Utility class for managing internal sessions using local storage and encryption.

Properties

encrypter → Encrypter
The encrypter used for encrypting and decrypting sensitive data.
final
hashCode int
The hash code for this object.
no setterinherited
iv → IV
The initialization vector (IV) used for encryption.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

decrypt(String input) String
Decrypts the given Base64 encoded input string using the specified initialization vector (iv).
deleteSession() Future<void>
Deletes the current session and resets campaign data.
encrypt(String input) String
Encrypts the given input string using the specified encrypter and IV (initialization vector).
getOrCreateSession() Future<InternalSession>
Retrieves an existing session or creates a new one if none exists.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
saveSession(InternalSession session, {required bool merge}) Future<void>
Saves the given session to the database.
setAnonymousId(String? anonId) Future<void>
Sets the anonymous ID for the current session and saves it.
setClientId(String clientId) Future<void>
Sets the client ID for the current session and saves it.
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

instance InternalSessionUtils
Returns the singleton instance of InternalSessionUtils.
no setter

Static Methods

initialize({required String appSecret, required String appId}) → void
Initializes the InternalSessionUtils with the provided appSecret and appId.