Class ImmutableConflictClique
java.lang.Object
pl.poznan.put.structure.pseudoknots.dp.ConflictClique
pl.poznan.put.structure.pseudoknots.dp.ImmutableConflictClique
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class ImmutableConflictClique
extends ConflictClique
Immutable implementation of
ConflictClique
.
Use the builder to create immutable instances:
ImmutableConflictClique.builder()
.
Use the static factory method to create immutable instances:
ImmutableConflictClique.of()
.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final class
Builds instances of typeImmutableConflictClique
. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Creates a builder forImmutableConflictClique
.static ImmutableConflictClique
copyOf
(ConflictClique instance) Creates an immutable copy of aConflictClique
value.boolean
This instance is equal to all instances ofImmutableConflictClique
that have equal attribute values.int
hashCode()
Computes a hash code from attributes:regions
.static ImmutableConflictClique
Construct a new immutableConflictClique
instance.static ImmutableConflictClique
Construct a new immutableConflictClique
instance.regions()
toString()
Prints the immutable valueConflictClique
with attribute values.final ImmutableConflictClique
withRegions
(Iterable<? extends Region> elements) Copy the current immutable object with elements that replace the content ofregions
.final ImmutableConflictClique
withRegions
(Region... elements) Copy the current immutable object with elements that replace the content ofregions
.Methods inherited from class pl.poznan.put.structure.pseudoknots.dp.ConflictClique
endpoint, endpointCount, findRegion, indexOfEndpoint, size
-
Method Details
-
regions
- Specified by:
regions
in classConflictClique
- Returns:
- The set of regions in this conflict clique.
-
withRegions
Copy the current immutable object with elements that replace the content ofregions
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withRegions
Copy the current immutable object with elements that replace the content ofregions
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of regions elements to set- Returns:
- A modified copy of
this
object
-
equals
This instance is equal to all instances ofImmutableConflictClique
that have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:regions
. -
toString
Prints the immutable valueConflictClique
with attribute values. -
sortedEndpoints
Returns a lazily initialized value of the
sortedEndpoints
attribute. Initialized once and only once and stored for subsequent access with proper synchronization. In case of any exception or error thrown by the lazy value initializer, the result will not be memoised (i.e. remembered) and on next call computation will be attempted again.- Overrides:
sortedEndpoints
in classConflictClique
- Returns:
- A lazily initialized value of the
sortedEndpoints
attribute
-
of
Construct a new immutableConflictClique
instance.- Parameters:
regions
- The value for theregions
attribute- Returns:
- An immutable ConflictClique instance
-
of
Construct a new immutableConflictClique
instance.- Parameters:
regions
- The value for theregions
attribute- Returns:
- An immutable ConflictClique instance
-
copyOf
Creates an immutable copy of aConflictClique
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 ConflictClique instance
-
builder
Creates a builder forImmutableConflictClique
.ImmutableConflictClique.builder() .addRegions|addAllRegions(pl.poznan.put.structure.pseudoknots.Region) //
regions
elements .build();- Returns:
- A new ImmutableConflictClique builder
-