Class OpcodeAssembler
OpcodeAssembler class, can be declared and inherit from a ProcessInfo object to inherit the values of the current process or be called as a static function to assemble instructions.
Inherited Members
Namespace: ERC.Utilities
Assembly: ERC.Net.dll
Syntax
public class OpcodeAssembler : ProcessInfo
Constructors
OpcodeAssembler(ProcessInfo)
Constructor.
Declaration
public OpcodeAssembler(ProcessInfo parent)
Parameters
Type | Name | Description |
---|---|---|
ProcessInfo | parent | ProcessInfo object to be inherited from. |
Methods
AssembleOpcodes(List<String>)
Takes either an array or list of strings containing assembly instructions and returns the associated opcodes.
Declaration
public ErcResult<byte[]> AssembleOpcodes(List<string> instructions)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.List<System.String> | instructions | The instructions to be assembled |
Returns
Type | Description |
---|---|
ErcResult<System.Byte[]> | Returns an ErcResult byte array containing the assembled instructions |
AssembleOpcodes(List<String>, MachineType)
Takes either an array or list of strings containing assembly instructions, a MachineType of I386 or x64, an instance of the ERC_Core object and returns the associated opcodes.
Declaration
public static ErcResult<byte[]> AssembleOpcodes(List<string> instructions, MachineType machineType)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.Generic.List<System.String> | instructions | The instructions to be assemble=d |
MachineType | machineType | a ERC.MachineType of either I386 or x64 |
Returns
Type | Description |
---|---|
ErcResult<System.Byte[]> | Returns an ERC_Result byte array containing the assembled instructions |