Documentation ¶
Index ¶
- func ClarityTypeToClarityValue(descriptor ClarityTypeDescriptor, value interface{}) (clarity.ClarityValue, error)
- type ABI
- type Argument
- type BufferDescriptor
- type ClarityTypeDescriptor
- type Function
- type ListDescriptor
- type Map
- type OptionalDescriptor
- type OutputDescriptor
- type ResponseDescriptor
- type StringASCIIDescriptor
- type StringUTF8Descriptor
- type TraitReferenceDescriptor
- type TupleDescriptor
- type TupleField
- type Variable
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClarityTypeToClarityValue ¶
func ClarityTypeToClarityValue(descriptor ClarityTypeDescriptor, value interface{}) (clarity.ClarityValue, error)
Types ¶
type ABI ¶
type ABI struct { Maps []Map `json:"maps"` Epoch string `json:"epoch"` Functions []Function `json:"functions"` Variables []Variable `json:"variables"` ClarityVersion string `json:"clarity_version"` FungibleTokens []interface{} `json:"fungible_tokens"` NonFungibleTokens []interface{} `json:"non_fungible_tokens"` }
type Argument ¶
type Argument struct { Name string `json:"name"` Type ClarityTypeDescriptor `json:"type"` }
type BufferDescriptor ¶
type BufferDescriptor struct {
Length int `json:"length"`
}
type ClarityTypeDescriptor ¶
type ClarityTypeDescriptor struct { Raw json.RawMessage `json:"-"` StringASCII *StringASCIIDescriptor `json:"string-ascii,omitempty"` StringUTF8 *StringUTF8Descriptor `json:"string-utf8,omitempty"` Uint128 *struct{} `json:"uint128,omitempty"` Int128 *struct{} `json:"int128,omitempty"` Bool *struct{} `json:"bool,omitempty"` Buffer *BufferDescriptor `json:"buffer,omitempty"` Optional *OptionalDescriptor `json:"optional,omitempty"` List *ListDescriptor `json:"list,omitempty"` Tuple *TupleDescriptor `json:"tuple,omitempty"` Response *ResponseDescriptor `json:"response,omitempty"` Principal *struct{} `json:"principal,omitempty"` TraitReference *struct{} `json:"trait_reference,omitempty"` None *struct{} `json:"none,omitempty"` }
func (*ClarityTypeDescriptor) UnmarshalJSON ¶
func (c *ClarityTypeDescriptor) UnmarshalJSON(data []byte) error
type Function ¶
type Function struct { Args []Argument `json:"args"` Name string `json:"name"` Access string `json:"access"` Outputs OutputDescriptor `json:"outputs"` }
type ListDescriptor ¶
type ListDescriptor struct { Type ClarityTypeDescriptor `json:"type"` Length int `json:"length"` }
type Map ¶
type Map struct { Key ClarityTypeDescriptor `json:"key"` Name string `json:"name"` Value ClarityTypeDescriptor `json:"value"` }
type OptionalDescriptor ¶
type OptionalDescriptor struct {
Type ClarityTypeDescriptor `json:"type"`
}
func (*OptionalDescriptor) UnmarshalJSON ¶
func (o *OptionalDescriptor) UnmarshalJSON(data []byte) error
type OutputDescriptor ¶
type OutputDescriptor struct {
Type ClarityTypeDescriptor `json:"type"`
}
type ResponseDescriptor ¶
type ResponseDescriptor struct { Ok *ClarityTypeDescriptor `json:"ok,omitempty"` Error *ClarityTypeDescriptor `json:"error,omitempty"` }
type StringASCIIDescriptor ¶
type StringASCIIDescriptor struct {
Length int `json:"length"`
}
type StringUTF8Descriptor ¶
type StringUTF8Descriptor struct {
Length int `json:"length"`
}
type TraitReferenceDescriptor ¶
type TraitReferenceDescriptor struct { }
type TupleDescriptor ¶
type TupleDescriptor struct {
Fields []TupleField `json:"tuple"`
}
type TupleField ¶
type TupleField struct { Name string `json:"name"` Type ClarityTypeDescriptor `json:"type"` }
type Variable ¶
type Variable struct { Name string `json:"name"` Type ClarityTypeDescriptor `json:"type"` Access string `json:"access"` }
Click to show internal directories.
Click to hide internal directories.