parse

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2025 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseHeaderFile

func ParseHeaderFile(files []string, prefixes []string, cflags []string, symMap map[string]string, isCpp bool, isTemp bool) (map[string]*SymbolInfo, error)

Types

type Collect added in v0.3.0

type Collect struct {
	SymName    string             // symbol name
	GetSymInfo func() *SymbolInfo // get symbol info
}

type SymbolInfo

type SymbolInfo struct {
	GoName    string
	ProtoName string
}

type SymbolProcessor

type SymbolProcessor struct {
	Files      []string
	Prefixes   []string
	SymbolMap  map[string]*SymbolInfo
	NameCounts map[string]int
	// custom symbol map like:
	// "sqlite3_finalize":".Close" -> method
	// "sqlite3_open":"Open" -> function
	CustomSymMap map[string]string
	// contains filtered or unexported fields
}

func NewSymbolProcessor

func NewSymbolProcessor(Files []string, Prefixes []string, SymMap map[string]string) *SymbolProcessor

func (*SymbolProcessor) AddSuffix

func (p *SymbolProcessor) AddSuffix(name string) string

func (*SymbolProcessor) GenMethodName

func (p *SymbolProcessor) GenMethodName(class, name string, isDestructor bool, isPointer bool) string

Jump to

Keyboard shortcuts

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