Documentation ¶
Index ¶
- type Collector
- func (c *Collector) CollectObject(ctx context.Context, u *unstructured.Unstructured, resourceInfo *ResourceInfo) error
- func (c *Collector) CollectResource(ctx context.Context, resourceInfo *ResourceInfo, namespace, name string) error
- func (c *Collector) CollectResources(ctx context.Context, resourceInfo *ResourceInfo, namespace string) error
- func (c *Collector) DiscoverResources(ctx context.Context, filter discovery.ResourcePredicateFunc) ([]*ResourceInfo, error)
- type OmitManagedFieldsPrinter
- type ResourceInfo
- type ResourcePrinterInterface
- type SuffixInterface
- type YAMLPrinter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Collector ¶
type Collector struct {
// contains filtered or unexported fields
}
func NewCollector ¶
func NewCollector( baseDir string, printers []ResourcePrinterInterface, discoveryClient discovery.DiscoveryInterface, corev1Client corev1client.CoreV1Interface, dynamicClient dynamic.Interface, relatedResources bool, keepGoing bool, logsLimitBytes int64, ) *Collector
func (*Collector) CollectObject ¶
func (c *Collector) CollectObject(ctx context.Context, u *unstructured.Unstructured, resourceInfo *ResourceInfo) error
func (*Collector) CollectResource ¶
func (*Collector) CollectResources ¶
func (*Collector) DiscoverResources ¶
func (c *Collector) DiscoverResources(ctx context.Context, filter discovery.ResourcePredicateFunc) ([]*ResourceInfo, error)
type OmitManagedFieldsPrinter ¶
type OmitManagedFieldsPrinter struct {
Delegate ResourcePrinterInterface
}
func (*OmitManagedFieldsPrinter) GetSuffix ¶
func (p *OmitManagedFieldsPrinter) GetSuffix() string
func (*OmitManagedFieldsPrinter) PrintObj ¶
func (p *OmitManagedFieldsPrinter) PrintObj(resourceInfo *ResourceInfo, obj runtime.Object, w io.Writer) error
type ResourceInfo ¶
type ResourceInfo struct { Scope meta.RESTScope Resource schema.GroupVersionResource }
func NewResourceInfoFromMapping ¶
func NewResourceInfoFromMapping(mapping *meta.RESTMapping) *ResourceInfo
func ReplaceIsometricResourceInfosIfPresent ¶
func ReplaceIsometricResourceInfosIfPresent(resourceInfos []*ResourceInfo) ([]*ResourceInfo, error)
type ResourcePrinterInterface ¶
type ResourcePrinterInterface interface { PrintObj(*ResourceInfo, runtime.Object, io.Writer) error SuffixInterface }
type SuffixInterface ¶
type SuffixInterface interface {
GetSuffix() string
}
type YAMLPrinter ¶
type YAMLPrinter struct { }
func (*YAMLPrinter) GetSuffix ¶
func (p *YAMLPrinter) GetSuffix() string
func (*YAMLPrinter) PrintObj ¶
func (p *YAMLPrinter) PrintObj(resourceInfo *ResourceInfo, obj runtime.Object, w io.Writer) error
Click to show internal directories.
Click to hide internal directories.