helper

package
v0.0.0-...-db8d551 Latest Latest
Warning

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

Go to latest
Published: May 24, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetDefaultImports

func GetDefaultImports() map[string]string

func GetMemberNames

func GetMemberNames(node *ast.StructType) []string

Types

type Generator

type Generator struct {
	PkgName string
	Imports map[string]string
	// contains filtered or unexported fields
}

func (*Generator) GenPreamble

func (g *Generator) GenPreamble()

func (*Generator) GenReverse

func (g *Generator) GenReverse(typeInfo map[string]TypeInfo)

func (*Generator) GenSizeHint

func (g *Generator) GenSizeHint(typeInfo map[string]TypeInfo)

func (*Generator) Write

func (g *Generator) Write(w io.Writer) error

type Parser

type Parser struct {
	PkgName string
	Info    map[string]TypeInfo
	Debug   bool
}

func (*Parser) ParseDir

func (p *Parser) ParseDir(dirname string, targetTypeNames []string, ignoreComment []string) error

type TypeInfo

type TypeInfo struct {
	TypeName        string
	TypeParams      []string
	InnerMemberName string
	StructType      *ast.StructType
}

Jump to

Keyboard shortcuts

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