@aldea/sdk / Exports / Instruction
Class: Instruction
Instruction base class.
An Instruction is Aldea's smallest contiguous unit of execution. A transaction consists of a OpCode
byte and a number of arguments, depending on the OpCode
.
Hierarchy
Instruction
Table of contents
Constructors
Properties
Methods
Constructors
constructor
• new Instruction(opcode
): Instruction
Parameters
Name | Type |
---|---|
opcode | OpCode |
Returns
Defined in
packages/core/dist/instruction.d.ts:27
Properties
opcode
• opcode: OpCode
Defined in
packages/core/dist/instruction.d.ts:26
Methods
toBytes
▸ toBytes(): Uint8Array
Returns
Uint8Array
Defined in
packages/core/dist/instruction.d.ts:29
fromBytes
▸ fromBytes(bytes
): Instruction
Parameters
Name | Type |
---|---|
bytes | Uint8Array |
Returns
Defined in
packages/core/dist/instruction.d.ts:28