Package com.zendesk.sdk.storage
Interface SdkStorage
-
public interface SdkStorageProvides a way of accessing all of theSdkStorage.UserStorageclasses that the SDK uses.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface and Description static interfaceSdkStorage.UserStorageDefines behaviour for SDK storage of user data
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description voidclearUserData()Clears user data from storage.java.util.Set<SdkStorage.UserStorage>getUserStorage()Gets an unmodifiable version of the UserStoragevoidregisterUserStorage(SdkStorage.UserStorage userStorage)Registers additional user storage providers with SdkStorage.
-
-
-
Method Detail
-
registerUserStorage
void registerUserStorage(SdkStorage.UserStorage userStorage)
Registers additional user storage providers with SdkStorage.Additional storage providers should be registered if they are defined outside the scope of the ZendeskProviders project.
Duplicate storage providers will not be registered. If a duplicate type of storage, as determined by
firstClass.getClass().equals(secondClass.getClass), is provided then firstClass' storage will be cleared and it will be replaced in the set of UserStorage by the secondClass.- Parameters:
userStorage- The storage to register
-
clearUserData
void clearUserData()
Clears user data from storage.This will only clear data that is associated with a user. Settings like
SdkSettingsare an example of something that won't be cleared butRequestStoragewill be cleared because that is from a user.
-
getUserStorage
java.util.Set<SdkStorage.UserStorage> getUserStorage()
Gets an unmodifiable version of the UserStorage- Returns:
- An unmodifiable version of the UserStorage
-
-