Package org.cdk8s.plus23
Class Resource
- java.lang.Object
-
- software.amazon.jsii.JsiiObject
-
- software.constructs.Construct
-
- org.cdk8s.plus23.Resource
-
- All Implemented Interfaces:
IApiEndpoint,IApiResource,IResource,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
- Direct Known Subclasses:
AbstractPod,ClusterRole,ClusterRoleBinding,ConfigMap,Ingress,Namespace,NetworkPolicy,PersistentVolume,PersistentVolumeClaim,Role,RoleBinding,Secret,Service,ServiceAccount
@Generated(value="jsii-pacmak/1.61.0 (build abf4039)", date="2022-07-06T20:17:23.691Z") @Stability(Stable) public abstract class Resource extends software.constructs.Construct implements IResource, IApiResource, IApiEndpoint
Base class for all Kubernetes objects in stdk8s.Represents a single resource.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
-
Nested classes/interfaces inherited from interface org.cdk8s.plus23.IApiEndpoint
IApiEndpoint.Jsii$Default
-
Nested classes/interfaces inherited from interface org.cdk8s.plus23.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.plus23.IResource
IResource.Jsii$Default
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description IApiResourceasApiResource()Return the IApiResource this object represents.StringasNonApiResource()Return the non resource url this object represents.StringgetApiGroup()The group portion of the API version (e.g.protected abstract org.cdk8s.ApiObjectgetApiObject()The underlying cdk8s API object.StringgetApiVersion()The object's API version (e.g.StringgetKind()The object kind (e.g.org.cdk8s.ApiObjectMetadataDefinitiongetMetadata()StringgetName()The name of this API object.ResourcePermissionsgetPermissions()StringgetResourceName()The unique, namespace-global, name of an object inside the Kubernetes cluster.abstract StringgetResourceType()The name of a resource type as it appears in the relevant API endpoint.-
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
-
-
-
-
Constructor Detail
-
Resource
protected Resource(software.amazon.jsii.JsiiObjectRef objRef)
-
Resource
protected Resource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
-
Resource
@Stability(Stable) protected Resource(@NotNull software.constructs.Construct scope, @NotNull String id)- Parameters:
scope- This parameter is required.id- This parameter is required.
-
-
Method Detail
-
asApiResource
@Stability(Stable) @Nullable public IApiResource asApiResource()
Return the IApiResource this object represents.- Specified by:
asApiResourcein interfaceIApiEndpoint
-
asNonApiResource
@Stability(Stable) @Nullable public String asNonApiResource()
Return the non resource url this object represents.- Specified by:
asNonApiResourcein interfaceIApiEndpoint
-
getApiGroup
@Stability(Stable) @NotNull public String getApiGroup()
The group portion of the API version (e.g. "authorization.k8s.io").- Specified by:
getApiGroupin interfaceIApiResource- Specified by:
getApiGroupin interfaceIResource
-
getApiObject
@Stability(Stable) @NotNull protected abstract org.cdk8s.ApiObject getApiObject()
The underlying cdk8s API object.
-
getApiVersion
@Stability(Stable) @NotNull public String getApiVersion()
The object's API version (e.g. "authorization.k8s.io/v1").- Specified by:
getApiVersionin interfaceIResource
-
getKind
@Stability(Stable) @NotNull public String getKind()
The object kind (e.g. "Deployment").
-
getMetadata
@Stability(Stable) @NotNull public org.cdk8s.ApiObjectMetadataDefinition getMetadata()
-
getName
@Stability(Stable) @NotNull public String getName()
The name of this API object.
-
getPermissions
@Stability(Stable) @NotNull public ResourcePermissions getPermissions()
-
getResourceType
@Stability(Stable) @NotNull public abstract String getResourceType()
The name of a resource type as it appears in the relevant API endpoint.- Specified by:
getResourceTypein interfaceIApiResource- See Also:
- https://kubernetes.io/docs/reference/access-authn-authz/rbac/#referring-to-resources
-
getResourceName
@Stability(Stable) @Nullable public String getResourceName()
The unique, namespace-global, name of an object inside the Kubernetes cluster.If this is omitted, the ApiResource should represent all objects of the given type.
- Specified by:
getResourceNamein interfaceIApiResource
-
-