meta

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2017 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrNoDeletionTimestamp is the error returned by GetDeletionTimestamp when there is no
	// deletion timestamp set on the object
	ErrNoDeletionTimestamp = errors.New("no deletion timestamp set")
)

Functions

func AddFinalizer

func AddFinalizer(obj runtime.Object, value string) error

AddFinalizer adds value to the list of finalizers on obj

func DeletionTimestampExists

func DeletionTimestampExists(obj runtime.Object) (bool, error)

DeletionTimestampExists returns true if a deletion timestamp exists on obj, or a non-nil error if that couldn't be reliably determined

func GetAccessor

func GetAccessor() meta.MetadataAccessor

GetAccessor returns a MetadataAccessor to fetch general information on metadata of runtime.Object types

func GetDeletionTimestamp

func GetDeletionTimestamp(obj runtime.Object) (*metav1.Time, error)

GetDeletionTimestamp returns the deletion timestamp on obj, or a non-nil error if there was an error getting it or it isn't set. Returns ErrNoDeletionTimestamp if there was none set

func GetFinalizers

func GetFinalizers(obj runtime.Object) ([]string, error)

GetFinalizers gets the list of finalizers on obj

func GetNamespace

func GetNamespace(obj runtime.Object) (string, error)

GetNamespace returns the namespace for the given object, if there is one. If not, returns the empty string and a non-nil error

func RemoveFinalizer

func RemoveFinalizer(obj runtime.Object, value string) ([]string, error)

RemoveFinalizer removes the given value from the list of finalizers in obj, then returns a new list of finalizers after value has been removed.

func SetDeletionTimestamp

func SetDeletionTimestamp(obj runtime.Object, t time.Time) error

SetDeletionTimestamp sets the deletion timestamp on obj to t

Types

This section is empty.

Jump to

Keyboard shortcuts

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