Class K8sDynamicModel

java.lang.Object
org.jdrupes.vmoperator.common.K8sDynamicModel
All Implemented Interfaces:
io.kubernetes.client.common.KubernetesObject, io.kubernetes.client.common.KubernetesType
Direct Known Subclasses:
VmDefinitionModel

public class K8sDynamicModel extends Object implements io.kubernetes.client.common.KubernetesObject
Represents a Kubernetes object 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 KubernetesObject.

  • Constructor Details

    • K8sDynamicModel

      public K8sDynamicModel(com.google.gson.Gson delegate, com.google.gson.JsonObject json)
      Instantiates a new model from the JSON representation.
      Parameters:
      delegate - the gson instance to use for extracting structured data
      json - the JSON
  • Method Details

    • getApiVersion

      Specified by:
      getApiVersion in interface io.kubernetes.client.common.KubernetesType
    • apiVersion

      public String apiVersion()
      Gets the API version.

      (Abbreviated method name for convenience.)

      Returns:
      the API version
    • getKind

      public String getKind()
      Specified by:
      getKind in interface io.kubernetes.client.common.KubernetesType
    • kind

      public String kind()
      Gets the kind.

      (Abbreviated method name for convenience.)

      Returns:
      the kind
    • getMetadata

      public io.kubernetes.client.openapi.models.V1ObjectMeta getMetadata()
      Specified by:
      getMetadata in interface io.kubernetes.client.common.KubernetesObject
    • metadata

      public io.kubernetes.client.openapi.models.V1ObjectMeta metadata()
      Gets the metadata.

      (Abbreviated method name for convenience.)

      Returns:
      the metadata
    • data

      public com.google.gson.JsonObject data()
      Gets the data.
      Returns:
      the data
    • status

      public com.google.gson.JsonObject status()
      Convenience method for getting the status.
      Returns:
      the JSON object describing the status
    • toString

      public String toString()
      Overrides:
      toString in class Object