StrictInjector
public struct StrictInjector<K> : InjectorDerivingFromMutableInjector where K : Hashable
A basic implementation of MutableInjector
that evaluates all factories on provide.
-
Declaration
Swift
public typealias Key = K
-
Creates an empty
StrictInjector
.Declaration
Swift
public init()
-
Declaration
Swift
public mutating func resolve(key: Key) throws -> Providable
-
Declaration
Swift
public mutating func provide( key: K, usingFactory factory: @escaping (inout StrictInjector) throws -> Providable )
-
Declaration
Swift
public mutating func revoke(key: K)
-
Declaration
Swift
public var providedKeys: [K] { get }