bpdoc

package
v0.0.0-...-8d20586 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2017 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPackageAST

func NewPackageAST(files []string) (*ast.Package, error)

func Write

func Write(filename string, pkgFiles map[string][]string,
	moduleTypePropertyStructs map[string][]interface{}) error

Types

type Context

type Context struct {
	// contains filtered or unexported fields
}

func NewContext

func NewContext(pkgFiles map[string][]string) *Context

func (*Context) PropertyStruct

func (c *Context) PropertyStruct(pkgPath, name string, defaults reflect.Value) (*PropertyStruct, error)

Return the PropertyStruct associated with a property struct type. The type should be in the format <package path>.<type name>

type Property

type Property struct {
	Name       string
	OtherNames []string
	Type       string
	Tag        reflect.StructTag
	Text       string
	OtherTexts []string
	Properties []Property
	Default    string
}

func (*Property) Clone

func (p *Property) Clone() Property

func (*Property) Equal

func (p *Property) Equal(other Property) bool

func (*Property) Nest

func (p *Property) Nest(nested *PropertyStruct)

func (*Property) SameSubProperties

func (p *Property) SameSubProperties(other Property) bool

type PropertyStruct

type PropertyStruct struct {
	Name       string
	Text       string
	Properties []Property
}

func (*PropertyStruct) Clone

func (ps *PropertyStruct) Clone() *PropertyStruct

func (*PropertyStruct) ExcludeByTag

func (ps *PropertyStruct) ExcludeByTag(key, value string)

func (*PropertyStruct) GetByName

func (ps *PropertyStruct) GetByName(name string) *Property

func (*PropertyStruct) IncludeByTag

func (ps *PropertyStruct) IncludeByTag(key, value string)

func (*PropertyStruct) SetDefaults

func (ps *PropertyStruct) SetDefaults(defaults reflect.Value)

Jump to

Keyboard shortcuts

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