v1

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AggregationRuleBlank = (&AggregationRuleDie{}).DieFeed(rbacv1.AggregationRule{})
View Source
var ClusterRoleBindingBlank = (&ClusterRoleBindingDie{}).DieFeed(rbacv1.ClusterRoleBinding{})
View Source
var ClusterRoleBlank = (&ClusterRoleDie{}).DieFeed(rbacv1.ClusterRole{})
View Source
var PolicyRuleBlank = (&PolicyRuleDie{}).DieFeed(rbacv1.PolicyRule{})
View Source
var RoleBindingBlank = (&RoleBindingDie{}).DieFeed(rbacv1.RoleBinding{})
View Source
var RoleBlank = (&RoleDie{}).DieFeed(rbacv1.Role{})
View Source
var RoleRefBlank = (&RoleRefDie{}).DieFeed(rbacv1.RoleRef{})
View Source
var SubjectBlank = (&SubjectDie{}).DieFeed(rbacv1.Subject{})

Functions

This section is empty.

Types

type AggregationRuleDie

type AggregationRuleDie struct {
	// contains filtered or unexported fields
}

func (*AggregationRuleDie) ClusterRoleSelectors

func (d *AggregationRuleDie) ClusterRoleSelectors(v ...apismetav1.LabelSelector) *AggregationRuleDie

ClusterRoleSelectors holds a list of selectors which will be used to find ClusterRoles and create the rules.

If any of the selectors match, then the ClusterRole's permissions will be added

func (*AggregationRuleDie) ClusterRoleSelectorsDie

func (d *AggregationRuleDie) ClusterRoleSelectorsDie(v ...*metav1.LabelSelectorDie) *AggregationRuleDie

ClusterRoleSelectorsDie replaces ClusterRoleSelectors by collecting the released value from each die passed.

ClusterRoleSelectors holds a list of selectors which will be used to find ClusterRoles and create the rules.

If any of the selectors match, then the ClusterRole's permissions will be added

func (*AggregationRuleDie) DeepCopy

func (d *AggregationRuleDie) DeepCopy() *AggregationRuleDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*AggregationRuleDie) DieDiff added in v0.13.0

func (d *AggregationRuleDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*AggregationRuleDie) DieFeed

DieFeed returns a new die with the provided resource.

func (*AggregationRuleDie) DieFeedJSON

func (d *AggregationRuleDie) DieFeedJSON(j []byte) *AggregationRuleDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*AggregationRuleDie) DieFeedPtr

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*AggregationRuleDie) DieFeedRawExtension

func (d *AggregationRuleDie) DieFeedRawExtension(raw runtime.RawExtension) *AggregationRuleDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*AggregationRuleDie) DieFeedYAML

func (d *AggregationRuleDie) DieFeedYAML(y []byte) *AggregationRuleDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*AggregationRuleDie) DieFeedYAMLFile

func (d *AggregationRuleDie) DieFeedYAMLFile(name string) *AggregationRuleDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*AggregationRuleDie) DieImmutable

func (d *AggregationRuleDie) DieImmutable(immutable bool) *AggregationRuleDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*AggregationRuleDie) DiePatch added in v0.13.0

func (d *AggregationRuleDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*AggregationRuleDie) DieRelease

func (d *AggregationRuleDie) DieRelease() rbacv1.AggregationRule

DieRelease returns the resource managed by the die.

func (*AggregationRuleDie) DieReleaseJSON

func (d *AggregationRuleDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*AggregationRuleDie) DieReleasePtr

func (d *AggregationRuleDie) DieReleasePtr() *rbacv1.AggregationRule

DieReleasePtr returns a pointer to the resource managed by the die.

func (*AggregationRuleDie) DieReleaseRawExtension

func (d *AggregationRuleDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*AggregationRuleDie) DieReleaseYAML

func (d *AggregationRuleDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*AggregationRuleDie) DieSeal added in v0.13.0

func (d *AggregationRuleDie) DieSeal() *AggregationRuleDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*AggregationRuleDie) DieSealFeed added in v0.13.0

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*AggregationRuleDie) DieSealFeedPtr added in v0.13.0

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*AggregationRuleDie) DieSealRelease added in v0.13.0

func (d *AggregationRuleDie) DieSealRelease() rbacv1.AggregationRule

DieSealRelease returns the sealed resource managed by the die.

func (*AggregationRuleDie) DieSealReleasePtr added in v0.13.0

func (d *AggregationRuleDie) DieSealReleasePtr() *rbacv1.AggregationRule

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*AggregationRuleDie) DieStamp

func (d *AggregationRuleDie) DieStamp(fn func(r *rbacv1.AggregationRule)) *AggregationRuleDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*AggregationRuleDie) DieStampAt

func (d *AggregationRuleDie) DieStampAt(jp string, fn interface{}) *AggregationRuleDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*AggregationRuleDie) DieWith

func (d *AggregationRuleDie) DieWith(fns ...func(d *AggregationRuleDie)) *AggregationRuleDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

type ClusterRoleBindingDie

type ClusterRoleBindingDie struct {
	metav1.FrozenObjectMeta
	// contains filtered or unexported fields
}

func (*ClusterRoleBindingDie) APIVersion

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources

func (*ClusterRoleBindingDie) DeepCopy

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*ClusterRoleBindingDie) DeepCopyObject

func (d *ClusterRoleBindingDie) DeepCopyObject() runtime.Object

func (*ClusterRoleBindingDie) DieDefaultTypeMetadata added in v0.13.0

func (d *ClusterRoleBindingDie) DieDefaultTypeMetadata() *ClusterRoleBindingDie

DieDefaultTypeMetadata sets the APIVersion and Kind to "rbac.authorization.k8s.io/v1" and "ClusterRoleBinding" respectively.

func (*ClusterRoleBindingDie) DieDiff added in v0.13.0

func (d *ClusterRoleBindingDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*ClusterRoleBindingDie) DieFeed

DieFeed returns a new die with the provided resource.

func (*ClusterRoleBindingDie) DieFeedJSON

func (d *ClusterRoleBindingDie) DieFeedJSON(j []byte) *ClusterRoleBindingDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*ClusterRoleBindingDie) DieFeedPtr

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*ClusterRoleBindingDie) DieFeedRawExtension

func (d *ClusterRoleBindingDie) DieFeedRawExtension(raw runtime.RawExtension) *ClusterRoleBindingDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*ClusterRoleBindingDie) DieFeedYAML

func (d *ClusterRoleBindingDie) DieFeedYAML(y []byte) *ClusterRoleBindingDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*ClusterRoleBindingDie) DieFeedYAMLFile

func (d *ClusterRoleBindingDie) DieFeedYAMLFile(name string) *ClusterRoleBindingDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*ClusterRoleBindingDie) DieImmutable

func (d *ClusterRoleBindingDie) DieImmutable(immutable bool) *ClusterRoleBindingDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*ClusterRoleBindingDie) DiePatch added in v0.13.0

func (d *ClusterRoleBindingDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*ClusterRoleBindingDie) DieRelease

DieRelease returns the resource managed by the die.

func (*ClusterRoleBindingDie) DieReleaseJSON

func (d *ClusterRoleBindingDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*ClusterRoleBindingDie) DieReleasePtr

func (d *ClusterRoleBindingDie) DieReleasePtr() *rbacv1.ClusterRoleBinding

DieReleasePtr returns a pointer to the resource managed by the die.

func (*ClusterRoleBindingDie) DieReleaseRawExtension

func (d *ClusterRoleBindingDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*ClusterRoleBindingDie) DieReleaseUnstructured

func (d *ClusterRoleBindingDie) DieReleaseUnstructured() *unstructured.Unstructured

DieReleaseUnstructured returns the resource managed by the die as an unstructured object. Panics on error.

func (*ClusterRoleBindingDie) DieReleaseYAML

func (d *ClusterRoleBindingDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*ClusterRoleBindingDie) DieSeal added in v0.13.0

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*ClusterRoleBindingDie) DieSealFeed added in v0.13.0

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*ClusterRoleBindingDie) DieSealFeedPtr added in v0.13.0

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*ClusterRoleBindingDie) DieSealRelease added in v0.13.0

func (d *ClusterRoleBindingDie) DieSealRelease() rbacv1.ClusterRoleBinding

DieSealRelease returns the sealed resource managed by the die.

func (*ClusterRoleBindingDie) DieSealReleasePtr added in v0.13.0

func (d *ClusterRoleBindingDie) DieSealReleasePtr() *rbacv1.ClusterRoleBinding

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*ClusterRoleBindingDie) DieStamp

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*ClusterRoleBindingDie) DieStampAt

func (d *ClusterRoleBindingDie) DieStampAt(jp string, fn interface{}) *ClusterRoleBindingDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*ClusterRoleBindingDie) DieWith

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*ClusterRoleBindingDie) GetObjectKind

func (d *ClusterRoleBindingDie) GetObjectKind() schema.ObjectKind

func (*ClusterRoleBindingDie) Kind

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds

func (*ClusterRoleBindingDie) MarshalJSON

func (d *ClusterRoleBindingDie) MarshalJSON() ([]byte, error)

func (*ClusterRoleBindingDie) Metadata added in v0.13.0

Metadata standard object's metadata.

func (*ClusterRoleBindingDie) MetadataDie

func (d *ClusterRoleBindingDie) MetadataDie(fn func(d *metav1.ObjectMetaDie)) *ClusterRoleBindingDie

MetadataDie stamps the resource's ObjectMeta field with a mutable die.

func (*ClusterRoleBindingDie) RoleRef

RoleRef can only reference a ClusterRole in the global namespace.

If the RoleRef cannot be resolved, the Authorizer must return an error.

This field is immutable.

func (*ClusterRoleBindingDie) RoleRefDie

func (d *ClusterRoleBindingDie) RoleRefDie(fn func(d *RoleRefDie)) *ClusterRoleBindingDie

RoleRefDie mutates RoleRef as a die.

RoleRef can only reference a ClusterRole in the global namespace.

If the RoleRef cannot be resolved, the Authorizer must return an error.

This field is immutable.

func (*ClusterRoleBindingDie) Subjects

Subjects holds references to the objects the role applies to.

func (*ClusterRoleBindingDie) SubjectsDie

SubjectsDie replaces Subjects by collecting the released value from each die passed.

Subjects holds references to the objects the role applies to.

func (*ClusterRoleBindingDie) TypeMetadata added in v0.13.0

TypeMetadata standard object's type metadata.

func (*ClusterRoleBindingDie) TypeMetadataDie added in v0.13.0

func (d *ClusterRoleBindingDie) TypeMetadataDie(fn func(d *metav1.TypeMetaDie)) *ClusterRoleBindingDie

TypeMetadataDie stamps the resource's TypeMeta field with a mutable die.

func (*ClusterRoleBindingDie) UnmarshalJSON

func (d *ClusterRoleBindingDie) UnmarshalJSON(b []byte) error

type ClusterRoleDie

type ClusterRoleDie struct {
	metav1.FrozenObjectMeta
	// contains filtered or unexported fields
}

func (*ClusterRoleDie) APIVersion

func (d *ClusterRoleDie) APIVersion(v string) *ClusterRoleDie

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources

func (*ClusterRoleDie) AddRuleDie

func (d *ClusterRoleDie) AddRuleDie(rule *PolicyRuleDie) *ClusterRoleDie

func (*ClusterRoleDie) AggregationRule

func (d *ClusterRoleDie) AggregationRule(v *rbacv1.AggregationRule) *ClusterRoleDie

AggregationRule is an optional field that describes how to build the Rules for this ClusterRole.

If AggregationRule is set, then the Rules are controller managed and direct changes to Rules will be

stomped by the controller.

func (*ClusterRoleDie) AggregationRuleDie

func (d *ClusterRoleDie) AggregationRuleDie(fn func(d *AggregationRuleDie)) *ClusterRoleDie

AggregationRuleDie mutates AggregationRule as a die.

AggregationRule is an optional field that describes how to build the Rules for this ClusterRole.

If AggregationRule is set, then the Rules are controller managed and direct changes to Rules will be

stomped by the controller.

func (*ClusterRoleDie) DeepCopy

func (d *ClusterRoleDie) DeepCopy() *ClusterRoleDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*ClusterRoleDie) DeepCopyObject

func (d *ClusterRoleDie) DeepCopyObject() runtime.Object

func (*ClusterRoleDie) DieDefaultTypeMetadata added in v0.13.0

func (d *ClusterRoleDie) DieDefaultTypeMetadata() *ClusterRoleDie

DieDefaultTypeMetadata sets the APIVersion and Kind to "rbac.authorization.k8s.io/v1" and "ClusterRole" respectively.

func (*ClusterRoleDie) DieDiff added in v0.13.0

func (d *ClusterRoleDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*ClusterRoleDie) DieFeed

DieFeed returns a new die with the provided resource.

func (*ClusterRoleDie) DieFeedJSON

func (d *ClusterRoleDie) DieFeedJSON(j []byte) *ClusterRoleDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*ClusterRoleDie) DieFeedPtr

func (d *ClusterRoleDie) DieFeedPtr(r *rbacv1.ClusterRole) *ClusterRoleDie

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*ClusterRoleDie) DieFeedRawExtension

func (d *ClusterRoleDie) DieFeedRawExtension(raw runtime.RawExtension) *ClusterRoleDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*ClusterRoleDie) DieFeedYAML

func (d *ClusterRoleDie) DieFeedYAML(y []byte) *ClusterRoleDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*ClusterRoleDie) DieFeedYAMLFile

func (d *ClusterRoleDie) DieFeedYAMLFile(name string) *ClusterRoleDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*ClusterRoleDie) DieImmutable

func (d *ClusterRoleDie) DieImmutable(immutable bool) *ClusterRoleDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*ClusterRoleDie) DiePatch added in v0.13.0

func (d *ClusterRoleDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*ClusterRoleDie) DieRelease

func (d *ClusterRoleDie) DieRelease() rbacv1.ClusterRole

DieRelease returns the resource managed by the die.

func (*ClusterRoleDie) DieReleaseJSON

func (d *ClusterRoleDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*ClusterRoleDie) DieReleasePtr

func (d *ClusterRoleDie) DieReleasePtr() *rbacv1.ClusterRole

DieReleasePtr returns a pointer to the resource managed by the die.

func (*ClusterRoleDie) DieReleaseRawExtension

func (d *ClusterRoleDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*ClusterRoleDie) DieReleaseUnstructured

func (d *ClusterRoleDie) DieReleaseUnstructured() *unstructured.Unstructured

DieReleaseUnstructured returns the resource managed by the die as an unstructured object. Panics on error.

func (*ClusterRoleDie) DieReleaseYAML

func (d *ClusterRoleDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*ClusterRoleDie) DieSeal added in v0.13.0

func (d *ClusterRoleDie) DieSeal() *ClusterRoleDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*ClusterRoleDie) DieSealFeed added in v0.13.0

func (d *ClusterRoleDie) DieSealFeed(r rbacv1.ClusterRole) *ClusterRoleDie

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*ClusterRoleDie) DieSealFeedPtr added in v0.13.0

func (d *ClusterRoleDie) DieSealFeedPtr(r *rbacv1.ClusterRole) *ClusterRoleDie

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*ClusterRoleDie) DieSealRelease added in v0.13.0

func (d *ClusterRoleDie) DieSealRelease() rbacv1.ClusterRole

DieSealRelease returns the sealed resource managed by the die.

func (*ClusterRoleDie) DieSealReleasePtr added in v0.13.0

func (d *ClusterRoleDie) DieSealReleasePtr() *rbacv1.ClusterRole

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*ClusterRoleDie) DieStamp

func (d *ClusterRoleDie) DieStamp(fn func(r *rbacv1.ClusterRole)) *ClusterRoleDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*ClusterRoleDie) DieStampAt

func (d *ClusterRoleDie) DieStampAt(jp string, fn interface{}) *ClusterRoleDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*ClusterRoleDie) DieWith

func (d *ClusterRoleDie) DieWith(fns ...func(d *ClusterRoleDie)) *ClusterRoleDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*ClusterRoleDie) GetObjectKind

func (d *ClusterRoleDie) GetObjectKind() schema.ObjectKind

func (*ClusterRoleDie) Kind

func (d *ClusterRoleDie) Kind(v string) *ClusterRoleDie

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds

func (*ClusterRoleDie) MarshalJSON

func (d *ClusterRoleDie) MarshalJSON() ([]byte, error)

func (*ClusterRoleDie) Metadata added in v0.13.0

Metadata standard object's metadata.

func (*ClusterRoleDie) MetadataDie

func (d *ClusterRoleDie) MetadataDie(fn func(d *metav1.ObjectMetaDie)) *ClusterRoleDie

MetadataDie stamps the resource's ObjectMeta field with a mutable die.

func (*ClusterRoleDie) Rules

Rules holds all the PolicyRules for this ClusterRole

func (*ClusterRoleDie) RulesDie

func (d *ClusterRoleDie) RulesDie(v ...*PolicyRuleDie) *ClusterRoleDie

RulesDie replaces Rules by collecting the released value from each die passed.

Rules holds all the PolicyRules for this ClusterRole

func (*ClusterRoleDie) TypeMetadata added in v0.13.0

func (d *ClusterRoleDie) TypeMetadata(v apismetav1.TypeMeta) *ClusterRoleDie

TypeMetadata standard object's type metadata.

func (*ClusterRoleDie) TypeMetadataDie added in v0.13.0

func (d *ClusterRoleDie) TypeMetadataDie(fn func(d *metav1.TypeMetaDie)) *ClusterRoleDie

TypeMetadataDie stamps the resource's TypeMeta field with a mutable die.

func (*ClusterRoleDie) UnmarshalJSON

func (d *ClusterRoleDie) UnmarshalJSON(b []byte) error

type PolicyRuleDie

type PolicyRuleDie struct {
	// contains filtered or unexported fields
}

func (*PolicyRuleDie) APIGroups

func (d *PolicyRuleDie) APIGroups(v ...string) *PolicyRuleDie

APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of

the enumerated resources in any API group will be allowed. "" represents the core API group and "*" represents all API groups.

func (*PolicyRuleDie) AddAPIGroups

func (d *PolicyRuleDie) AddAPIGroups(apiGroups ...string) *PolicyRuleDie

func (*PolicyRuleDie) AddAResources

func (d *PolicyRuleDie) AddAResources(resources ...string) *PolicyRuleDie

func (*PolicyRuleDie) AddNonResourceURLs

func (d *PolicyRuleDie) AddNonResourceURLs(nonResourceURLs ...string) *PolicyRuleDie

func (*PolicyRuleDie) AddResourceNames

func (d *PolicyRuleDie) AddResourceNames(resourceNames ...string) *PolicyRuleDie

func (*PolicyRuleDie) AddVerbs

func (d *PolicyRuleDie) AddVerbs(verbs ...string) *PolicyRuleDie

func (*PolicyRuleDie) DeepCopy

func (d *PolicyRuleDie) DeepCopy() *PolicyRuleDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*PolicyRuleDie) DieDiff added in v0.13.0

func (d *PolicyRuleDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*PolicyRuleDie) DieFeed

DieFeed returns a new die with the provided resource.

func (*PolicyRuleDie) DieFeedJSON

func (d *PolicyRuleDie) DieFeedJSON(j []byte) *PolicyRuleDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*PolicyRuleDie) DieFeedPtr

func (d *PolicyRuleDie) DieFeedPtr(r *rbacv1.PolicyRule) *PolicyRuleDie

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*PolicyRuleDie) DieFeedRawExtension

func (d *PolicyRuleDie) DieFeedRawExtension(raw runtime.RawExtension) *PolicyRuleDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*PolicyRuleDie) DieFeedYAML

func (d *PolicyRuleDie) DieFeedYAML(y []byte) *PolicyRuleDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*PolicyRuleDie) DieFeedYAMLFile

func (d *PolicyRuleDie) DieFeedYAMLFile(name string) *PolicyRuleDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*PolicyRuleDie) DieImmutable

func (d *PolicyRuleDie) DieImmutable(immutable bool) *PolicyRuleDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*PolicyRuleDie) DiePatch added in v0.13.0

func (d *PolicyRuleDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*PolicyRuleDie) DieRelease

func (d *PolicyRuleDie) DieRelease() rbacv1.PolicyRule

DieRelease returns the resource managed by the die.

func (*PolicyRuleDie) DieReleaseJSON

func (d *PolicyRuleDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*PolicyRuleDie) DieReleasePtr

func (d *PolicyRuleDie) DieReleasePtr() *rbacv1.PolicyRule

DieReleasePtr returns a pointer to the resource managed by the die.

func (*PolicyRuleDie) DieReleaseRawExtension

func (d *PolicyRuleDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*PolicyRuleDie) DieReleaseYAML

func (d *PolicyRuleDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*PolicyRuleDie) DieSeal added in v0.13.0

func (d *PolicyRuleDie) DieSeal() *PolicyRuleDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*PolicyRuleDie) DieSealFeed added in v0.13.0

func (d *PolicyRuleDie) DieSealFeed(r rbacv1.PolicyRule) *PolicyRuleDie

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*PolicyRuleDie) DieSealFeedPtr added in v0.13.0

func (d *PolicyRuleDie) DieSealFeedPtr(r *rbacv1.PolicyRule) *PolicyRuleDie

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*PolicyRuleDie) DieSealRelease added in v0.13.0

func (d *PolicyRuleDie) DieSealRelease() rbacv1.PolicyRule

DieSealRelease returns the sealed resource managed by the die.

func (*PolicyRuleDie) DieSealReleasePtr added in v0.13.0

func (d *PolicyRuleDie) DieSealReleasePtr() *rbacv1.PolicyRule

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*PolicyRuleDie) DieStamp

func (d *PolicyRuleDie) DieStamp(fn func(r *rbacv1.PolicyRule)) *PolicyRuleDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*PolicyRuleDie) DieStampAt

func (d *PolicyRuleDie) DieStampAt(jp string, fn interface{}) *PolicyRuleDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*PolicyRuleDie) DieWith

func (d *PolicyRuleDie) DieWith(fns ...func(d *PolicyRuleDie)) *PolicyRuleDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*PolicyRuleDie) NonResourceURLs

