parse

package
v0.0.0-...-2c63f42 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 26, 2023 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseEnumInPackage

func ParseEnumInPackage(ng ggen.Engine, pkg *packages.Package) (map[string]*defs.Enum, error)

func Services

func Services(ng ggen.Engine, pkg *packages.Package, kinds []defs.Kind) (services []*defs.Service, _ error)

func SkipPointer

func SkipPointer(typ types.Type) types.Type

func UnwrapNull

func UnwrapNull(typ types.Type) types.Type

Types

type Info

type Info struct {
	Meta
	// contains filtered or unexported fields
}

func NewInfo

func NewInfo(ng ggen.FilterEngine) *Info

func (*Info) GetEnum

func (inf *Info) GetEnum(typ types.Type) *defs.Enum

func (*Info) Init

func (inf *Info) Init(ng ggen.Engine)

func (*Info) IsArray

func (inf *Info) IsArray(typ types.Type, inner *types.Type) bool

func (*Info) IsBasic

func (inf *Info) IsBasic(typ types.Type, inner *types.Type) bool

func (*Info) IsEnum

func (inf *Info) IsEnum(typ types.Type) bool

func (*Info) IsID

func (inf *Info) IsID(typ types.Type) bool

func (*Info) IsMap

func (inf *Info) IsMap(typ types.Type) bool

func (*Info) IsNamed

func (inf *Info) IsNamed(typ types.Type, inner *types.Type) bool

func (*Info) IsNamedBasic

func (inf *Info) IsNamedBasic(typ types.Type, inner *types.Type) bool

func (*Info) IsNamedInterface

func (inf *Info) IsNamedInterface(typ types.Type, inner *types.Type) bool

func (*Info) IsNamedStruct

func (inf *Info) IsNamedStruct(typ types.Type, inner *types.Type) bool

func (*Info) IsNullBasic

func (inf *Info) IsNullBasic(typ types.Type, inner *types.Type) bool

func (*Info) IsNullID

func (inf *Info) IsNullID(typ types.Type) bool

func (*Info) IsNullStruct

func (inf *Info) IsNullStruct(typ types.Type, expectName string) bool

func (*Info) IsSliceOfBytes

func (inf *Info) IsSliceOfBytes(typ types.Type) bool

func (*Info) IsTime

func (inf *Info) IsTime(typ types.Type) bool

type Meta

type Meta map[MetaKey]interface{}

func (Meta) Cache

func (m Meta) Cache(item, key interface{}, fn func() interface{}) interface{}

func (Meta) Get

func (m Meta) Get(item, key interface{}) interface{}

func (Meta) Set

func (m Meta) Set(item, key, value interface{})

type MetaKey

type MetaKey struct {
	Item interface{}
	Key  interface{}
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL