Struct k8s_openapi::apimachinery::pkg::apis::meta::v1::LabelSelector
source · pub struct LabelSelector {
pub match_expressions: Option<Vec<LabelSelectorRequirement>>,
pub match_labels: Option<BTreeMap<String, String>>,
}
Expand description
A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.
Fields§
§match_expressions: Option<Vec<LabelSelectorRequirement>>
matchExpressions is a list of label selector requirements. The requirements are ANDed.
match_labels: Option<BTreeMap<String, String>>
matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is “key”, the operator is “In”, and the values array contains only “value”. The requirements are ANDed.
Trait Implementations§
source§impl Clone for LabelSelector
impl Clone for LabelSelector
source§fn clone(&self) -> LabelSelector
fn clone(&self) -> LabelSelector
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for LabelSelector
impl Debug for LabelSelector
source§impl DeepMerge for LabelSelector
impl DeepMerge for LabelSelector
source§fn merge_from(&mut self, other: Self)
fn merge_from(&mut self, other: Self)
Merge
other
into self
.source§impl Default for LabelSelector
impl Default for LabelSelector
source§fn default() -> LabelSelector
fn default() -> LabelSelector
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for LabelSelector
impl<'de> Deserialize<'de> for LabelSelector
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl JsonSchema for LabelSelector
impl JsonSchema for LabelSelector
source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
source§fn json_schema(__gen: &mut SchemaGenerator) -> Schema
fn json_schema(__gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref
keyword. Read moresource§impl PartialEq for LabelSelector
impl PartialEq for LabelSelector
source§impl Serialize for LabelSelector
impl Serialize for LabelSelector
impl StructuralPartialEq for LabelSelector
Auto Trait Implementations§
impl Freeze for LabelSelector
impl RefUnwindSafe for LabelSelector
impl Send for LabelSelector
impl Sync for LabelSelector
impl Unpin for LabelSelector
impl UnwindSafe for LabelSelector
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)