Package pl.poznan.put.pdb.analysis
Class ImmutableCifContainer
java.lang.Object
pl.poznan.put.pdb.analysis.CifContainer
pl.poznan.put.pdb.analysis.ImmutableCifContainer
- All Implemented Interfaces:
Closeable,AutoCloseable,ModelContainer
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
public final class ImmutableCifContainer
extends CifContainer
Immutable implementation of
CifContainer.
Use the builder to create immutable instances:
ImmutableCifContainer.builder().
Use the static factory method to create immutable instances:
ImmutableCifContainer.of().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableCifContainer. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forImmutableCifContainer.cifFile()static ImmutableCifContainercopyOf(CifContainer instance) Creates an immutable copy of aCifContainervalue.booleanThis instance is equal to all instances ofImmutableCifContainerthat have equal attribute values.inthashCode()Computes a hash code from attributes:fileChainMap,cifFile.static ImmutableCifContainerof(File cifFile, Map<? extends File, ? extends org.apache.commons.collections4.BidiMap<String, String>> fileChainMap) Construct a new immutableCifContainerinstance.toString()Prints the immutable valueCifContainerwith attribute values.final ImmutableCifContainerwithCifFile(File value) Copy the current immutable object by setting a value for thecifFileattribute.final ImmutableCifContainerwithFileChainMap(Map<? extends File, ? extends org.apache.commons.collections4.BidiMap<String, String>> entries) Copy the current immutable object by replacing thefileChainMapmap with the specified map.Methods inherited from class pl.poznan.put.pdb.analysis.CifContainer
close, convertedPdbChainName, emptyInstance, originalCifChainName, pdbFiles
-
Method Details
-
fileChainMap
- Specified by:
fileChainMapin classCifContainer- Returns:
- The mapping of chain name in PDB and mmCIF for a specific file.
-
cifFile
- Specified by:
cifFilein classCifContainer- Returns:
- The value of the
cifFileattribute,
-
withFileChainMap
public final ImmutableCifContainer withFileChainMap(Map<? extends File, ? extends org.apache.commons.collections4.BidiMap<String, String>> entries) Copy the current immutable object by replacing thefileChainMapmap 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 fileChainMap map- Returns:
- A modified copy of
thisobject
-
withCifFile
Copy the current immutable object by setting a value for thecifFileattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for cifFile- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofImmutableCifContainerthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:fileChainMap,cifFile. -
toString
Prints the immutable valueCifContainerwith attribute values. -
of
public static ImmutableCifContainer of(File cifFile, Map<? extends File, ? extends org.apache.commons.collections4.BidiMap<String, String>> fileChainMap) Construct a new immutableCifContainerinstance.- Parameters:
cifFile- The value for thecifFileattributefileChainMap- The value for thefileChainMapattribute- Returns:
- An immutable CifContainer instance
-
copyOf
Creates an immutable copy of aCifContainervalue. 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 CifContainer instance
-
builder
Creates a builder forImmutableCifContainer.ImmutableCifContainer.builder() .putFileChainMap|putAllFileChainMap(java.io.File => org.apache.commons.collections4.BidiMap<String, String>) //fileChainMapmappings .cifFile(java.io.File) // requiredcifFile.build();- Returns:
- A new ImmutableCifContainer builder
-