Documentation ¶
Index ¶
Constants ¶
View Source
const ( ElementType = "element_type" // element type of Array Chan Pointer Slice ArrayLength = "array_length" // length of Array KeyType = "key_type" // key type of Map ValueType = "value_type" // value type of Map NumIn = "in_number" // input parameter count of Func NumOut = "out_number" // output parameter count of Func In = "in_" // specify the index of in type Out = "out_" // specify the index of out type NumField = "fields_number" // a struct type's field count Field = "field_" // specify the inedex of of field name ChanDir = "chan_dir" // dir of Chan Variadic = "variadic" // variadic of Func )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Type ¶
type Type struct { Kind string `json:"kind,omitempty"` // reflect.Type.Kind().String() Struct map[string]Type `json:"struct,omitempty"` // struct info of the type Extra map[string]any `json:"extra,omitempty"` // extra info of the type. Such as array length }
Type is a serializable representation of a Go type.
Field Kind is same as reflect.Type::Kind() Struct gives the complete info of the type if the Kind field cannot specify the type
func FromGoType ¶
FromGoType converts the std reflect.Type to Type
Click to show internal directories.
Click to hide internal directories.