Documentation ¶
Index ¶
- type CompositeType
- type Contract
- func (c *Contract) FlattenSubTypes()
- func (c *Contract) GetFields() []Field
- func (c *Contract) GetFunctions() []Function
- func (c *Contract) GetGoName() string
- func (c *Contract) GetName() string
- func (c *Contract) GetSimpleName() string
- func (c *Contract) GetSubTypes() []CompositeType
- func (c *Contract) Kind() common.CompositeKind
- func (c *Contract) SetFields(fields []Field)
- func (c *Contract) SetFunctions(fns []Function)
- func (c *Contract) SetName(n string)
- func (c *Contract) SetOwnerType(owner string)
- func (c *Contract) SetSubTypes(sb []CompositeType)
- type Event
- func (c *Event) GetFields() []Field
- func (c *Event) GetFunctions() []Function
- func (e *Event) GetGoName() string
- func (c *Event) GetName() string
- func (c *Event) GetSimpleName() string
- func (c *Event) GetSubTypes() []CompositeType
- func (*Event) Kind() common.CompositeKind
- func (c *Event) SetFields(fields []Field)
- func (c *Event) SetFunctions(fns []Function)
- func (c *Event) SetName(n string)
- func (c *Event) SetOwnerType(owner string)
- func (c *Event) SetSubTypes(sb []CompositeType)
- type Field
- type FlowJson
- type Function
- func (fn *Function) AddUsedCommaAuth() int
- func (fn *Function) AddUsedCommaCommon() int
- func (fn *Function) AuthorizerCount() int
- func (fn *Function) CommaCountAll() int
- func (fn *Function) CommaCountAuth() int
- func (fn *Function) CommaCountCommon() int
- func (fn *Function) GenCadenceScript() (string, error)
- func (fn *Function) IsReturnMap() bool
- type FunctionParam
- type Resource
- func (c *Resource) GetFields() []Field
- func (c *Resource) GetFunctions() []Function
- func (r *Resource) GetGoName() string
- func (c *Resource) GetName() string
- func (c *Resource) GetSimpleName() string
- func (c *Resource) GetSubTypes() []CompositeType
- func (r *Resource) Kind() common.CompositeKind
- func (c *Resource) SetFields(fields []Field)
- func (c *Resource) SetFunctions(fns []Function)
- func (c *Resource) SetName(n string)
- func (c *Resource) SetOwnerType(owner string)
- func (c *Resource) SetSubTypes(sb []CompositeType)
- type Struct
- func (c *Struct) GetFields() []Field
- func (c *Struct) GetFunctions() []Function
- func (s *Struct) GetGoName() string
- func (c *Struct) GetName() string
- func (c *Struct) GetSimpleName() string
- func (c *Struct) GetSubTypes() []CompositeType
- func (s *Struct) Kind() common.CompositeKind
- func (c *Struct) SetFields(fields []Field)
- func (c *Struct) SetFunctions(fns []Function)
- func (c *Struct) SetName(n string)
- func (c *Struct) SetOwnerType(owner string)
- func (c *Struct) SetSubTypes(sb []CompositeType)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CompositeType ¶
type CompositeType interface { Kind() common.CompositeKind GetFields() []Field SetFields(fields []Field) GetFunctions() []Function SetFunctions(fns []Function) GetSubTypes() []CompositeType SetSubTypes(sb []CompositeType) SetName(n string) GetName() string GetSimpleName() string GetGoName() string // GetGoName returns name in go, if it's kind is struct, will add "Struct" prefix, if it's kind is resource, will add "Resource" prefix. SetOwnerType(own string) }
type Contract ¶
type Contract struct { PkgName string IgnoreContractGeneration bool // contains filtered or unexported fields }
func (*Contract) FlattenSubTypes ¶
func (c *Contract) FlattenSubTypes()
FlattenSubTypes move all subtypes to contracts subtypes
func (*Contract) GetFunctions ¶
func (c *Contract) GetFunctions() []Function
func (*Contract) GetSimpleName ¶
func (c *Contract) GetSimpleName() string
func (*Contract) GetSubTypes ¶
func (c *Contract) GetSubTypes() []CompositeType
func (*Contract) Kind ¶ added in v0.0.7
func (c *Contract) Kind() common.CompositeKind
func (*Contract) SetFunctions ¶
func (c *Contract) SetFunctions(fns []Function)
func (*Contract) SetOwnerType ¶
func (c *Contract) SetOwnerType(owner string)
func (*Contract) SetSubTypes ¶
func (c *Contract) SetSubTypes(sb []CompositeType)
type Event ¶ added in v0.0.7
type Event struct {
// contains filtered or unexported fields
}
func (*Event) GetFunctions ¶ added in v0.0.7
func (c *Event) GetFunctions() []Function
func (*Event) GetSimpleName ¶ added in v0.0.7
func (c *Event) GetSimpleName() string
func (*Event) GetSubTypes ¶ added in v0.0.7
func (c *Event) GetSubTypes() []CompositeType
func (*Event) Kind ¶ added in v0.0.7
func (*Event) Kind() common.CompositeKind
func (*Event) SetFunctions ¶ added in v0.0.7
func (c *Event) SetFunctions(fns []Function)
func (*Event) SetOwnerType ¶ added in v0.0.7
func (c *Event) SetOwnerType(owner string)
func (*Event) SetSubTypes ¶ added in v0.0.7
func (c *Event) SetSubTypes(sb []CompositeType)
type Function ¶
type Function struct { OwnerTypeName string Name string GoName string // first letter uppercase Params []FunctionParam ReturnType string // for return type of script ReturnSimpleType string // for convert to go type ReturnGoType string // contains filtered or unexported fields }
func (*Function) AddUsedCommaAuth ¶
AddUsedCommaAuth manually add index
func (*Function) AddUsedCommaCommon ¶
AddUsedCommaCommon manually add index
func (*Function) AuthorizerCount ¶
func (*Function) CommaCountAll ¶
CommaCountAll returns length of all params - 1, used to check necessary for comma adding.
func (*Function) CommaCountAuth ¶
CommaCountAuth returns length of all auth params - 1, used to check necessary for comma adding.
func (*Function) CommaCountCommon ¶
CommaCountCommon returns length of all common params - 1, used to check necessary for comma adding.
func (*Function) GenCadenceScript ¶
func (*Function) IsReturnMap ¶
type FunctionParam ¶
type Resource ¶
type Resource struct {
// contains filtered or unexported fields
}
func (*Resource) GetFunctions ¶
func (c *Resource) GetFunctions() []Function
func (*Resource) GetSimpleName ¶
func (c *Resource) GetSimpleName() string
func (*Resource) GetSubTypes ¶
func (c *Resource) GetSubTypes() []CompositeType
func (*Resource) Kind ¶ added in v0.0.7
func (r *Resource) Kind() common.CompositeKind
func (*Resource) SetFunctions ¶
func (c *Resource) SetFunctions(fns []Function)
func (*Resource) SetOwnerType ¶
func (c *Resource) SetOwnerType(owner string)
func (*Resource) SetSubTypes ¶
func (c *Resource) SetSubTypes(sb []CompositeType)
type Struct ¶
type Struct struct {
// contains filtered or unexported fields
}
func (*Struct) GetFunctions ¶
func (c *Struct) GetFunctions() []Function
func (*Struct) GetSimpleName ¶
func (c *Struct) GetSimpleName() string
func (*Struct) GetSubTypes ¶
func (c *Struct) GetSubTypes() []CompositeType
func (*Struct) Kind ¶ added in v0.0.7
func (s *Struct) Kind() common.CompositeKind
func (*Struct) SetFunctions ¶
func (c *Struct) SetFunctions(fns []Function)
func (*Struct) SetOwnerType ¶
func (c *Struct) SetOwnerType(owner string)
func (*Struct) SetSubTypes ¶
func (c *Struct) SetSubTypes(sb []CompositeType)
Click to show internal directories.
Click to hide internal directories.