func (d *PolicyRuleDie) NonResourceURLs(v ...string) *PolicyRuleDie

NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path

Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding.

Rules can either apply to API resources (such as "pods" or "secrets") or non-resource URL paths (such as "/api"), but not both.

func (*PolicyRuleDie) ResourceNames

func (d *PolicyRuleDie) ResourceNames(v ...string) *PolicyRuleDie

ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed.

func (*PolicyRuleDie) Resources

func (d *PolicyRuleDie) Resources(v ...string) *PolicyRuleDie

Resources is a list of resources this rule applies to. '*' represents all resources.

func (*PolicyRuleDie) Verbs

func (d *PolicyRuleDie) Verbs(v ...string) *PolicyRuleDie

Verbs is a list of Verbs that apply to ALL the ResourceKinds contained in this rule. '*' represents all verbs.

type RoleBindingDie

type RoleBindingDie struct {
	metav1.FrozenObjectMeta
	// contains filtered or unexported fields
}

func (*RoleBindingDie) APIVersion

func (d *RoleBindingDie) APIVersion(v string) *RoleBindingDie

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources

func (*RoleBindingDie) DeepCopy

func (d *RoleBindingDie) DeepCopy() *RoleBindingDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*RoleBindingDie) DeepCopyObject

func (d *RoleBindingDie) DeepCopyObject() runtime.Object

func (*RoleBindingDie) DieDefaultTypeMetadata added in v0.13.0

func (d *RoleBindingDie) DieDefaultTypeMetadata() *RoleBindingDie

DieDefaultTypeMetadata sets the APIVersion and Kind to "rbac.authorization.k8s.io/v1" and "RoleBinding" respectively.

func (*RoleBindingDie) DieDiff added in v0.13.0

func (d *RoleBindingDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*RoleBindingDie) DieFeed

DieFeed returns a new die with the provided resource.

func (*RoleBindingDie) DieFeedJSON

func (d *RoleBindingDie) DieFeedJSON(j []byte) *RoleBindingDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*RoleBindingDie) DieFeedPtr

func (d *RoleBindingDie) DieFeedPtr(r *rbacv1.RoleBinding) *RoleBindingDie

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*RoleBindingDie) DieFeedRawExtension

func (d *RoleBindingDie) DieFeedRawExtension(raw runtime.RawExtension) *RoleBindingDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*RoleBindingDie) DieFeedYAML

func (d *RoleBindingDie) DieFeedYAML(y []byte) *RoleBindingDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*RoleBindingDie) DieFeedYAMLFile

func (d *RoleBindingDie) DieFeedYAMLFile(name string) *RoleBindingDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*RoleBindingDie) DieImmutable

func (d *RoleBindingDie) DieImmutable(immutable bool) *RoleBindingDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*RoleBindingDie) DiePatch added in v0.13.0

func (d *RoleBindingDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*RoleBindingDie) DieRelease

func (d *RoleBindingDie) DieRelease() rbacv1.RoleBinding

DieRelease returns the resource managed by the die.

func (*RoleBindingDie) DieReleaseJSON

func (d *RoleBindingDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*RoleBindingDie) DieReleasePtr

func (d *RoleBindingDie) DieReleasePtr() *rbacv1.RoleBinding

DieReleasePtr returns a pointer to the resource managed by the die.

func (*RoleBindingDie) DieReleaseRawExtension

func (d *RoleBindingDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*RoleBindingDie) DieReleaseUnstructured

func (d *RoleBindingDie) DieReleaseUnstructured() *unstructured.Unstructured

DieReleaseUnstructured returns the resource managed by the die as an unstructured object. Panics on error.

func (*RoleBindingDie) DieReleaseYAML

func (d *RoleBindingDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*RoleBindingDie) DieSeal added in v0.13.0

func (d *RoleBindingDie) DieSeal() *RoleBindingDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*RoleBindingDie) DieSealFeed added in v0.13.0

func (d *RoleBindingDie) DieSealFeed(r rbacv1.RoleBinding) *RoleBindingDie

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*RoleBindingDie) DieSealFeedPtr added in v0.13.0

func (d *RoleBindingDie) DieSealFeedPtr(r *rbacv1.RoleBinding) *RoleBindingDie

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*RoleBindingDie) DieSealRelease added in v0.13.0

func (d *RoleBindingDie) DieSealRelease() rbacv1.RoleBinding

DieSealRelease returns the sealed resource managed by the die.

func (*RoleBindingDie) DieSealReleasePtr added in v0.13.0

func (d *RoleBindingDie) DieSealReleasePtr() *rbacv1.RoleBinding

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*RoleBindingDie) DieStamp

func (d *RoleBindingDie) DieStamp(fn func(r *rbacv1.RoleBinding)) *RoleBindingDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*RoleBindingDie) DieStampAt

func (d *RoleBindingDie) DieStampAt(jp string, fn interface{}) *RoleBindingDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*RoleBindingDie) DieWith

func (d *RoleBindingDie) DieWith(fns ...func(d *RoleBindingDie)) *RoleBindingDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*RoleBindingDie) GetObjectKind

func (d *RoleBindingDie) GetObjectKind() schema.ObjectKind

func (*RoleBindingDie) Kind

func (d *RoleBindingDie) Kind(v string) *RoleBindingDie

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds

func (*RoleBindingDie) MarshalJSON

func (d *RoleBindingDie) MarshalJSON() ([]byte, error)

func (*RoleBindingDie) Metadata added in v0.13.0

Metadata standard object's metadata.

func (*RoleBindingDie) MetadataDie

func (d *RoleBindingDie) MetadataDie(fn func(d *metav1.ObjectMetaDie)) *RoleBindingDie

