Documentation
¶
Index ¶
- func DecideEnumTypeName(t reflect.Type) string
- func WriteStructTSBinding(b *Bridge, w io.Writer)
- type Bridge
- func (b *Bridge) AddStructFields(sinfo *StructInfo, t reflect.Type)
- func (b *Bridge) DecideTypescriptTypeName(t reflect.Type) string
- func (b *Bridge) Process()
- func (b *Bridge) ProcessPackage(pkgPath string)
- func (b *Bridge) QueueObject(x interface{})
- func (b *Bridge) QueuePackage(pkgPath string)
- func (b *Bridge) QueueType(t reflect.Type)
- type ConstValue
- type EnumInfo
- type ErrorInfo
- type StructField
- type StructInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecideEnumTypeName ¶
func WriteStructTSBinding ¶
Types ¶
type Bridge ¶
type Bridge struct {
Structs []StructInfo
Enums []EnumInfo
Errors []ErrorInfo
// types we want to process (structs/enums)
ProcessedTypes []reflect.Type
QueuedTypes []reflect.Type
// packages we want to process consts for
QueuedPackages []string
ProcessedPackages []string
}
func (*Bridge) AddStructFields ¶
func (b *Bridge) AddStructFields(sinfo *StructInfo, t reflect.Type)
func (*Bridge) DecideTypescriptTypeName ¶
func (*Bridge) ProcessPackage ¶
func (*Bridge) QueueObject ¶
func (b *Bridge) QueueObject(x interface{})
func (*Bridge) QueuePackage ¶
type ConstValue ¶
type EnumInfo ¶
type EnumInfo struct {
Name string
TypeName string
Consts []ConstValue
}
type StructField ¶
type StructInfo ¶
type StructInfo struct {
Name string
Fields []StructField
}
Click to show internal directories.
Click to hide internal directories.