Class Generated.PodAffinityTerm

  • All Implemented Interfaces:
    com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable, Generated.PodAffinityTermOrBuilder
    Enclosing class:
    Generated

    public static final class Generated.PodAffinityTerm
    extends com.google.protobuf.GeneratedMessageV3
    implements Generated.PodAffinityTermOrBuilder
     Defines a set of pods (namely those matching the labelSelector
     relative to the given namespace(s)) that this pod should be
     co-located (affinity) or not co-located (anti-affinity) with,
     where co-located is defined as running on a node whose value of
     the label with key <topologyKey> matches that of any node on which
     a pod of the set of pods is running
     
    Protobuf type k8s.io.api.core.v1.PodAffinityTerm
    See Also:
    Serialized Form
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  Generated.PodAffinityTerm.Builder
      Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key <topologyKey> matches that of any node on which a pod of the set of pods is running
      • Nested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3

        com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,​BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT,​BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter
      • Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite

        com.google.protobuf.AbstractMessageLite.InternalOneOfEnum
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • 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
      • hasLabelSelector

        public boolean hasLabelSelector()
         A label query over a set of resources, in this case pods.
         If it's null, this PodAffinityTerm matches with no Pods.
         +optional
         
        optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector labelSelector = 1;
        Specified by:
        hasLabelSelector in interface Generated.PodAffinityTermOrBuilder
        Returns:
        Whether the labelSelector field is set.
      • getLabelSelector

        public Generated.LabelSelector getLabelSelector()
         A label query over a set of resources, in this case pods.
         If it's null, this PodAffinityTerm matches with no Pods.
         +optional
         
        optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector labelSelector = 1;
        Specified by:
        getLabelSelector in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The labelSelector.
      • getNamespacesList

        public com.google.protobuf.ProtocolStringList getNamespacesList()
         namespaces specifies a static list of namespace names that the term applies to.
         The term is applied to the union of the namespaces listed in this field
         and the ones selected by namespaceSelector.
         null or empty namespaces list and null namespaceSelector means "this pod's namespace".
         +optional
         +listType=atomic
         
        repeated string namespaces = 2;
        Specified by:
        getNamespacesList in interface Generated.PodAffinityTermOrBuilder
        Returns:
        A list containing the namespaces.
      • getNamespacesCount

        public int getNamespacesCount()
         namespaces specifies a static list of namespace names that the term applies to.
         The term is applied to the union of the namespaces listed in this field
         and the ones selected by namespaceSelector.
         null or empty namespaces list and null namespaceSelector means "this pod's namespace".
         +optional
         +listType=atomic
         
        repeated string namespaces = 2;
        Specified by:
        getNamespacesCount in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The count of namespaces.
      • getNamespaces

        public String getNamespaces​(int index)
         namespaces specifies a static list of namespace names that the term applies to.
         The term is applied to the union of the namespaces listed in this field
         and the ones selected by namespaceSelector.
         null or empty namespaces list and null namespaceSelector means "this pod's namespace".
         +optional
         +listType=atomic
         
        repeated string namespaces = 2;
        Specified by:
        getNamespaces in interface Generated.PodAffinityTermOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The namespaces at the given index.
      • getNamespacesBytes

        public com.google.protobuf.ByteString getNamespacesBytes​(int index)
         namespaces specifies a static list of namespace names that the term applies to.
         The term is applied to the union of the namespaces listed in this field
         and the ones selected by namespaceSelector.
         null or empty namespaces list and null namespaceSelector means "this pod's namespace".
         +optional
         +listType=atomic
         
        repeated string namespaces = 2;
        Specified by:
        getNamespacesBytes in interface Generated.PodAffinityTermOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the namespaces at the given index.
      • hasTopologyKey

        public boolean hasTopologyKey()
         This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching
         the labelSelector in the specified namespaces, where co-located is defined as running on a node
         whose value of the label with key topologyKey matches that of any node on which any of the
         selected pods is running.
         Empty topologyKey is not allowed.
         
        optional string topologyKey = 3;
        Specified by:
        hasTopologyKey in interface Generated.PodAffinityTermOrBuilder
        Returns:
        Whether the topologyKey field is set.
      • getTopologyKey

        public String getTopologyKey()
         This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching
         the labelSelector in the specified namespaces, where co-located is defined as running on a node
         whose value of the label with key topologyKey matches that of any node on which any of the
         selected pods is running.
         Empty topologyKey is not allowed.
         
        optional string topologyKey = 3;
        Specified by:
        getTopologyKey in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The topologyKey.
      • getTopologyKeyBytes

        public com.google.protobuf.ByteString getTopologyKeyBytes()
         This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching
         the labelSelector in the specified namespaces, where co-located is defined as running on a node
         whose value of the label with key topologyKey matches that of any node on which any of the
         selected pods is running.
         Empty topologyKey is not allowed.
         
        optional string topologyKey = 3;
        Specified by:
        getTopologyKeyBytes in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The bytes for topologyKey.
      • hasNamespaceSelector

        public boolean hasNamespaceSelector()
         A label query over the set of namespaces that the term applies to.
         The term is applied to the union of the namespaces selected by this field
         and the ones listed in the namespaces field.
         null selector and null or empty namespaces list means "this pod's namespace".
         An empty selector ({}) matches all namespaces.
         +optional
         
        optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 4;
        Specified by:
        hasNamespaceSelector in interface Generated.PodAffinityTermOrBuilder
        Returns:
        Whether the namespaceSelector field is set.
      • getNamespaceSelector

        public Generated.LabelSelector getNamespaceSelector()
         A label query over the set of namespaces that the term applies to.
         The term is applied to the union of the namespaces selected by this field
         and the ones listed in the namespaces field.
         null selector and null or empty namespaces list means "this pod's namespace".
         An empty selector ({}) matches all namespaces.
         +optional
         
        optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 4;
        Specified by:
        getNamespaceSelector in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The namespaceSelector.
      • getNamespaceSelectorOrBuilder

        public Generated.LabelSelectorOrBuilder getNamespaceSelectorOrBuilder()
         A label query over the set of namespaces that the term applies to.
         The term is applied to the union of the namespaces selected by this field
         and the ones listed in the namespaces field.
         null selector and null or empty namespaces list means "this pod's namespace".
         An empty selector ({}) matches all namespaces.
         +optional
         
        optional .k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 4;
        Specified by:
        getNamespaceSelectorOrBuilder in interface Generated.PodAffinityTermOrBuilder
      • getMatchLabelKeysList

        public com.google.protobuf.ProtocolStringList getMatchLabelKeysList()
         MatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both matchLabelKeys and labelSelector.
         Also, matchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string matchLabelKeys = 5;
        Specified by:
        getMatchLabelKeysList in interface Generated.PodAffinityTermOrBuilder
        Returns:
        A list containing the matchLabelKeys.
      • getMatchLabelKeysCount

        public int getMatchLabelKeysCount()
         MatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both matchLabelKeys and labelSelector.
         Also, matchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string matchLabelKeys = 5;
        Specified by:
        getMatchLabelKeysCount in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The count of matchLabelKeys.
      • getMatchLabelKeys

        public String getMatchLabelKeys​(int index)
         MatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both matchLabelKeys and labelSelector.
         Also, matchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string matchLabelKeys = 5;
        Specified by:
        getMatchLabelKeys in interface Generated.PodAffinityTermOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The matchLabelKeys at the given index.
      • getMatchLabelKeysBytes

        public com.google.protobuf.ByteString getMatchLabelKeysBytes​(int index)
         MatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key in (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both matchLabelKeys and labelSelector.
         Also, matchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string matchLabelKeys = 5;
        Specified by:
        getMatchLabelKeysBytes in interface Generated.PodAffinityTermOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the matchLabelKeys at the given index.
      • getMismatchLabelKeysList

        public com.google.protobuf.ProtocolStringList getMismatchLabelKeysList()
         MismatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both mismatchLabelKeys and labelSelector.
         Also, mismatchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string mismatchLabelKeys = 6;
        Specified by:
        getMismatchLabelKeysList in interface Generated.PodAffinityTermOrBuilder
        Returns:
        A list containing the mismatchLabelKeys.
      • getMismatchLabelKeysCount

        public int getMismatchLabelKeysCount()
         MismatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both mismatchLabelKeys and labelSelector.
         Also, mismatchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string mismatchLabelKeys = 6;
        Specified by:
        getMismatchLabelKeysCount in interface Generated.PodAffinityTermOrBuilder
        Returns:
        The count of mismatchLabelKeys.
      • getMismatchLabelKeys

        public String getMismatchLabelKeys​(int index)
         MismatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both mismatchLabelKeys and labelSelector.
         Also, mismatchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string mismatchLabelKeys = 6;
        Specified by:
        getMismatchLabelKeys in interface Generated.PodAffinityTermOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The mismatchLabelKeys at the given index.
      • getMismatchLabelKeysBytes

        public com.google.protobuf.ByteString getMismatchLabelKeysBytes​(int index)
         MismatchLabelKeys is a set of pod label keys to select which pods will
         be taken into consideration. The keys are used to lookup values from the
         incoming pod labels, those key-value labels are merged with `labelSelector` as `key notin (value)`
         to select the group of existing pods which pods will be taken into consideration
         for the incoming pod's pod (anti) affinity. Keys that don't exist in the incoming
         pod labels will be ignored. The default value is empty.
         The same key is forbidden to exist in both mismatchLabelKeys and labelSelector.
         Also, mismatchLabelKeys cannot be set when labelSelector isn't set.
         This is a beta field and requires enabling MatchLabelKeysInPodAffinity feature gate (enabled by default).
        
         +listType=atomic
         +optional
         
        repeated string mismatchLabelKeys = 6;
        Specified by:
        getMismatchLabelKeysBytes in interface Generated.PodAffinityTermOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the mismatchLabelKeys at the given index.
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static Generated.PodAffinityTerm parseFrom​(ByteBuffer data)
                                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Generated.PodAffinityTerm parseFrom​(ByteBuffer data,
                                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Generated.PodAffinityTerm parseFrom​(com.google.protobuf.ByteString data)
                                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Generated.PodAffinityTerm parseFrom​(com.google.protobuf.ByteString data,
                                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Generated.PodAffinityTerm parseFrom​(byte[] data)
                                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Generated.PodAffinityTerm parseFrom​(byte[] data,
                                                          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                   throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • newBuilderForType

        public Generated.PodAffinityTerm.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public Generated.PodAffinityTerm.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected Generated.PodAffinityTerm.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getParserForType

        public com.google.protobuf.Parser<Generated.PodAffinityTerm> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

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