Class NodeSelectorRequirement

  • All Implemented Interfaces:
    com.marcnuri.yakc.model.Model

    public class NodeSelectorRequirement
    extends java.lang.Object
    implements com.marcnuri.yakc.model.Model
    A node selector requirement is a selector that contains values, a key, and an operator that relates the key and values.
    • Constructor Detail

      • NodeSelectorRequirement

        public NodeSelectorRequirement​(@NonNull
                                       @NonNull java.lang.String key,
                                       @NonNull
                                       @NonNull java.lang.String operator,
                                       java.util.List<java.lang.String> values)
      • NodeSelectorRequirement

        public NodeSelectorRequirement()
    • Method Detail

      • getKey

        @NonNull
        public @NonNull java.lang.String getKey()
        The label key that the selector applies to.
      • getOperator

        @NonNull
        public @NonNull java.lang.String getOperator()
        Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.
      • getValues

        public java.util.List<java.lang.String> getValues()
        An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.
      • setKey

        public void setKey​(@NonNull
                           @NonNull java.lang.String key)
        The label key that the selector applies to.
      • setOperator

        public void setOperator​(@NonNull
                                @NonNull java.lang.String operator)
        Represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt.
      • setValues

        public void setValues​(java.util.List<java.lang.String> values)
        An array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. If the operator is Gt or Lt, the values array must have a single element, which will be interpreted as an integer. This array is replaced during a strategic merge patch.
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • canEqual

        protected boolean canEqual​(java.lang.Object other)
      • hashCode

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

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object