MetadataDie stamps the resource's ObjectMeta field with a mutable die.

func (*RoleBindingDie) RoleRef

RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace.

If the RoleRef cannot be resolved, the Authorizer must return an error.

This field is immutable.

func (*RoleBindingDie) RoleRefDie

func (d *RoleBindingDie) RoleRefDie(fn func(d *RoleRefDie)) *RoleBindingDie

RoleRefDie mutates RoleRef as a die.

RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace.

If the RoleRef cannot be resolved, the Authorizer must return an error.

This field is immutable.

func (*RoleBindingDie) Subjects

func (d *RoleBindingDie) Subjects(v ...rbacv1.Subject) *RoleBindingDie

Subjects holds references to the objects the role applies to.

func (*RoleBindingDie) SubjectsDie

func (d *RoleBindingDie) SubjectsDie(v ...*SubjectDie) *RoleBindingDie

SubjectsDie replaces Subjects by collecting the released value from each die passed.

Subjects holds references to the objects the role applies to.

func (*RoleBindingDie) TypeMetadata added in v0.13.0

func (d *RoleBindingDie) TypeMetadata(v apismetav1.TypeMeta) *RoleBindingDie

TypeMetadata standard object's type metadata.

func (*RoleBindingDie) TypeMetadataDie added in v0.13.0

func (d *RoleBindingDie) TypeMetadataDie(fn func(d *metav1.TypeMetaDie)) *RoleBindingDie

TypeMetadataDie stamps the resource's TypeMeta field with a mutable die.

func (*RoleBindingDie) UnmarshalJSON

func (d *RoleBindingDie) UnmarshalJSON(b []byte) error

type RoleDie

type RoleDie struct {
	metav1.FrozenObjectMeta
	// contains filtered or unexported fields
}

func (*RoleDie) APIVersion

func (d *RoleDie) APIVersion(v string) *RoleDie

APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources

func (*RoleDie) AddRuleDie

func (d *RoleDie) AddRuleDie(rule *PolicyRuleDie) *RoleDie

func (*RoleDie) DeepCopy

func (d *RoleDie) DeepCopy() *RoleDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*RoleDie) DeepCopyObject

func (d *RoleDie) DeepCopyObject() runtime.Object

func (*RoleDie) DieDefaultTypeMetadata added in v0.13.0

func (d *RoleDie) DieDefaultTypeMetadata() *RoleDie

DieDefaultTypeMetadata sets the APIVersion and Kind to "rbac.authorization.k8s.io/v1" and "Role" respectively.

func (*RoleDie) DieDiff added in v0.13.0

func (d *RoleDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*RoleDie) DieFeed

func (d *RoleDie) DieFeed(r rbacv1.Role) *RoleDie

DieFeed returns a new die with the provided resource.

func (*RoleDie) DieFeedJSON

func (d *RoleDie) DieFeedJSON(j []byte) *RoleDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*RoleDie) DieFeedPtr

func (d *RoleDie) DieFeedPtr(r *rbacv1.Role) *RoleDie

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*RoleDie) DieFeedRawExtension

func (d *RoleDie) DieFeedRawExtension(raw runtime.RawExtension) *RoleDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*RoleDie) DieFeedYAML

func (d *RoleDie) DieFeedYAML(y []byte) *RoleDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*RoleDie) DieFeedYAMLFile

func (d *RoleDie) DieFeedYAMLFile(name string) *RoleDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*RoleDie) DieImmutable

func (d *RoleDie) DieImmutable(immutable bool) *RoleDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*RoleDie) DiePatch added in v0.13.0

func (d *RoleDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*RoleDie) DieRelease

func (d *RoleDie) DieRelease() rbacv1.Role

DieRelease returns the resource managed by the die.

func (*RoleDie) DieReleaseJSON

func (d *RoleDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*RoleDie) DieReleasePtr

func (d *RoleDie) DieReleasePtr() *rbacv1.Role

DieReleasePtr returns a pointer to the resource managed by the die.

func (*RoleDie) DieReleaseRawExtension

func (d *RoleDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*RoleDie) DieReleaseUnstructured

func (d *RoleDie) DieReleaseUnstructured() *unstructured.Unstructured

DieReleaseUnstructured returns the resource managed by the die as an unstructured object. Panics on error.

func (*RoleDie) DieReleaseYAML

func (d *RoleDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*RoleDie) DieSeal added in v0.13.0

func (d *RoleDie) DieSeal() *RoleDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*RoleDie) DieSealFeed added in v0.13.0

func (d *RoleDie) DieSealFeed(r rbacv1.Role) *RoleDie

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*RoleDie) DieSealFeedPtr added in v0.13.0

func (d *RoleDie) DieSealFeedPtr(r *rbacv1.Role) *RoleDie

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*RoleDie) DieSealRelease added in v0.13.0

func (d *RoleDie) DieSealRelease() rbacv1.Role

DieSealRelease returns the sealed resource managed by the die.

func (*RoleDie) DieSealReleasePtr added in v0.13.0

func (d *RoleDie) DieSealReleasePtr() *rbacv1.Role

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*RoleDie) DieStamp

func (d *RoleDie) DieStamp(fn func(r *rbacv1.Role)) *RoleDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*RoleDie) DieStampAt

func (d *RoleDie) DieStampAt(jp string, fn interface{}) *RoleDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*RoleDie) DieWith

func (d *RoleDie) DieWith(fns ...func(d *RoleDie)) *RoleDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*RoleDie) GetObjectKind

func (d *RoleDie) GetObjectKind() schema.ObjectKind

func (*RoleDie) Kind

func (d *RoleDie) Kind(v string) *RoleDie

Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds

