Package org.jdrupes.vmoperator.common
Class K8sDynamicModelsBase<T extends K8sDynamicModel>
java.lang.Object
org.jdrupes.vmoperator.common.K8sDynamicModelsBase<T>
- All Implemented Interfaces:
io.kubernetes.client.common.KubernetesListObject
,io.kubernetes.client.common.KubernetesType
- Direct Known Subclasses:
K8sDynamicModels
,VmDefinitionModels
public class K8sDynamicModelsBase<T extends K8sDynamicModel>
extends Object
implements io.kubernetes.client.common.KubernetesListObject
Represents a list of Kubernetes objects each of which is
represented using a JSON data structure.
Some information that is common to all Kubernetes objects,
notably the metadata, is made available through the methods
defined by KubernetesListObject
.
-
Constructor Summary
ConstructorDescriptionK8sDynamicModelsBase
(Class<T> itemClass, com.google.gson.Gson delegate, com.google.gson.JsonObject data) Initialize the object list using the given JSON data. -
Method Summary
Modifier and TypeMethodDescriptionGets the API version.com.google.gson.JsonObject
data()
Returns the JSON representation of this object.boolean
getItems()
getKind()
io.kubernetes.client.openapi.models.V1ListMeta
int
hashCode()
kind()
Gets the kind.io.kubernetes.client.openapi.models.V1ListMeta
metadata()
Gets the metadata.void
setApiVersion
(String apiVersion) Sets the api version.void
Sets the kind.void
setMetadata
(io.kubernetes.client.openapi.models.V1ListMeta objectMeta) Sets the metadata.
-
Constructor Details
-
K8sDynamicModelsBase
public K8sDynamicModelsBase(Class<T> itemClass, com.google.gson.Gson delegate, com.google.gson.JsonObject data) Initialize the object list using the given JSON data.- Parameters:
itemClass
- the item classdelegate
- the gson instance to use for extracting structured datadata
- the data
-
-
Method Details
-
getApiVersion
- Specified by:
getApiVersion
in interfaceio.kubernetes.client.common.KubernetesType
-
apiVersion
Gets the API version.(Abbreviated method name for convenience.)
- Returns:
- the API version
-
getKind
- Specified by:
getKind
in interfaceio.kubernetes.client.common.KubernetesType
-
kind
Gets the kind.(Abbreviated method name for convenience.)
- Returns:
- the kind
-
getMetadata
- Specified by:
getMetadata
in interfaceio.kubernetes.client.common.KubernetesListObject
-
metadata
Gets the metadata.(Abbreviated method name for convenience.)
- Returns:
- the metadata
-
data
Returns the JSON representation of this object.- Returns:
- the JOSN representation
-
getItems
- Specified by:
getItems
in interfaceio.kubernetes.client.common.KubernetesListObject
-
setApiVersion
Sets the api version.- Parameters:
apiVersion
- the new api version
-
setKind
Sets the kind.- Parameters:
kind
- the new kind
-
setMetadata
Sets the metadata.- Parameters:
objectMeta
- the new metadata
-
hashCode
-
equals
-