Class LabelSelectorRequirement
- java.lang.Object
-
- com.marcnuri.yakc.model.io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement
-
- All Implemented Interfaces:
com.marcnuri.yakc.model.Model
public class LabelSelectorRequirement extends java.lang.Object implements com.marcnuri.yakc.model.Model
A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
LabelSelectorRequirement.Builder
-
Constructor Summary
Constructors Constructor Description LabelSelectorRequirement()
LabelSelectorRequirement(@NonNull java.lang.String key, @NonNull java.lang.String operator, java.util.List<java.lang.String> values)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static LabelSelectorRequirement.Builder
builder()
protected boolean
canEqual(java.lang.Object other)
boolean
equals(java.lang.Object o)
@NonNull java.lang.String
getKey()
key is the label key that the selector applies to.@NonNull java.lang.String
getOperator()
operator represents a key's relationship to a set of values.java.util.List<java.lang.String>
getValues()
values is an array of string values.int
hashCode()
void
setKey(@NonNull java.lang.String key)
key is the label key that the selector applies to.void
setOperator(@NonNull java.lang.String operator)
operator represents a key's relationship to a set of values.void
setValues(java.util.List<java.lang.String> values)
values is an array of string values.LabelSelectorRequirement.Builder
toBuilder()
java.lang.String
toString()
-
-
-
Method Detail
-
builder
public static LabelSelectorRequirement.Builder builder()
-
toBuilder
public LabelSelectorRequirement.Builder toBuilder()
-
getKey
@NonNull public @NonNull java.lang.String getKey()
key is the label key that the selector applies to.
-
getOperator
@NonNull public @NonNull java.lang.String getOperator()
operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
-
getValues
public java.util.List<java.lang.String> getValues()
values is 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. This array is replaced during a strategic merge patch.
-
setKey
public void setKey(@NonNull @NonNull java.lang.String key)
key is the label key that the selector applies to.
-
setOperator
public void setOperator(@NonNull @NonNull java.lang.String operator)
operator represents a key's relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
-
setValues
public void setValues(java.util.List<java.lang.String> values)
values is 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. This array is replaced during a strategic merge patch.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
canEqual
protected boolean canEqual(java.lang.Object other)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-