workutils

package module
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

README

workutils

Utilities for Open Cluster Management ManifestWork

func Get(work workapiv1.ManifestWork, resource Resource) (runtime.Object, error)

func Add(work workapiv1.ManifestWork, obj runtime.Object) (workapiv1.ManifestWork, error)

func Update(work workapiv1.ManifestWork, obj runtime.Object) (workapiv1.ManifestWork, error)

func Remove(work workapiv1.ManifestWork, resource Resource) (workapiv1.ManifestWork, error)

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Add

Add adds the given object to the ManifestWork

func Get

func Get(work workapiv1.ManifestWork, resource Resource) (runtime.Object, error)

Get returns the resource with the given APIVersion, Kind, Name, and Namespace

func Remove

func Remove(work workapiv1.ManifestWork, resource Resource) (workapiv1.ManifestWork, error)

Remove removes the resource with the given APIVersion, Kind, Name, and Namespace

func Update

Update updates ManifestWork

Types

type Resource

type Resource struct {
	Group     string
	Version   string `validate:"required"`
	Kind      string `validate:"required"`
	Name      string `validate:"required"`
	Namespace string
}

Jump to

Keyboard shortcuts

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