@Generated(value="org.immutables.processor.ProxyProcessor") public final class ImmutableObjectMeta extends Object implements ObjectMeta
ObjectMeta.
Use the builder to create immutable instances:
new ObjectMeta.Builder().
| Modifier and Type | Class and Description |
|---|---|
static class |
ImmutableObjectMeta.Builder
Builds instances of type
ImmutableObjectMeta. |
| Modifier and Type | Method and Description |
|---|---|
static ImmutableObjectMeta |
copyOf(ObjectMeta instance)
Creates an immutable copy of a
ObjectMeta value. |
boolean |
equals(Object another)
This instance is equal to all instances of
ImmutableObjectMeta that have equal attribute values. |
com.google.common.collect.ImmutableMap<String,String> |
getLabels() |
String |
getName() |
int |
hashCode()
Computes a hash code from attributes:
name, labels. |
String |
toString()
Prints the immutable value
ObjectMeta with attribute values. |
ImmutableObjectMeta |
withLabels(Map<String,? extends String> entries)
Copy the current immutable object by replacing the
labels map with the specified map. |
ImmutableObjectMeta |
withName(String value)
Copy the current immutable object by setting a value for the
name attribute. |
public String getName()
getName in interface ObjectMetaname attributepublic com.google.common.collect.ImmutableMap<String,String> getLabels()
getLabels in interface ObjectMetalabels attributepublic final ImmutableObjectMeta withName(String value)
name attribute.
An equals check used to prevent copying of the same value by returning this.value - A new value for namethis objectpublic final ImmutableObjectMeta withLabels(Map<String,? extends String> entries)
labels map with the specified map.
Nulls are not permitted as keys or values.
A shallow reference equality check is used to prevent copying of the same value by returning this.entries - The entries to be added to the labels mapthis objectpublic boolean equals(Object another)
ImmutableObjectMeta that have equal attribute values.public int hashCode()
name, labels.public String toString()
ObjectMeta with attribute values.public static ImmutableObjectMeta copyOf(ObjectMeta instance)
ObjectMeta value.
Uses accessors to get values to initialize the new immutable instance.
If an instance is already immutable, it is returned as is.instance - The instance to copyCopyright © 2019 The Apache Software Foundation. All rights reserved.