Documentation ¶
Overview ¶
Get is a reusable implementation of the Get command for the tink cli. The Get command lists and filters resources. It supports different kind of visualisation and it is designed to be extendible and usable across resources.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewGetCommand ¶
Types ¶
type Options ¶
type Options struct { // Headers is the list of headers you want to print as part of the list Headers []string // RetrieveData reaches out to Tinkerbell and it gets the required data RetrieveData func(context.Context, *client.FullClient) ([]interface{}, error) // RetrieveByID is used when a get command has a list of arguments RetrieveByID func(context.Context, *client.FullClient, string) (interface{}, error) // RetrieveByName is used when a get command has a list of arguments RetrieveByName func(context.Context, *client.FullClient, string) (interface{}, error) // PopulateTable populates a table with the data retrieved with the RetrieveData function. PopulateTable func([]interface{}, table.Writer) error // Format specifies the format you want the list of resources printed // out. By default it is table but it can be JSON ar CSV. Format string // NoHeaders does not print the header line NoHeaders bool }
Click to show internal directories.
Click to hide internal directories.