StorageCrypto Documentation

Structure Providers.​Lock

struct Lock<Key, Secret>: LockProvider  

A struct defining an instance abstracting a lock, a padlock, requiring some key to be opened.

%141 Providers.Lock Providers.Lock LockProvider LockProvider Providers.Lock->LockProvider

Member Of

Providers

A module-like enum listing all providers.

Conforms To

LockProvider

Initializers

init(_:​)

public init(_ content: @escaping (Key) -> Secret)  

Init.

Parameters

content @escaping (Key) -> Secret

The output factory.

Methods

unlock(with:​)

public func unlock(with key: Key) -> Secret  

Unlock the output.

Parameters

key Key

Some Key.

Returns

Some Secret.