Class ImmutableCamelArtifact
- java.lang.Object
-
- org.apache.camel.k.tooling.maven.model.ImmutableCamelArtifact
-
- All Implemented Interfaces:
Artifact,CamelArtifact
@Generated("org.immutables.processor.ProxyProcessor") public final class ImmutableCamelArtifact extends Object implements CamelArtifact
Immutable implementation ofCamelArtifact.Use the builder to create immutable instances:
new CamelArtifact.Builder().
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutableCamelArtifact.BuilderBuilds instances of typeImmutableCamelArtifact.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ImmutableCamelArtifactcopyOf(CamelArtifact instance)Creates an immutable copy of aCamelArtifactvalue.booleanequals(Object another)This instance is equal to all instances ofImmutableCamelArtifactthat have equal attribute values.StringgetArtifactId()com.google.common.collect.ImmutableSet<String>getDataformats()com.google.common.collect.ImmutableSet<Artifact>getDependencies()com.google.common.collect.ImmutableSet<Artifact>getExclusions()StringgetGroupId()com.google.common.collect.ImmutableSet<String>getJavaTypes()com.google.common.collect.ImmutableSet<String>getLanguages()com.google.common.collect.ImmutableSet<CamelScheme>getSchemes()Optional<String>getVersion()inthashCode()Computes a hash code from attributes:groupId,artifactId,version.StringtoString()Prints the immutable valueCamelArtifactwith attribute values.ImmutableCamelArtifactwithArtifactId(String value)Copy the current immutable object by setting a value for theartifactIdattribute.ImmutableCamelArtifactwithDataformats(Iterable<String> elements)Copy the current immutable object with elements that replace the content ofdataformats.ImmutableCamelArtifactwithDataformats(String... elements)Copy the current immutable object with elements that replace the content ofdataformats.ImmutableCamelArtifactwithDependencies(Iterable<? extends Artifact> elements)Copy the current immutable object with elements that replace the content ofdependencies.ImmutableCamelArtifactwithDependencies(Artifact... elements)Copy the current immutable object with elements that replace the content ofdependencies.ImmutableCamelArtifactwithExclusions(Iterable<? extends Artifact> elements)Copy the current immutable object with elements that replace the content ofexclusions.ImmutableCamelArtifactwithExclusions(Artifact... elements)Copy the current immutable object with elements that replace the content ofexclusions.ImmutableCamelArtifactwithGroupId(String value)Copy the current immutable object by setting a value for thegroupIdattribute.ImmutableCamelArtifactwithJavaTypes(Iterable<String> elements)Copy the current immutable object with elements that replace the content ofjavaTypes.ImmutableCamelArtifactwithJavaTypes(String... elements)Copy the current immutable object with elements that replace the content ofjavaTypes.ImmutableCamelArtifactwithLanguages(Iterable<String> elements)Copy the current immutable object with elements that replace the content oflanguages.ImmutableCamelArtifactwithLanguages(String... elements)Copy the current immutable object with elements that replace the content oflanguages.ImmutableCamelArtifactwithSchemes(Iterable<? extends CamelScheme> elements)Copy the current immutable object with elements that replace the content ofschemes.ImmutableCamelArtifactwithSchemes(CamelScheme... elements)Copy the current immutable object with elements that replace the content ofschemes.ImmutableCamelArtifactwithVersion(String value)Copy the current immutable object by setting a present value for the optionalversionattribute.ImmutableCamelArtifactwithVersion(Optional<String> optional)Copy the current immutable object by setting an optional value for theversionattribute.
-
-
-
Method Detail
-
getGroupId
public String getGroupId()
- Specified by:
getGroupIdin interfaceArtifact- Returns:
- The value of the
groupIdattribute
-
getArtifactId
public String getArtifactId()
- Specified by:
getArtifactIdin interfaceArtifact- Returns:
- The value of the
artifactIdattribute
-
getVersion
public Optional<String> getVersion()
- Specified by:
getVersionin interfaceArtifact- Returns:
- The value of the
versionattribute
-
getSchemes
public com.google.common.collect.ImmutableSet<CamelScheme> getSchemes()
- Specified by:
getSchemesin interfaceCamelArtifact- Returns:
- The value of the
schemesattribute
-
getLanguages
public com.google.common.collect.ImmutableSet<String> getLanguages()
- Specified by:
getLanguagesin interfaceCamelArtifact- Returns:
- The value of the
languagesattribute
-
getDataformats
public com.google.common.collect.ImmutableSet<String> getDataformats()
- Specified by:
getDataformatsin interfaceCamelArtifact- Returns:
- The value of the
dataformatsattribute
-
getDependencies
public com.google.common.collect.ImmutableSet<Artifact> getDependencies()
- Specified by:
getDependenciesin interfaceCamelArtifact- Returns:
- The value of the
dependenciesattribute
-
getExclusions
public com.google.common.collect.ImmutableSet<Artifact> getExclusions()
- Specified by:
getExclusionsin interfaceCamelArtifact- Returns:
- The value of the
exclusionsattribute
-
getJavaTypes
public com.google.common.collect.ImmutableSet<String> getJavaTypes()
- Specified by:
getJavaTypesin interfaceCamelArtifact- Returns:
- The value of the
javaTypesattribute
-
withGroupId
public final ImmutableCamelArtifact withGroupId(String value)
Copy the current immutable object by setting a value for thegroupIdattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for groupId- Returns:
- A modified copy of the
thisobject
-
withArtifactId
public final ImmutableCamelArtifact withArtifactId(String value)
Copy the current immutable object by setting a value for theartifactIdattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for artifactId- Returns:
- A modified copy of the
thisobject
-
withVersion
public final ImmutableCamelArtifact withVersion(String value)
Copy the current immutable object by setting a present value for the optionalversionattribute.- Parameters:
value- The value for version- Returns:
- A modified copy of
thisobject
-
withVersion
public final ImmutableCamelArtifact withVersion(Optional<String> optional)
Copy the current immutable object by setting an optional value for theversionattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for version- Returns:
- A modified copy of
thisobject
-
withSchemes
public final ImmutableCamelArtifact withSchemes(CamelScheme... elements)
Copy the current immutable object with elements that replace the content ofschemes.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withSchemes
public final ImmutableCamelArtifact withSchemes(Iterable<? extends CamelScheme> elements)
Copy the current immutable object with elements that replace the content ofschemes. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of schemes elements to set- Returns:
- A modified copy of
thisobject
-
withLanguages
public final ImmutableCamelArtifact withLanguages(String... elements)
Copy the current immutable object with elements that replace the content oflanguages.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withLanguages
public final ImmutableCamelArtifact withLanguages(Iterable<String> elements)
Copy the current immutable object with elements that replace the content oflanguages. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of languages elements to set- Returns:
- A modified copy of
thisobject
-
withDataformats
public final ImmutableCamelArtifact withDataformats(String... elements)
Copy the current immutable object with elements that replace the content ofdataformats.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withDataformats
public final ImmutableCamelArtifact withDataformats(Iterable<String> elements)
Copy the current immutable object with elements that replace the content ofdataformats. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of dataformats elements to set- Returns:
- A modified copy of
thisobject
-
withDependencies
public final ImmutableCamelArtifact 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
thisobject
-
withDependencies
public final ImmutableCamelArtifact 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
thisobject
-
withExclusions
public final ImmutableCamelArtifact withExclusions(Artifact... elements)
Copy the current immutable object with elements that replace the content ofexclusions.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withExclusions
public final ImmutableCamelArtifact withExclusions(Iterable<? extends Artifact> elements)
Copy the current immutable object with elements that replace the content ofexclusions. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of exclusions elements to set- Returns:
- A modified copy of
thisobject
-
withJavaTypes
public final ImmutableCamelArtifact withJavaTypes(String... elements)
Copy the current immutable object with elements that replace the content ofjavaTypes.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withJavaTypes
public final ImmutableCamelArtifact withJavaTypes(Iterable<String> elements)
Copy the current immutable object with elements that replace the content ofjavaTypes. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of javaTypes elements to set- Returns:
- A modified copy of
thisobject
-
equals
public boolean equals(Object another)
This instance is equal to all instances ofImmutableCamelArtifactthat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:groupId,artifactId,version.
-
toString
public String toString()
Prints the immutable valueCamelArtifactwith attribute values.
-
copyOf
public static ImmutableCamelArtifact copyOf(CamelArtifact instance)
Creates an immutable copy of aCamelArtifactvalue. 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 CamelArtifact instance
-
-