Package org.cdk8s.plus24
Class Namespace
- java.lang.Object
-
- software.amazon.jsii.JsiiObject
-
- software.constructs.Construct
-
- org.cdk8s.plus24.Resource
-
- org.cdk8s.plus24.Namespace
-
- All Implemented Interfaces:
IApiEndpoint
,IApiResource
,INamespaceSelector
,INetworkPolicyPeer
,IResource
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.75.0 (build 63bb957)", date="2023-02-20T02:42:01.893Z") @Stability(Stable) public class Namespace extends Resource implements INamespaceSelector, INetworkPolicyPeer
In Kubernetes, namespaces provides a mechanism for isolating groups of resources within a single cluster.Names of resources need to be unique within a namespace, but not across namespaces. Namespace-based scoping is applicable only for namespaced objects (e.g. Deployments, Services, etc) and not for cluster-wide objects (e.g. StorageClass, Nodes, PersistentVolumes, etc).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Namespace.Builder
A fluent builder forNamespace
.-
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
-
Nested classes/interfaces inherited from interface org.cdk8s.plus24.IApiEndpoint
IApiEndpoint.Jsii$Default
-
Nested classes/interfaces inherited from interface org.cdk8s.plus24.IApiResource
IApiResource.Jsii$Default
-
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
-
Nested classes/interfaces inherited from interface org.cdk8s.plus24.INamespaceSelector
INamespaceSelector.Jsii$Default, INamespaceSelector.Jsii$Proxy
-
Nested classes/interfaces inherited from interface org.cdk8s.plus24.INetworkPolicyPeer
INetworkPolicyPeer.Jsii$Default, INetworkPolicyPeer.Jsii$Proxy
-
Nested classes/interfaces inherited from interface org.cdk8s.plus24.IResource
IResource.Jsii$Default
-
-
Field Summary
Fields Modifier and Type Field Description static String
NAME_LABEL
-
Constructor Summary
Constructors Modifier Constructor Description protected
Namespace(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
protected
Namespace(software.amazon.jsii.JsiiObjectRef objRef)
Namespace(software.constructs.Construct scope, String id)
Namespace(software.constructs.Construct scope, String id, NamespaceProps props)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.cdk8s.ApiObject
getApiObject()
The underlying cdk8s API object.String
getResourceType()
The name of a resource type as it appears in the relevant API endpoint.NamespaceSelectorConfig
toNamespaceSelectorConfig()
Return the configuration of this selector.NetworkPolicyPeerConfig
toNetworkPolicyPeerConfig()
Return the configuration of this peer.IPodSelector
toPodSelector()
Convert the peer into a pod selector, if possible.-
Methods inherited from class org.cdk8s.plus24.Resource
asApiResource, asNonApiResource, getApiGroup, getApiVersion, getKind, getMetadata, getName, getPermissions, getResourceName
-
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
-
-
-
-
Field Detail
-
NAME_LABEL
@Stability(Stable) public static final String NAME_LABEL
-
-
Constructor Detail
-
Namespace
protected Namespace(software.amazon.jsii.JsiiObjectRef objRef)
-
Namespace
protected Namespace(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
-
Namespace
@Stability(Stable) public Namespace(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable NamespaceProps props)
- Parameters:
scope
- This parameter is required.id
- This parameter is required.props
-
-
Namespace
@Stability(Stable) public Namespace(@NotNull software.constructs.Construct scope, @NotNull String id)
- Parameters:
scope
- This parameter is required.id
- This parameter is required.
-
-
Method Detail
-
toNamespaceSelectorConfig
@Stability(Stable) @NotNull public NamespaceSelectorConfig toNamespaceSelectorConfig()
Return the configuration of this selector.- Specified by:
toNamespaceSelectorConfig
in interfaceINamespaceSelector
- See Also:
- INamespaceSelector.toNamespaceSelectorConfig()
-
toNetworkPolicyPeerConfig
@Stability(Stable) @NotNull public NetworkPolicyPeerConfig toNetworkPolicyPeerConfig()
Return the configuration of this peer.- Specified by:
toNetworkPolicyPeerConfig
in interfaceINetworkPolicyPeer
- See Also:
- INetworkPolicyPeer.toNetworkPolicyPeerConfig()
-
toPodSelector
@Stability(Stable) @Nullable public IPodSelector toPodSelector()
Convert the peer into a pod selector, if possible.- Specified by:
toPodSelector
in interfaceINetworkPolicyPeer
- See Also:
- INetworkPolicyPeer.toPodSelector()
-
getApiObject
@Stability(Stable) @NotNull protected org.cdk8s.ApiObject getApiObject()
The underlying cdk8s API object.- Specified by:
getApiObject
in classResource
- See Also:
- base.Resource.apiObject
-
getResourceType
@Stability(Stable) @NotNull public String getResourceType()
The name of a resource type as it appears in the relevant API endpoint.- Specified by:
getResourceType
in interfaceIApiResource
- Specified by:
getResourceType
in classResource
- See Also:
- https://kubernetes.io/docs/reference/access-authn-authz/rbac/#referring-to-resources
-
-