args

package
v0.32.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2024 License: Apache-2.0 Imports: 10 Imported by: 145

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGVPackagesValue

func NewGVPackagesValue(builder *groupVersionsBuilder, def []string) *gvPackagesValue

func NewGVTypesValue

func NewGVTypesValue(gvToTypes *map[types.GroupVersion][]string, def []string) *gvTypeValue

func NewGroupVersionsBuilder

func NewGroupVersionsBuilder(groups *[]types.GroupVersions) *groupVersionsBuilder

func NewInputBasePathValue

func NewInputBasePathValue(builder *groupVersionsBuilder, def string) *inputBasePathValue

Types

type Args added in v0.30.0

type Args struct {
	// The directory for the generated results.
	OutputDir string

	// The Go import-path of the generated results.
	OutputPkg string

	// The boilerplate header for Go files.
	GoHeaderFile string

	// A sorted list of group versions to generate. For each of them the package path is found
	// in GroupVersionToInputPath.
	Groups []types.GroupVersions

	// Overrides for which types should be included in the client.
	IncludedTypesOverrides map[types.GroupVersion][]string

	// ClientsetName is the name of the clientset to be generated. It's
	// populated from command-line arguments.
	ClientsetName string
	// ClientsetAPIPath is the default API HTTP path for generated clients.
	ClientsetAPIPath string
	// ClientsetOnly determines if we should generate the clients for groups and
	// types along with the clientset. It's populated from command-line
	// arguments.
	ClientsetOnly bool
	// FakeClient determines if client-gen generates the fake clients.
	FakeClient bool
	// PluralExceptions specify list of exceptions used when pluralizing certain types.
	// For example 'Endpoints:Endpoints', otherwise the pluralizer will generate 'Endpointes'.
	PluralExceptions []string

	// ApplyConfigurationPackage is the package of apply builders generated by
	// applyconfiguration-gen.
	// If non-empty, Apply functions are generated for each type and reference the apply builders.
	// If empty (""), Apply functions are not generated.
	ApplyConfigurationPackage string

	// PrefersProtobuf determines if the generated clientset uses protobuf for API requests.
	PrefersProtobuf bool
}

func New added in v0.30.0

func New() *Args

func (*Args) AddFlags added in v0.30.0

func (args *Args) AddFlags(fs *pflag.FlagSet, inputBase string)

func (*Args) GroupVersionPackages added in v0.30.0

func (args *Args) GroupVersionPackages() map[types.GroupVersion]string

GroupVersionPackages returns a map from GroupVersion to the package with the types.go.

func (*Args) Validate added in v0.30.0

func (args *Args) Validate() error

Jump to

Keyboard shortcuts

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