typescaffold

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2022 License: Apache-2.0 Imports: 5 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Resource

type Resource struct {
	// Namespaced is true if the resource is namespaced
	Namespaced bool

	// Kind is the API Kind.
	Kind string

	// Resource is the API Resource.
	Resource string
}

Resource contains the information required to scaffold files for a resource.

func (*Resource) Validate

func (r *Resource) Validate() error

Validate checks the Resource values to make sure they are valid.

type ScaffoldOptions

type ScaffoldOptions struct {
	Resource        Resource
	AdditionalHelp  string
	GenerateClients bool
}

ScaffoldOptions describes how to scaffold out a Kubernetes object with the basic metadata and comment annotations required to generate code for and conform to runtime.Object and metav1.Object.

func (*ScaffoldOptions) Scaffold

func (o *ScaffoldOptions) Scaffold(out io.Writer) error

Scaffold prints the Kubernetes object scaffolding to the given output.

func (*ScaffoldOptions) Validate

func (o *ScaffoldOptions) Validate() error

Validate validates the options, returning an error if anything is invalid.

Jump to

Keyboard shortcuts

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