Versions in this module Expand all Collapse all v0 v0.11.0-alpha.3 May 16, 2024 v0.11.0-alpha.2 May 13, 2024 v0.11.0-alpha Apr 4, 2024 v0.10.0 Apr 4, 2024 v0.10.0-alpha Jan 4, 2024 v0.9.0 Jan 4, 2024 v0.9.0-alpha Jul 19, 2023 v0.8.0 Jul 19, 2023 Changes in this version + func CleanMessageComment(comment string) string + func GeneratePlugins(genPlugins []string) func(*Generator) error + func ListImportedFiles(files []vppapi.File, file *vppapi.File) []vppapi.File + func ResolveImportPath(dir string) (string, error) + func SortFilesByName(apifiles []vppapi.File) + func StripMessageCommentFields(comment string, fields ...string) string + func WriteContentToFile(outputFile string, content []byte) error type File + func (f *File) IsStable() bool type GenFile + func (g *GenFile) GetFile() *File + type GenerateAllFn = func(*Generator) []*GenFile + type GenerateFileFn = func(*Generator, *File) *GenFile type Generator + func (g *Generator) GetMessageByName(name string) *Message + func (g *Generator) GetOpts() Options type Message + Comment string + File *File type Options + GenerateFiles []string type Plugin + External bool + GenerateAll GenerateAllFn v0.8.0-alpha Nov 29, 2022 v0.7.0 Nov 29, 2022 v0.6.0 Sep 9, 2022 Changes in this version + const BOOL + const F64 + const I16 + const I32 + const I64 + const I8 + const STRING + const U16 + const U32 + const U64 + const U8 + var BaseTypeSizes = map[string]int + var BaseTypesGo = map[string]string + var Logger = logrus.New() + var Plugins = map[string]*Plugin + func GenerateDefault(gen *Generator) + func ListImportedTypes(apifiles []*vppapi.File, file *vppapi.File) []string + func RegisterPlugin(name string, genfn func(*Generator, *File) *GenFile) + func RemoveImportedTypes(apifiles []*vppapi.File, apifile *vppapi.File) + func Run(apiDir string, filesToGenerate []string, opts Options, ...) + func RunPlugin(name string, gen *Generator, file *File) error + func SortFileObjectsByName(file *vppapi.File) + func SortFilesByImports(apifiles []*vppapi.File) + type Alias struct + TypeBasic *string + TypeStruct *Struct + TypeUnion *Union + type Enum struct + IsFlag bool + type Field struct + DefaultValue interface{} + FieldSizeFrom *Field + FieldSizeOf *Field + GoName string + Index int + ParentMessage *Message + ParentStruct *Struct + ParentUnion *Union + TypeAlias *Alias + TypeEnum *Enum + TypeStruct *Struct + TypeUnion *Union + type File struct + Aliases []*Alias + Desc vppapi.File + Enums []*Enum + FilenamePrefix string + Generate bool + GoImportPath GoImportPath + Imports []string + Messages []*Message + PackageName GoPackageName + Service *Service + Structs []*Struct + Unions []*Union + Version string + type GenFile struct + func GenerateAPI(gen *Generator, file *File) *GenFile + func GenerateHTTP(gen *Generator, file *File) *GenFile + func GenerateRPC(gen *Generator, file *File) *GenFile + func (g *GenFile) Content() ([]byte, error) + func (g *GenFile) GoIdent(ident GoIdent) string + func (g *GenFile) Import(importPath GoImportPath) + func (g *GenFile) P(v ...interface{}) + func (g *GenFile) Write(p []byte) (n int, err error) + type Generator struct + Files []*File + FilesByName map[string]*File + FilesByPath map[string]*File + func New(opts Options, apiFiles []*vppapi.File, filesToGen []string) (*Generator, error) + func (g *Generator) Generate() error + func (g *Generator) NewGenFile(filename string, importPath GoImportPath) *GenFile + type GoIdent struct + GoImportPath GoImportPath + GoName string + func (id GoIdent) String() string + type GoImportPath string + func (p GoImportPath) Ident(s string) GoIdent + func (p GoImportPath) String() string + type GoPackageName string + type Message struct + CRC string + Fields []*Field + type Options struct + ImportPrefix string + NoSourcePathInfo bool + NoVersionInfo bool + OutputDir string + type Plugin struct + GenerateFile func(*Generator, *File) *GenFile + Name string + type RPC struct + GoName string + MsgReply *Message + MsgRequest *Message + MsgStream *Message + Service *Service + VPP vppapi.RPC + type Service struct + RPCs []*RPC + type Struct struct + Fields []*Field + type Union struct + Fields []*Field v0.6.0-alpha Aug 2, 2022