Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoConfigFile = fmt.Errorf("no config file exists") ErrNoGoFilesFoundInRoot = fmt.Errorf("no go files found in root search path") ErrPkgNotFound = fmt.Errorf("package not found in config") ErrGoModNotFound = fmt.Errorf("no go.mod file found") ErrGoModInvalid = fmt.Errorf("go.mod file has no module line") )
Functions ¶
This section is empty.
Types ¶
type Interface ¶ added in v3.1.0
type NodeVisitor ¶
type NodeVisitor struct {
// contains filtered or unexported fields
}
func NewNodeVisitor ¶
func NewNodeVisitor(ctx context.Context) *NodeVisitor
func (*NodeVisitor) DeclaredInterfaces ¶
func (nv *NodeVisitor) DeclaredInterfaces() []declaredInterface
type RemoteTemplate ¶
type RemoteTemplate struct {
// contains filtered or unexported fields
}
func NewRemoteTemplate ¶
func NewRemoteTemplate(templateURL string, schemaURL string) *RemoteTemplate
func (*RemoteTemplate) Schema ¶
func (r *RemoteTemplate) Schema(ctx context.Context) (*gojsonschema.Schema, error)
Schema returns the JSON Schema as a string. It downloads the remote schema once and caches the result for future calls.
type TemplateGenerator ¶
type TemplateGenerator struct {
// contains filtered or unexported fields
}
func NewTemplateGenerator ¶
func NewTemplateGenerator( ctx context.Context, srcPkg *packages.Package, outPkgFSPath string, templateName string, templateSchema string, requireSchemaExists bool, remoteTemplateCache map[string]*RemoteTemplate, formatter Formatter, pkgConfig *config.Config, pkgName string, forceInPackage *bool, ) (*TemplateGenerator, error)
Source Files
¶
Directories
¶
| Path | Synopsis |
|---|---|
|
recursive_generation/subpkg_with_only_autogenerated_files
Code generated by an arbitrary code generator thingy.
|
Code generated by an arbitrary code generator thingy. |
Click to show internal directories.
Click to hide internal directories.