Class ImmutableRuntimeSpec
- java.lang.Object
-
- org.apache.camel.k.catalog.model.k8s.crd.ImmutableRuntimeSpec
-
- All Implemented Interfaces:
RuntimeSpec
@Generated("org.immutables.processor.ProxyProcessor") public final class ImmutableRuntimeSpec extends Object implements RuntimeSpec
Immutable implementation ofRuntimeSpec
.Use the builder to create immutable instances:
new RuntimeSpec.Builder()
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ImmutableRuntimeSpec.Builder
Builds instances of typeImmutableRuntimeSpec
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableRuntimeSpec
copyOf(RuntimeSpec instance)
Creates an immutable copy of aRuntimeSpec
value.boolean
equals(Object another)
This instance is equal to all instances ofImmutableRuntimeSpec
that have equal attribute values.String
getApplicationClass()
SortedMap<String,CamelCapability>
getCapabilities()
SortedSet<Artifact>
getDependencies()
SortedMap<String,String>
getMetadata()
String
getProvider()
String
getVersion()
int
hashCode()
Computes a hash code from attributes:provider
,version
,applicationClass
,metadata
,dependencies
,capabilities
.String
toString()
Prints the immutable valueRuntimeSpec
with attribute values.ImmutableRuntimeSpec
withApplicationClass(String value)
Copy the current immutable object by setting a value for theapplicationClass
attribute.ImmutableRuntimeSpec
withCapabilities(Map<String,? extends CamelCapability> entries)
Copy the current immutable object by replacing thecapabilities
map with the specified map.ImmutableRuntimeSpec
withDependencies(Iterable<? extends Artifact> elements)
Copy the current immutable object with elements that replace the content ofdependencies
.ImmutableRuntimeSpec
withDependencies(Artifact... elements)
Copy the current immutable object with elements that replace the content ofdependencies
.ImmutableRuntimeSpec
withMetadata(Map<String,? extends String> entries)
Copy the current immutable object by replacing themetadata
map with the specified map.ImmutableRuntimeSpec
withProvider(String value)
Copy the current immutable object by setting a value for theprovider
attribute.ImmutableRuntimeSpec
withVersion(String value)
Copy the current immutable object by setting a value for theversion
attribute.
-
-
-
Method Detail
-
getProvider
public String getProvider()
- Specified by:
getProvider
in interfaceRuntimeSpec
- Returns:
- The value of the
provider
attribute
-
getVersion
public String getVersion()
- Specified by:
getVersion
in interfaceRuntimeSpec
- Returns:
- The value of the
version
attribute
-
getApplicationClass
public String getApplicationClass()
- Specified by:
getApplicationClass
in interfaceRuntimeSpec
- Returns:
- The value of the
applicationClass
attribute
-
getMetadata
public SortedMap<String,String> getMetadata()
- Specified by:
getMetadata
in interfaceRuntimeSpec
- Returns:
- The value of the
metadata
attribute
-
getDependencies
public SortedSet<Artifact> getDependencies()
- Specified by:
getDependencies
in interfaceRuntimeSpec
- Returns:
- The value of the
dependencies
attribute
-
getCapabilities
public SortedMap<String,CamelCapability> getCapabilities()
- Specified by:
getCapabilities
in interfaceRuntimeSpec
- Returns:
- The value of the
capabilities
attribute
-
withProvider
public final ImmutableRuntimeSpec withProvider(String value)
Copy the current immutable object by setting a value for theprovider
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for provider- Returns:
- A modified copy of the
this
object
-
withVersion
public final ImmutableRuntimeSpec withVersion(String value)
Copy the current immutable object by setting a value for theversion
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for version- Returns:
- A modified copy of the
this
object
-
withApplicationClass
public final ImmutableRuntimeSpec withApplicationClass(String value)
Copy the current immutable object by setting a value for theapplicationClass
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for applicationClass- Returns:
- A modified copy of the
this
object
-
withMetadata
public final ImmutableRuntimeSpec withMetadata(Map<String,? extends String> entries)
Copy the current immutable object by replacing themetadata
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 returningthis
.- Parameters:
entries
- The entries to be added to the metadata map- Returns:
- A modified copy of
this
object
-
withDependencies
public final ImmutableRuntimeSpec withDependencies(Artifact... elements)
Copy the current immutable object with elements that replace the content ofdependencies
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withDependencies
public final ImmutableRuntimeSpec withDependencies(Iterable<? extends Artifact> elements)
Copy the current immutable object with elements that replace the content ofdependencies
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of dependencies elements to set- Returns:
- A modified copy of
this
object
-
withCapabilities
public final ImmutableRuntimeSpec withCapabilities(Map<String,? extends CamelCapability> entries)
Copy the current immutable object by replacing thecapabilities
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 returningthis
.- Parameters:
entries
- The entries to be added to the capabilities map- Returns:
- A modified copy of
this
object
-
equals
public boolean equals(Object another)
This instance is equal to all instances ofImmutableRuntimeSpec
that have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:provider
,version
,applicationClass
,metadata
,dependencies
,capabilities
.
-
toString
public String toString()
Prints the immutable valueRuntimeSpec
with attribute values.
-
copyOf
public static ImmutableRuntimeSpec copyOf(RuntimeSpec instance)
Creates an immutable copy of aRuntimeSpec
value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance
- The instance to copy- Returns:
- A copied immutable RuntimeSpec instance
-
-