func (*RoleDie) MarshalJSON

func (d *RoleDie) MarshalJSON() ([]byte, error)

func (*RoleDie) Metadata added in v0.13.0

func (d *RoleDie) Metadata(v apismetav1.ObjectMeta) *RoleDie

Metadata standard object's metadata.

func (*RoleDie) MetadataDie

func (d *RoleDie) MetadataDie(fn func(d *metav1.ObjectMetaDie)) *RoleDie

MetadataDie stamps the resource's ObjectMeta field with a mutable die.

func (*RoleDie) Rules

func (d *RoleDie) Rules(v ...rbacv1.PolicyRule) *RoleDie

Rules holds all the PolicyRules for this Role

func (*RoleDie) RulesDie

func (d *RoleDie) RulesDie(v ...*PolicyRuleDie) *RoleDie

RulesDie replaces Rules by collecting the released value from each die passed.

Rules holds all the PolicyRules for this Role

func (*RoleDie) TypeMetadata added in v0.13.0

func (d *RoleDie) TypeMetadata(v apismetav1.TypeMeta) *RoleDie

TypeMetadata standard object's type metadata.

func (*RoleDie) TypeMetadataDie added in v0.13.0

func (d *RoleDie) TypeMetadataDie(fn func(d *metav1.TypeMetaDie)) *RoleDie

TypeMetadataDie stamps the resource's TypeMeta field with a mutable die.

func (*RoleDie) UnmarshalJSON

func (d *RoleDie) UnmarshalJSON(b []byte) error

type RoleRefDie

type RoleRefDie struct {
	// contains filtered or unexported fields
}

func (*RoleRefDie) APIGroup

func (d *RoleRefDie) APIGroup(v string) *RoleRefDie

APIGroup is the group for the resource being referenced

func (*RoleRefDie) DeepCopy

func (d *RoleRefDie) DeepCopy() *RoleRefDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*RoleRefDie) DieDiff added in v0.13.0

func (d *RoleRefDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*RoleRefDie) DieFeed

func (d *RoleRefDie) DieFeed(r rbacv1.RoleRef) *RoleRefDie

DieFeed returns a new die with the provided resource.

func (*RoleRefDie) DieFeedJSON

func (d *RoleRefDie) DieFeedJSON(j []byte) *RoleRefDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*RoleRefDie) DieFeedPtr

func (d *RoleRefDie) DieFeedPtr(r *rbacv1.RoleRef) *RoleRefDie

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*RoleRefDie) DieFeedRawExtension

func (d *RoleRefDie) DieFeedRawExtension(raw runtime.RawExtension) *RoleRefDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*RoleRefDie) DieFeedYAML

func (d *RoleRefDie) DieFeedYAML(y []byte) *RoleRefDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*RoleRefDie) DieFeedYAMLFile

func (d *RoleRefDie) DieFeedYAMLFile(name string) *RoleRefDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*RoleRefDie) DieImmutable

func (d *RoleRefDie) DieImmutable(immutable bool) *RoleRefDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*RoleRefDie) DiePatch added in v0.13.0

func (d *RoleRefDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*RoleRefDie) DieRelease

func (d *RoleRefDie) DieRelease() rbacv1.RoleRef

DieRelease returns the resource managed by the die.

func (*RoleRefDie) DieReleaseJSON

func (d *RoleRefDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*RoleRefDie) DieReleasePtr

func (d *RoleRefDie) DieReleasePtr() *rbacv1.RoleRef

DieReleasePtr returns a pointer to the resource managed by the die.

func (*RoleRefDie) DieReleaseRawExtension

func (d *RoleRefDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*RoleRefDie) DieReleaseYAML

func (d *RoleRefDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*RoleRefDie) DieSeal added in v0.13.0

func (d *RoleRefDie) DieSeal() *RoleRefDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*RoleRefDie) DieSealFeed added in v0.13.0

func (d *RoleRefDie) DieSealFeed(r rbacv1.RoleRef) *RoleRefDie

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*RoleRefDie) DieSealFeedPtr added in v0.13.0

func (d *RoleRefDie) DieSealFeedPtr(r *rbacv1.RoleRef) *RoleRefDie

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*RoleRefDie) DieSealRelease added in v0.13.0

func (d *RoleRefDie) DieSealRelease() rbacv1.RoleRef

DieSealRelease returns the sealed resource managed by the die.

func (*RoleRefDie) DieSealReleasePtr added in v0.13.0

func (d *RoleRefDie) DieSealReleasePtr() *rbacv1.RoleRef

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*RoleRefDie) DieStamp

func (d *RoleRefDie) DieStamp(fn func(r *rbacv1.RoleRef)) *RoleRefDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*RoleRefDie) DieStampAt

func (d *RoleRefDie) DieStampAt(jp string, fn interface{}) *RoleRefDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*RoleRefDie) DieWith

func (d *RoleRefDie) DieWith(fns ...func(d *RoleRefDie)) *RoleRefDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*RoleRefDie) Kind

func (d *RoleRefDie) Kind(v string) *RoleRefDie

Kind is the type of resource being referenced

func (*RoleRefDie) Name

func (d *RoleRefDie) Name(v string) *RoleRefDie

Name is the name of resource being referenced

type SubjectDie

type SubjectDie struct {
	// contains filtered or unexported fields
}

func (*SubjectDie) APIGroup

func (d *SubjectDie) APIGroup(v string) *SubjectDie

APIGroup holds the API group of the referenced subject.

Defaults to "" for ServiceAccount subjects.

Defaults to "rbac.authorization.k8s.io" for User and Group subjects.

func (*SubjectDie) DeepCopy

func (d *SubjectDie) DeepCopy() *SubjectDie

