args

package
v0.0.0-...-9d3dc0a Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Validate

func Validate(genericArgs *args.GeneratorArgs) error

Validate checks the given arguments.

Types

type CustomArgs

type CustomArgs struct {
	// ReportFilename is added to CustomArgs for specifying name of report file used
	// by API linter. If specified, API rule violations will be printed to report file.
	// Otherwise default value "-" will be used which indicates stdout.
	ReportFilename string
}

CustomArgs is used by the gengo framework to pass args specific to this generator.

func NewDefaults

func NewDefaults() (*args.GeneratorArgs, *CustomArgs)

NewDefaults returns default arguments for the generator. Returning the arguments instead of using default flag parsing allows registering custom arguments afterwards

func (*CustomArgs) AddFlags

func (c *CustomArgs) AddFlags(fs *pflag.FlagSet)

AddFlags add the generator flags to the flag set.

Jump to

Keyboard shortcuts

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