Documentation
¶
Overview ¶
Package specmodel defines the YAML spec schema produced by specgen and consumed by idiomgen.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CallbackDef ¶
type CallbackDef struct {
Params []Param `yaml:"params,omitempty"`
Returns string `yaml:"returns"`
}
CallbackDef describes an extracted callback function type.
type FuncDef ¶
type FuncDef struct {
CName string `yaml:"c_name"`
Params []Param `yaml:"params,omitempty"`
Returns string `yaml:"returns"`
}
FuncDef describes an extracted function.
type Param ¶
type Param struct {
Name string `yaml:"name"`
Type string `yaml:"type"`
Direction string `yaml:"direction,omitempty"` // "out" for output params
Const bool `yaml:"const,omitempty"` // true if param has const qualifier
}
Param describes a function or callback parameter.
type Spec ¶
type Spec struct {
Module string `yaml:"module"`
SourcePackage string `yaml:"source_package"`
Types map[string]TypeDef `yaml:"types,omitempty"`
Enums map[string][]EnumValue `yaml:"enums,omitempty"`
Functions map[string]FuncDef `yaml:"functions,omitempty"`
Callbacks map[string]CallbackDef `yaml:"callbacks,omitempty"`
Structs map[string]StructDef `yaml:"structs,omitempty"`
Macros map[string]int64 `yaml:"macros,omitempty"`
}
Spec is the top-level structure representing one NDK module's extracted API.
type StructDef ¶
type StructDef struct {
Fields []StructField `yaml:"fields"`
}
StructDef describes a C struct's fields extracted from NDK headers.
Click to show internal directories.
Click to hide internal directories.