Package pl.poznan.put.structure.formats
Class ImmutableDefaultDotBracketFromPdb.Builder
java.lang.Object
pl.poznan.put.structure.formats.ImmutableDefaultDotBracketFromPdb.Builder
- Enclosing class:
- ImmutableDefaultDotBracketFromPdb
Builds instances of type
ImmutableDefaultDotBracketFromPdb
.
Initialize attributes and then invoke the build()
method to create an
immutable instance.
Builder
is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionaddAllIdentifierSet
(Iterable<? extends PdbResidueIdentifier> elements) Adds elements toidentifierSet
set.addAllStrands
(Iterable<? extends Strand> elements) Adds elements tostrands
list.addIdentifierSet
(PdbResidueIdentifier element) Adds one element toidentifierSet
set.addIdentifierSet
(PdbResidueIdentifier... elements) Adds elements toidentifierSet
set.addStrands
(Strand element) Adds one element tostrands
list.addStrands
(Strand... elements) Adds elements tostrands
list.build()
Builds a newImmutableDefaultDotBracketFromPdb
.from
(pl.poznan.put.structure.formats.AbstractDotBracket instance) Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.AbstractDotBracket
instance.from
(DefaultDotBracketFromPdb instance) Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.DefaultDotBracketFromPdb
instance.from
(DotBracket instance) Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.DotBracket
instance.from
(DotBracketFromPdb instance) Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.DotBracketFromPdb
instance.identifierSet
(Iterable<? extends PdbResidueIdentifier> elements) Sets or replaces all elements foridentifierSet
set.Initializes the value for themodel
attribute.Initializes the value for thesequence
attribute.Sets or replaces all elements forstrands
list.Initializes the value for thestructure
attribute.
-
Method Details
-
from
Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.DefaultDotBracketFromPdb
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.DotBracketFromPdb
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
public final ImmutableDefaultDotBracketFromPdb.Builder from(pl.poznan.put.structure.formats.AbstractDotBracket instance) Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.AbstractDotBracket
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
from
Fill a builder with attribute values from the providedpl.poznan.put.structure.formats.DotBracket
instance.- Parameters:
instance
- The instance from which to copy values- Returns:
this
builder for use in a chained invocation
-
addIdentifierSet
public final ImmutableDefaultDotBracketFromPdb.Builder addIdentifierSet(PdbResidueIdentifier element) Adds one element toidentifierSet
set.- Parameters:
element
- A identifierSet element- Returns:
this
builder for use in a chained invocation
-
addIdentifierSet
public final ImmutableDefaultDotBracketFromPdb.Builder addIdentifierSet(PdbResidueIdentifier... elements) Adds elements toidentifierSet
set.- Parameters:
elements
- An array of identifierSet elements- Returns:
this
builder for use in a chained invocation
-
identifierSet
public final ImmutableDefaultDotBracketFromPdb.Builder identifierSet(Iterable<? extends PdbResidueIdentifier> elements) Sets or replaces all elements foridentifierSet
set.- Parameters:
elements
- An iterable of identifierSet elements- Returns:
this
builder for use in a chained invocation
-
addAllIdentifierSet
public final ImmutableDefaultDotBracketFromPdb.Builder addAllIdentifierSet(Iterable<? extends PdbResidueIdentifier> elements) Adds elements toidentifierSet
set.- Parameters:
elements
- An iterable of identifierSet elements- Returns:
this
builder for use in a chained invocation
-
model
Initializes the value for themodel
attribute.- Parameters:
model
- The value for model- Returns:
this
builder for use in a chained invocation
-
addStrands
Adds one element tostrands
list.- Parameters:
element
- A strands element- Returns:
this
builder for use in a chained invocation
-
addStrands
Adds elements tostrands
list.- Parameters:
elements
- An array of strands elements- Returns:
this
builder for use in a chained invocation
-
strands
Sets or replaces all elements forstrands
list.- Parameters:
elements
- An iterable of strands elements- Returns:
this
builder for use in a chained invocation
-
addAllStrands
public final ImmutableDefaultDotBracketFromPdb.Builder addAllStrands(Iterable<? extends Strand> elements) Adds elements tostrands
list.- Parameters:
elements
- An iterable of strands elements- Returns:
this
builder for use in a chained invocation
-
sequence
Initializes the value for thesequence
attribute.- Parameters:
sequence
- The value for sequence- Returns:
this
builder for use in a chained invocation
-
structure
Initializes the value for thestructure
attribute.- Parameters:
structure
- The value for structure- Returns:
this
builder for use in a chained invocation
-
build
Builds a newImmutableDefaultDotBracketFromPdb
.- Returns:
- An immutable instance of DefaultDotBracketFromPdb
- Throws:
IllegalStateException
- if any required attributes are missing
-