plugin

package
v0.0.0-...-6cd2900 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2023 License: BSD-3-Clause Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New() generator.Plugin

Types

type Plugin

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

func (*Plugin) Generate

func (p *Plugin) Generate(file *generator.FileDescriptor)

Here is where all the work is done, this is called to generate the main guts of the code

func (*Plugin) GenerateImports

func (p *Plugin) GenerateImports(file *generator.FileDescriptor)

Remember that this is called last, so that we can mark imports as used in Generate and then they get output here. So don't go adding things here that expect to be first

func (*Plugin) Init

func (p *Plugin) Init(g *generator.Generator)

func (*Plugin) Name

func (p *Plugin) Name() string

func (*Plugin) P

func (p *Plugin) P(s string, args ...interface{})

P forwards to p.gen.P after a Sprintf

Jump to

Keyboard shortcuts

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