Documentation ¶
Index ¶
Constants ¶
View Source
const ( MaxMessageSize = 24 * units.KiB // Note: Modifying this variable can have subtle implications on memory // usage when parsing malformed payloads. MaxSliceLen = 24 * 1024 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddressedCall ¶
type AddressedCall struct { SourceAddress []byte `serialize:"true"` Payload []byte `serialize:"true"` // contains filtered or unexported fields }
AddressedCall defines the format for delivering a call across VMs including a source address and a payload.
Note: If a destination address is expected, it should be encoded in the payload.
func NewAddressedCall ¶
func NewAddressedCall(sourceAddress []byte, payload []byte) (*AddressedCall, error)
NewAddressedCall creates a new *AddressedCall and initializes it.
func ParseAddressedCall ¶
func ParseAddressedCall(b []byte) (*AddressedCall, error)
ParseAddressedCall converts a slice of bytes into an initialized AddressedCall.
func (*AddressedCall) Bytes ¶
func (a *AddressedCall) Bytes() []byte
Bytes returns the binary representation of this payload. It assumes that the payload is initialized from either NewAddressedCall or Parse.
Click to show internal directories.
Click to hide internal directories.