UserDefaults

extension UserDefaults
  • Undocumented

    See more

    Declaration

    Swift

    @propertyWrapper
    open class Binding<Value> where Value : Decodable, Value : Encodable
    extension UserDefaults.Binding: ObservableObject
  • Key

    Undocumented

    See more

    Declaration

    Swift

    public struct Key<Value> : Hashable, Equatable, RawRepresentable where Value : Decodable, Value : Encodable
  • Undocumented

    Declaration

    Swift

    open func ridi_object<T>(forKey defaultName: String) throws -> T? where T : Decodable
  • Undocumented

    Declaration

    Swift

    open func ridi_set<T>(_ value: T?, forKey defaultName: String) throws where T : Encodable
  • Undocumented

    Declaration

    Swift

    open func ridi_object<T>(forKey key: Key<T>) throws -> T where T : Decodable, T : Encodable
  • Undocumented

    Declaration

    Swift

    open func ridi_set<T>(_ value: T?, forKey key: Key<T>) throws where T : Decodable, T : Encodable
  • Undocumented

    Declaration

    Swift

    open subscript<T>(key: Key<T>) -> T? where T : Decodable, T : Encodable { get set }
  • Undocumented

    Declaration

    Swift

    open func ridi_removeObject<T>(forKey key: Key<T>) where T : Decodable, T : Encodable
  • Undocumented

    Declaration

    Swift

    open func ridi_objectIsForced<T>(forKey key: Key<T>) -> Bool where T : Decodable, T : Encodable
  • Undocumented

    Declaration

    Swift

    open func ridi_objectIsForced<T>(forKey key: Key<T>, inDomain domain: String) -> Bool where T : Decodable, T : Encodable
  • Undocumented

    See more

    Declaration

    Swift

    public struct KeyValueObservedChange<Value> where Value : Decodable, Value : Encodable
  • Undocumented

    See more

    Declaration

    Swift

    public class KeyValueObservation<Value> : NSObject where Value : Decodable, Value : Encodable
  • Undocumented

    Declaration

    Swift

    public func observe<Value>(
        _ key: Key<Value>,
        options: NSKeyValueObservingOptions = [.new],
        changeHandler: @escaping (UserDefaults, KeyValueObservedChange<Value>) -> Void
    ) -> UserDefaults.KeyValueObservation<Value>