Class OptimizationAlgorithmPluginResult
java.lang.Object
com.dna.jopt.cloud.touroptimizer.pluginservice.algorithm.AbstractOptimizationAlgorithmPluginResult
com.dna.jopt.cloud.touroptimizer.pluginservice.algorithm.OptimizationAlgorithmPluginResult
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class OptimizationAlgorithmPluginResult
extends AbstractOptimizationAlgorithmPluginResult
Immutable implementation of
AbstractOptimizationAlgorithmPluginResult.
Use the builder to create immutable instances:
OptimizationAlgorithmPluginResult.builder().
Use the static factory method to create immutable instances:
OptimizationAlgorithmPluginResult.of().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeOptimizationAlgorithmPluginResult.static interfacestatic interface -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forOptimizationAlgorithmPluginResult.Creates an immutable copy of aAbstractOptimizationAlgorithmPluginResultvalue.com.google.common.collect.ImmutableList<IEntity>ens()booleanThis instance is equal to all instances ofOptimizationAlgorithmPluginResultthat have equal attribute values.inthashCode()Computes a hash code from attributes:ens,status.of(Iterable<? extends IEntity> ens, AlgorithmPluginResultStatus status) Construct a new immutableOptimizationAlgorithmPluginResultinstance.of(List<IEntity> ens, AlgorithmPluginResultStatus status) Construct a new immutableOptimizationAlgorithmPluginResultinstance.status()toString()Prints the immutable valueOptimizationAlgorithmPluginResultwith attribute values.Copy the current immutable object with elements that replace the content ofens.Copy the current immutable object with elements that replace the content ofens.Copy the current immutable object by setting a value for thestatusattribute.
-
Method Details
-
ens
- Specified by:
ensin classAbstractOptimizationAlgorithmPluginResult- Returns:
- The value of the
ensattribute
-
status
- Specified by:
statusin classAbstractOptimizationAlgorithmPluginResult- Returns:
- The value of the
statusattribute
-
withEns
Copy the current immutable object with elements that replace the content ofens.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withEns
Copy the current immutable object with elements that replace the content ofens. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of ens elements to set- Returns:
- A modified copy of
thisobject
-
withStatus
Copy the current immutable object by setting a value for thestatusattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for status- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofOptimizationAlgorithmPluginResultthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:ens,status. -
toString
Prints the immutable valueOptimizationAlgorithmPluginResultwith attribute values. -
of
public static OptimizationAlgorithmPluginResult of(List<IEntity> ens, AlgorithmPluginResultStatus status) Construct a new immutableOptimizationAlgorithmPluginResultinstance.- Parameters:
ens- The value for theensattributestatus- The value for thestatusattribute- Returns:
- An immutable OptimizationAlgorithmPluginResult instance
-
of
public static OptimizationAlgorithmPluginResult of(Iterable<? extends IEntity> ens, AlgorithmPluginResultStatus status) Construct a new immutableOptimizationAlgorithmPluginResultinstance.- Parameters:
ens- The value for theensattributestatus- The value for thestatusattribute- Returns:
- An immutable OptimizationAlgorithmPluginResult instance
-
copyOf
public static OptimizationAlgorithmPluginResult copyOf(AbstractOptimizationAlgorithmPluginResult instance) Creates an immutable copy of aAbstractOptimizationAlgorithmPluginResultvalue. 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 OptimizationAlgorithmPluginResult instance
-
builder
Creates a builder forOptimizationAlgorithmPluginResult.OptimizationAlgorithmPluginResult.builder() .addEns|addAllEns(com.dna.jopt.member.bucket.entity.IEntity) //enselements .status(com.dna.jopt.cloud.touroptimizer.pluginservice.algorithm.AlgorithmPluginResultStatus) // requiredstatus.build();- Returns:
- A new OptimizationAlgorithmPluginResult builder
-