Class Generated.ResourceHealth.Builder

  • All Implemented Interfaces:
    com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable, Generated.ResourceHealthOrBuilder
    Enclosing class:
    Generated.ResourceHealth

    public static final class Generated.ResourceHealth.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
    implements Generated.ResourceHealthOrBuilder
     ResourceHealth represents the health of a resource. It has the latest device health information.
     This is a part of KEP https://kep.k8s.io/4680.
     
    Protobuf type k8s.io.api.core.v1.ResourceHealth
    • Method Detail

      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
      • getDescriptorForType

        public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
        Specified by:
        getDescriptorForType in interface com.google.protobuf.Message.Builder
        Specified by:
        getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
        Overrides:
        getDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
      • getDefaultInstanceForType

        public Generated.ResourceHealth getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

        public Generated.ResourceHealth build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public Generated.ResourceHealth buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • setRepeatedField

        public Generated.ResourceHealth.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                                 int index,
                                                                 Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
      • addRepeatedField

        public Generated.ResourceHealth.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                                 Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
      • mergeFrom

        public Generated.ResourceHealth.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                   throws IOException
        Specified by:
        mergeFrom in interface com.google.protobuf.Message.Builder
        Specified by:
        mergeFrom in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        mergeFrom in class com.google.protobuf.AbstractMessage.Builder<Generated.ResourceHealth.Builder>
        Throws:
        IOException
      • hasResourceID

        public boolean hasResourceID()
         ResourceID is the unique identifier of the resource. See the ResourceID type for more information.
         
        optional string resourceID = 1;
        Specified by:
        hasResourceID in interface Generated.ResourceHealthOrBuilder
        Returns:
        Whether the resourceID field is set.
      • getResourceID

        public String getResourceID()
         ResourceID is the unique identifier of the resource. See the ResourceID type for more information.
         
        optional string resourceID = 1;
        Specified by:
        getResourceID in interface Generated.ResourceHealthOrBuilder
        Returns:
        The resourceID.
      • getResourceIDBytes

        public com.google.protobuf.ByteString getResourceIDBytes()
         ResourceID is the unique identifier of the resource. See the ResourceID type for more information.
         
        optional string resourceID = 1;
        Specified by:
        getResourceIDBytes in interface Generated.ResourceHealthOrBuilder
        Returns:
        The bytes for resourceID.
      • setResourceID

        public Generated.ResourceHealth.Builder setResourceID​(String value)
         ResourceID is the unique identifier of the resource. See the ResourceID type for more information.
         
        optional string resourceID = 1;
        Parameters:
        value - The resourceID to set.
        Returns:
        This builder for chaining.
      • clearResourceID

        public Generated.ResourceHealth.Builder clearResourceID()
         ResourceID is the unique identifier of the resource. See the ResourceID type for more information.
         
        optional string resourceID = 1;
        Returns:
        This builder for chaining.
      • setResourceIDBytes

        public Generated.ResourceHealth.Builder setResourceIDBytes​(com.google.protobuf.ByteString value)
         ResourceID is the unique identifier of the resource. See the ResourceID type for more information.
         
        optional string resourceID = 1;
        Parameters:
        value - The bytes for resourceID to set.
        Returns:
        This builder for chaining.
      • hasHealth

        public boolean hasHealth()
         Health of the resource.
         can be one of:
          - Healthy: operates as normal
          - Unhealthy: reported unhealthy. We consider this a temporary health issue
                       since we do not have a mechanism today to distinguish
                       temporary and permanent issues.
          - Unknown: The status cannot be determined.
                     For example, Device Plugin got unregistered and hasn't been re-registered since.
        
         In future we may want to introduce the PermanentlyUnhealthy Status.
         
        optional string health = 2;
        Specified by:
        hasHealth in interface Generated.ResourceHealthOrBuilder
        Returns:
        Whether the health field is set.
      • getHealth

        public String getHealth()
         Health of the resource.
         can be one of:
          - Healthy: operates as normal
          - Unhealthy: reported unhealthy. We consider this a temporary health issue
                       since we do not have a mechanism today to distinguish
                       temporary and permanent issues.
          - Unknown: The status cannot be determined.
                     For example, Device Plugin got unregistered and hasn't been re-registered since.
        
         In future we may want to introduce the PermanentlyUnhealthy Status.
         
        optional string health = 2;
        Specified by:
        getHealth in interface Generated.ResourceHealthOrBuilder
        Returns:
        The health.
      • getHealthBytes

        public com.google.protobuf.ByteString getHealthBytes()
         Health of the resource.
         can be one of:
          - Healthy: operates as normal
          - Unhealthy: reported unhealthy. We consider this a temporary health issue
                       since we do not have a mechanism today to distinguish
                       temporary and permanent issues.
          - Unknown: The status cannot be determined.
                     For example, Device Plugin got unregistered and hasn't been re-registered since.
        
         In future we may want to introduce the PermanentlyUnhealthy Status.
         
        optional string health = 2;
        Specified by:
        getHealthBytes in interface Generated.ResourceHealthOrBuilder
        Returns:
        The bytes for health.
      • setHealth

        public Generated.ResourceHealth.Builder setHealth​(String value)
         Health of the resource.
         can be one of:
          - Healthy: operates as normal
          - Unhealthy: reported unhealthy. We consider this a temporary health issue
                       since we do not have a mechanism today to distinguish
                       temporary and permanent issues.
          - Unknown: The status cannot be determined.
                     For example, Device Plugin got unregistered and hasn't been re-registered since.
        
         In future we may want to introduce the PermanentlyUnhealthy Status.
         
        optional string health = 2;
        Parameters:
        value - The health to set.
        Returns:
        This builder for chaining.
      • clearHealth

        public Generated.ResourceHealth.Builder clearHealth()
         Health of the resource.
         can be one of:
          - Healthy: operates as normal
          - Unhealthy: reported unhealthy. We consider this a temporary health issue
                       since we do not have a mechanism today to distinguish
                       temporary and permanent issues.
          - Unknown: The status cannot be determined.
                     For example, Device Plugin got unregistered and hasn't been re-registered since.
        
         In future we may want to introduce the PermanentlyUnhealthy Status.
         
        optional string health = 2;
        Returns:
        This builder for chaining.
      • setHealthBytes

        public Generated.ResourceHealth.Builder setHealthBytes​(com.google.protobuf.ByteString value)
         Health of the resource.
         can be one of:
          - Healthy: operates as normal
          - Unhealthy: reported unhealthy. We consider this a temporary health issue
                       since we do not have a mechanism today to distinguish
                       temporary and permanent issues.
          - Unknown: The status cannot be determined.
                     For example, Device Plugin got unregistered and hasn't been re-registered since.
        
         In future we may want to introduce the PermanentlyUnhealthy Status.
         
        optional string health = 2;
        Parameters:
        value - The bytes for health to set.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final Generated.ResourceHealth.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>
      • mergeUnknownFields

        public final Generated.ResourceHealth.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Generated.ResourceHealth.Builder>