SynchronizedStorage
extension MoEngageStorage.SynchronizedStorage: MoEngageStorage.ReadOnlyLocation
where Location: MoEngageStorage.ReadOnlyLocation
extension MoEngageStorage.SynchronizedStorage: MoEngageStorage.WriteOnlyLocation
where Location: MoEngageStorage.WriteOnlyLocation
extension MoEngageStorage.SynchronizedStorage: MoEngageStorage.MigratableLocation
where Location: MoEngageStorage.MigratableLocation
extension MoEngageStorage.SynchronizedStorage: Equatable where Location: Equatable
extension MoEngageStorage.SynchronizedStorage: Hashable where Location: Hashable
-
Reads the wrapped location’s value inside the synchronisation lock.
Declaration
Swift
public func read( withInput input: Location.Input, fromInstance sdkInstance: isolated MoEngageSDKInstance = #isolation ) throws(Location.ReadError) -> Location.StoredParameters
inputUnused (
Void).sdkInstanceThe isolated SDK instance to read from.
Return Value
The stored value.
-
Writes to the wrapped location inside the synchronisation lock.
Declaration
Swift
public func write( _ value: Location.Saved, toInstance sdkInstance: isolated MoEngageSDKInstance = #isolation ) throws(Location.WriteError) -> Location.OutputParameters
valueThe value to persist.
sdkInstanceThe isolated SDK instance to write to.
-
Removes from the wrapped location inside the synchronisation lock.
Declaration
Swift
public func remove( fromInstance sdkInstance: isolated MoEngageSDKInstance = #isolation ) throws(Location.RemoveError) -> Location.RemoveOutputParameters
sdkInstanceThe isolated SDK instance to remove from.