Builder

class Builder

A helper class for building a CompositeKey.

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
fun addKey(key: PublicKey, weight: Int = 1): CompositeKey.Builder

Adds a child CompositeKey node. Specifying a weight for the child is optional and will default to 1.

Link copied to clipboard
Link copied to clipboard
fun build(threshold: Int? = null): PublicKey

Builds the CompositeKey. If threshold is not specified, it will default to the total (aggregated) weight of the children, effectively generating an "N of N" requirement. During process removes single keys wrapped in CompositeKey and enforces ordering on child nodes.