Documentation
¶
Index ¶
Constants ¶
View Source
const ( ABIVersionMajor uint16 = 2 ABIVersionMinor uint16 = 0 SchemaHashLen = 32 )
Variables ¶
View Source
var ( ErrIncompatibleABIMajor = errors.New("incompatible ABI major version") ErrIncompatibleABIMinor = errors.New("incompatible ABI minor version") ErrSchemaHashMismatch = errors.New("schema hash mismatch") ErrCapabilityMismatch = errors.New("required capability not provided") ErrContractNameEmpty = errors.New("contract name cannot be empty") ErrContractHashEmpty = errors.New("contract schema hash cannot be zero") ErrMethodIDDuplicate = errors.New("method id is duplicated") ErrMethodNameDuplicate = errors.New("method name is duplicated") ErrMethodNameEmpty = errors.New("method name cannot be empty") ErrMethodRequestMissing = errors.New("method request type cannot be empty") ErrMethodReplyMissing = errors.New("method response type cannot be empty") )
Functions ¶
func ParseSchemaHashHex ¶
func ParseSchemaHashHex(s string) ([SchemaHashLen]byte, error)
func ValidateHandshake ¶
Types ¶
type Handshake ¶
type Handshake struct {
ABIMajor uint16
ABIMinor uint16
SchemaHash [SchemaHashLen]byte
Capabilities uint64
}
func NewHandshake ¶
func NewHandshake(schemaHash [SchemaHashLen]byte) Handshake
func (Handshake) SchemaHashHex ¶
Click to show internal directories.
Click to hide internal directories.