Constructs a new TransformKind
instance.
The transformation data as a string.
Private
dataGetter for transformation data.
The transformation data.
Private
containsRecursively checks if any key in the provided object (including nested objects) contains the specified name.
true if a key containing the name is found; otherwise, false.
The object to search through.
The transformation name to search for within the keys.
Attempts to parse the transformation as a UInt512.
A CLValueUInt512
object if the data matches, otherwise throw an error
.
Attempts to parse the transformation data as a WriteAccount transformation.
This method supports two JSON formats:
2.x Format:
{
"Write": {
"Account": {
"account_hash": "..."
}
}
}
If the parsed accountHash
is not equal to the zero account hash, this value is returned.
1.x Format:
{
"WriteAccount": "..."
}
If the 2.x format is not matched or the parsed account hash equals the zero hash, the method falls back to this format.
The parsed AccountHash
.
Error if the transformation data cannot be parsed as a valid WriteAccount.
Attempts to parse the transformation as a WriteAddressableEntity.
An AddressableEntity
object if the data matches, otherwise throw an error`.
Attempts to parse the transformation as a WriteContractPackage.
A ContractPackage
object if the data matches, otherwise throw an error
.
Attempts to parse the transformation as a WriteDeployInfo.
A DeployInfo
object if the data matches, otherwise throw an error
.
Attempts to parse the transformation as a WriteMessageTopic.
A MessageTopicSummary
if the data matches, otherwise throw an error
.
Attempts to parse the transformation as a WriteNamedKey.
A NamedKeyKind
object if the data matches, otherwise throw an error
.
Attempts to parse the transformation as a WriteUnbonding.
An array of UnbondingPurse
objects if the data matches, otherwise throw an error
.
Attempts to parse the transformation as a WriteWithdraw.
An array of UnbondingPurse
objects if the data matches, otherwise []
.
Static
fromJSONCreates a TransformKind
instance from a JSON string.
The TransformKind
instance.
The transformation data as a string.
Generated using TypeDoc
Represents different types of transformation that can be applied. Used for parsing and processing transformation data in a transaction.