Skip to content

Instance Method

get(_:default:)

Gets a value from the Extend storage falling back to the default value if it does not exist or cannot be casted to T.
func get<T>(_ key: String, default d: T) -> T

Discussion

let foo: Foo = extend.get("foo", default: defaultFoo)