Documentation
¶
Index ¶
- type Config
- type Contemplate
- type Package
- func (s *Package) AddScopeTypes(names ...string)
- func (s *Package) Exprs() map[string]ast.Expr
- func (s *Package) FilterExprsByTypeExpr(expr ast.Expr) []ast.Expr
- func (s *Package) LookupAstIdentDef(typeName string) *ast.Ident
- func (s *Package) LookupExpr(name string) ast.Expr
- func (s *Package) LookupScopeExpr(name string) ast.Expr
- func (s *Package) LookupScopeType(name string) types.Object
- func (s *Package) LookupType(name string) types.Object
- func (s *Package) Name() string
- func (s *Package) Path() string
- func (s *Package) Raw() *packages.Package
- func (s *Package) ScopeTypes() map[string]types.Object
- func (s *Package) Types() map[string]types.Object
- type PackageConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Packages []*PackageConfig `json:"packages" yaml:"packages"`
}
func (*Config) Package ¶
func (c *Config) Package(path string) *PackageConfig
func (*Config) PackagePaths ¶
type Contemplate ¶
func Load ¶
func Load(cfg *Config) (*Contemplate, error)
func (*Contemplate) LookupAstIdentDefsByDeclType ¶
func (s *Contemplate) LookupAstIdentDefsByDeclType(input types.TypeAndValue) []types.Object
func (*Contemplate) LookupExpr ¶
func (s *Contemplate) LookupExpr(name string) ast.Expr
func (*Contemplate) LookupTypesByType ¶
func (s *Contemplate) LookupTypesByType(obj types.Object) []types.Object
func (*Contemplate) Package ¶
func (s *Contemplate) Package(path string) *Package
type Package ¶
type Package struct {
// contains filtered or unexported fields
}
func NewPackage ¶
func NewPackage(l *Contemplate, pkg *packages.Package) *Package
func (*Package) AddScopeTypes ¶
func (*Package) FilterExprsByTypeExpr ¶
type PackageConfig ¶
Click to show internal directories.
Click to hide internal directories.