Class V1DeviceClassSpec

java.lang.Object
io.kubernetes.client.openapi.models.V1DeviceClassSpec

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", date="2025-09-11T18:00:16.154662Z[Etc/UTC]", comments="Generator version: 7.13.0") public class V1DeviceClassSpec extends Object
DeviceClassSpec is used in a [DeviceClass] to define what can be allocated and how to configure it.
  • Field Details

  • Constructor Details

    • V1DeviceClassSpec

      public V1DeviceClassSpec()
  • Method Details

    • config

      public V1DeviceClassSpec config(@Nullable List<V1DeviceClassConfiguration> config)
    • addConfigItem

      public V1DeviceClassSpec addConfigItem(V1DeviceClassConfiguration configItem)
    • getConfig

      @Nullable public List<V1DeviceClassConfiguration> getConfig()
      Config defines configuration parameters that apply to each device that is claimed via this class. Some classses may potentially be satisfied by multiple drivers, so each instance of a vendor configuration applies to exactly one driver. They are passed to the driver, but are not considered while allocating the claim.
      Returns:
      config
    • setConfig

      public void setConfig(@Nullable List<V1DeviceClassConfiguration> config)
    • extendedResourceName

      public V1DeviceClassSpec extendedResourceName(@Nullable String extendedResourceName)
    • getExtendedResourceName

      @Nullable public String getExtendedResourceName()
      ExtendedResourceName is the extended resource name for the devices of this class. The devices of this class can be used to satisfy a pod's extended resource requests. It has the same format as the name of a pod's extended resource. It should be unique among all the device classes in a cluster. If two device classes have the same name, then the class created later is picked to satisfy a pod's extended resource requests. If two classes are created at the same time, then the name of the class lexicographically sorted first is picked. This is an alpha field.
      Returns:
      extendedResourceName
    • setExtendedResourceName

      public void setExtendedResourceName(@Nullable String extendedResourceName)
    • selectors

      public V1DeviceClassSpec selectors(@Nullable List<V1DeviceSelector> selectors)
    • addSelectorsItem

      public V1DeviceClassSpec addSelectorsItem(V1DeviceSelector selectorsItem)
    • getSelectors

      @Nullable public List<V1DeviceSelector> getSelectors()
      Each selector must be satisfied by a device which is claimed via this class.
      Returns:
      selectors
    • setSelectors

      public void setSelectors(@Nullable List<V1DeviceSelector> selectors)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • validateJsonElement

      public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
      Validates the JSON Element and throws an exception if issues found
      Parameters:
      jsonElement - JSON Element
      Throws:
      IOException - if the JSON Element is invalid with respect to V1DeviceClassSpec
    • fromJson

      public static V1DeviceClassSpec fromJson(String jsonString) throws IOException
      Create an instance of V1DeviceClassSpec given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of V1DeviceClassSpec
      Throws:
      IOException - if the JSON string is invalid with respect to V1DeviceClassSpec
    • toJson

      public String toJson()
      Convert an instance of V1DeviceClassSpec to an JSON string
      Returns:
      JSON string