DeepCopy returns a new die with equivalent state. Useful for snapshotting a mutable die.

func (*SubjectDie) DieDiff added in v0.13.0

func (d *SubjectDie) DieDiff(opts ...cmp.Option) string

DieDiff uses cmp.Diff to compare the current value of the die with the sealed value.

func (*SubjectDie) DieFeed

func (d *SubjectDie) DieFeed(r rbacv1.Subject) *SubjectDie

DieFeed returns a new die with the provided resource.

func (*SubjectDie) DieFeedJSON

func (d *SubjectDie) DieFeedJSON(j []byte) *SubjectDie

DieFeedJSON returns a new die with the provided JSON. Panics on error.

func (*SubjectDie) DieFeedPtr

func (d *SubjectDie) DieFeedPtr(r *rbacv1.Subject) *SubjectDie

DieFeedPtr returns a new die with the provided resource pointer. If the resource is nil, the empty value is used instead.

func (*SubjectDie) DieFeedRawExtension

func (d *SubjectDie) DieFeedRawExtension(raw runtime.RawExtension) *SubjectDie

DieFeedRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*SubjectDie) DieFeedYAML

func (d *SubjectDie) DieFeedYAML(y []byte) *SubjectDie

DieFeedYAML returns a new die with the provided YAML. Panics on error.

func (*SubjectDie) DieFeedYAMLFile

func (d *SubjectDie) DieFeedYAMLFile(name string) *SubjectDie

DieFeedYAMLFile returns a new die loading YAML from a file path. Panics on error.

func (*SubjectDie) DieImmutable

func (d *SubjectDie) DieImmutable(immutable bool) *SubjectDie

DieImmutable returns a new die for the current die's state that is either mutable (`false`) or immutable (`true`).

func (*SubjectDie) DiePatch added in v0.13.0

func (d *SubjectDie) DiePatch(patchType types.PatchType) ([]byte, error)

DiePatch generates a patch between the current value of the die and the sealed value.

func (*SubjectDie) DieRelease

func (d *SubjectDie) DieRelease() rbacv1.Subject

DieRelease returns the resource managed by the die.

func (*SubjectDie) DieReleaseJSON

func (d *SubjectDie) DieReleaseJSON() []byte

DieReleaseJSON returns the resource managed by the die as JSON. Panics on error.

func (*SubjectDie) DieReleasePtr

func (d *SubjectDie) DieReleasePtr() *rbacv1.Subject

DieReleasePtr returns a pointer to the resource managed by the die.

func (*SubjectDie) DieReleaseRawExtension

func (d *SubjectDie) DieReleaseRawExtension() runtime.RawExtension

DieReleaseRawExtension returns the resource managed by the die as an raw extension. Panics on error.

func (*SubjectDie) DieReleaseYAML

func (d *SubjectDie) DieReleaseYAML() []byte

DieReleaseYAML returns the resource managed by the die as YAML. Panics on error.

func (*SubjectDie) DieSeal added in v0.13.0

func (d *SubjectDie) DieSeal() *SubjectDie

DieSeal returns a new die for the current die's state that is sealed for comparison in future diff and patch operations.

func (*SubjectDie) DieSealFeed added in v0.13.0

func (d *SubjectDie) DieSealFeed(r rbacv1.Subject) *SubjectDie

DieSealFeed returns a new die for the current die's state that uses a specific resource for comparison in future diff and patch operations.

func (*SubjectDie) DieSealFeedPtr added in v0.13.0

func (d *SubjectDie) DieSealFeedPtr(r *rbacv1.Subject) *SubjectDie

DieSealFeedPtr returns a new die for the current die's state that uses a specific resource pointer for comparison in future diff and patch operations. If the resource is nil, the empty value is used instead.

func (*SubjectDie) DieSealRelease added in v0.13.0

func (d *SubjectDie) DieSealRelease() rbacv1.Subject

DieSealRelease returns the sealed resource managed by the die.

func (*SubjectDie) DieSealReleasePtr added in v0.13.0

func (d *SubjectDie) DieSealReleasePtr() *rbacv1.Subject

DieSealReleasePtr returns the sealed resource pointer managed by the die.

func (*SubjectDie) DieStamp

func (d *SubjectDie) DieStamp(fn func(r *rbacv1.Subject)) *SubjectDie

DieStamp returns a new die with the resource passed to the callback function. The resource is mutable.

func (*SubjectDie) DieStampAt

func (d *SubjectDie) DieStampAt(jp string, fn interface{}) *SubjectDie

Experimental: DieStampAt uses a JSON path (http://goessner.net/articles/JsonPath/) expression to stamp portions of the resource. The callback is invoked with each JSON path match. Panics if the callback function does not accept a single argument of the same type or a pointer to that type as found on the resource at the target location.

Future iterations will improve type coercion from the resource to the callback argument.

func (*SubjectDie) DieWith

func (d *SubjectDie) DieWith(fns ...func(d *SubjectDie)) *SubjectDie

DieWith returns a new die after passing the current die to the callback function. The passed die is mutable.

func (*SubjectDie) Kind

func (d *SubjectDie) Kind(v string) *SubjectDie

Kind of object being referenced. Values defined by this API group are "User", "Group", and "ServiceAccount".

If the Authorizer does not recognized the kind value, the Authorizer should report an error.

func (*SubjectDie) Name

func (d *SubjectDie) Name(v string) *SubjectDie

Name of the object being referenced.

func (*SubjectDie) Namespace

func (d *SubjectDie) Namespace(v string) *SubjectDie

Namespace of the referenced object. If the object kind is non-namespace, such as "User" or "Group", and this value is not empty

the Authorizer should report an error.

Jump to

Keyboard shortcuts

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