StateLib
bitcoinjs-lib / StateLib
Class: StateLib\<T>
Defined in: packages/scrypt-ts-btc/src/smart-contract/builtin-libs/stateLib.ts:11
Library for computing the hash of a state.
Onchain
Extends
Type Parameters
• T extends StructObject
Constructors
new StateLib()
new StateLib\<
T
>(...args
):StateLib
\<T
>
Defined in: packages/scrypt-ts-btc/src/smart-contract/smartContractLib.ts:29
Parameters
args
...SupportedParamType
[]
Returns
StateLib
\<T
>
Inherited from
Other
args
args:
any
[] =[]
Defined in: packages/scrypt-ts-btc/src/smart-contract/smartContractLib.ts:28
Inherited from
artifact
static
artifact:Artifact
Defined in: packages/scrypt-ts-btc/src/smart-contract/smartContractLib.ts:15
Inherited from
stateType?
static
optional
stateType:string
Defined in: packages/scrypt-ts-btc/src/smart-contract/smartContractLib.ts:16
Inherited from
loadArtifact()
static
loadArtifact(artifact
): typeofSmartContractLib
Defined in: packages/scrypt-ts-btc/src/smart-contract/smartContractLib.ts:18
Parameters
artifact
Returns
typeof SmartContractLib
Inherited from
State
stateHash()
static
stateHash\<ST
>(this
,state
):Ripemd160
Defined in: packages/scrypt-ts-btc/src/smart-contract/builtin-libs/stateLib.ts:19
Calculate the hash of the state object
Type Parameters
• ST extends StructObject
Parameters
this
(...args
) => StateLib
\<ST
>
state
ST
the state object
Returns
the hash byte string of the state object