Package org.cdk8s.plus28.k8s
Class NamedRuleWithOperationsV1Alpha1.Builder
- java.lang.Object
-
- org.cdk8s.plus28.k8s.NamedRuleWithOperationsV1Alpha1.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<NamedRuleWithOperationsV1Alpha1>
- Enclosing interface:
- NamedRuleWithOperationsV1Alpha1
@Stability(Stable) public static final class NamedRuleWithOperationsV1Alpha1.Builder extends Object implements software.amazon.jsii.Builder<NamedRuleWithOperationsV1Alpha1>
A builder forNamedRuleWithOperationsV1Alpha1
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NamedRuleWithOperationsV1Alpha1.BuilderapiGroups(List<String> apiGroups)Sets the value ofNamedRuleWithOperationsV1Alpha1.getApiGroups()NamedRuleWithOperationsV1Alpha1.BuilderapiVersions(List<String> apiVersions)Sets the value ofNamedRuleWithOperationsV1Alpha1.getApiVersions()NamedRuleWithOperationsV1Alpha1build()Builds the configured instance.NamedRuleWithOperationsV1Alpha1.Builderoperations(List<String> operations)Sets the value ofNamedRuleWithOperationsV1Alpha1.getOperations()NamedRuleWithOperationsV1Alpha1.BuilderresourceNames(List<String> resourceNames)Sets the value ofNamedRuleWithOperationsV1Alpha1.getResourceNames()NamedRuleWithOperationsV1Alpha1.Builderresources(List<String> resources)Sets the value ofNamedRuleWithOperationsV1Alpha1.getResources()NamedRuleWithOperationsV1Alpha1.Builderscope(String scope)Sets the value ofNamedRuleWithOperationsV1Alpha1.getScope()
-
-
-
Method Detail
-
apiGroups
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1.Builder apiGroups(List<String> apiGroups)
Sets the value ofNamedRuleWithOperationsV1Alpha1.getApiGroups()- Parameters:
apiGroups- APIGroups is the API groups the resources belong to. '' is all groups. If '' is present, the length of the slice must be one. Required.- Returns:
this
-
apiVersions
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1.Builder apiVersions(List<String> apiVersions)
Sets the value ofNamedRuleWithOperationsV1Alpha1.getApiVersions()- Parameters:
apiVersions- APIVersions is the API versions the resources belong to. '' is all versions. If '' is present, the length of the slice must be one. Required.- Returns:
this
-
operations
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1.Builder operations(List<String> operations)
Sets the value ofNamedRuleWithOperationsV1Alpha1.getOperations()- Parameters:
operations- Operations is the operations the admission hook cares about - CREATE, UPDATE, DELETE, CONNECT or * for all of those operations and any future admission operations that are added. If '*' is present, the length of the slice must be one. Required.- Returns:
this
-
resourceNames
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1.Builder resourceNames(List<String> resourceNames)
Sets the value ofNamedRuleWithOperationsV1Alpha1.getResourceNames()- Parameters:
resourceNames- ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed.- Returns:
this
-
resources
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1.Builder resources(List<String> resources)
Sets the value ofNamedRuleWithOperationsV1Alpha1.getResources()- Parameters:
resources- Resources is a list of resources this rule applies to. For example: 'pods' means pods. 'pods/log' means the log subresource of pods. '' means all resources, but not subresources. 'pods/' means all subresources of pods. '/scale' means all scale subresources. '/*' means all resources and their subresources.If wildcard is present, the validation rule will ensure resources do not overlap with each other.
Depending on the enclosing object, subresources might not be allowed. Required.
- Returns:
this
-
scope
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1.Builder scope(String scope)
Sets the value ofNamedRuleWithOperationsV1Alpha1.getScope()- Parameters:
scope- scope specifies the scope of this rule. Valid values are "Cluster", "Namespaced", and "" "Cluster" means that only cluster-scoped resources will match this rule. Namespace API objects are cluster-scoped. "Namespaced" means that only namespaced resources will match this rule. "" means that there are no scope restrictions. Subresources match the scope of their parent resource. Default is "*".- Returns:
this
-
build
@Stability(Stable) public NamedRuleWithOperationsV1Alpha1 build()
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<NamedRuleWithOperationsV1Alpha1>- Returns:
- a new instance of
NamedRuleWithOperationsV1Alpha1 - Throws:
NullPointerException- if any required attribute was not provided
-
-