UserDefaultsMonitor
public class UserDefaultsMonitor : BaseNotificationMonitor
A UserDefaultsMonitor instance monitors a user defaults object for
changes to its data.
-
Encapsulates changes to the user defaults object.
See moreDeclaration
Swift
public enum Event -
Specifies which events to monitor.
See moreDeclaration
Swift
public struct Options : OptionSet -
Initializes a new
UserDefaultsMonitor.Declaration
Parameters
userDefaultsThe user defaults object to monitor.
optionsThe options that specify which events to monitor. By default, all events are monitored.
queueThe operation queue on which the handler executes. By default, the main operation queue is used.
handlerThe handler to call when the user defaults object is changed within the current process or more data is stored in the object than is allowed.
-
Initializes a new
UserDefaultsMonitor. -
The user defaults object being monitored.
Declaration
Swift
public let userDefaults: UserDefaults -
Declaration
Swift
public override func addNotificationObservers()
View on GitHub
Install in Dash
UserDefaultsMonitor Class Reference