Package pl.poznan.put.pdb
Class ImmutablePdbAtomLine
- java.lang.Object
-
- pl.poznan.put.pdb.PdbAtomLine
-
- pl.poznan.put.pdb.ImmutablePdbAtomLine
-
- All Implemented Interfaces:
Serializable,Comparable<ChainNumberICode>,ChainNumberICode
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class ImmutablePdbAtomLine extends PdbAtomLine
Immutable implementation ofPdbAtomLine.Use the builder to create immutable instances:
ImmutablePdbAtomLine.builder(). Use the static factory method to create immutable instances:ImmutablePdbAtomLine.of().- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classImmutablePdbAtomLine.BuilderBuilds instances of typeImmutablePdbAtomLine.
-
Field Summary
-
Fields inherited from class pl.poznan.put.pdb.PdbAtomLine
CIF_LOOP
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringalternateLocation()StringatomName()static ImmutablePdbAtomLine.Builderbuilder()Creates a builder forImmutablePdbAtomLine.StringchainIdentifier()Stringcharge()static ImmutablePdbAtomLinecopyOf(PdbAtomLine instance)Creates an immutable copy of aPdbAtomLinevalue.StringelementSymbol()booleanequals(Object another)This instance is equal to all instances ofImmutablePdbAtomLinethat have equal attribute values.inthashCode()Computes a hash code from attributes:atomName,residueName,chainIdentifier,residueNumber,insertionCode,x,y,z.StringinsertionCode()doubleoccupancy()static ImmutablePdbAtomLineof(int serialNumber, String atomName, String alternateLocation, String residueName, String chainIdentifier, int residueNumber, String insertionCode, double x, double y, double z, double occupancy, double temperatureFactor, String elementSymbol, String charge)Construct a new immutablePdbAtomLineinstance.StringresidueName()intresidueNumber()intserialNumber()doubletemperatureFactor()ImmutablePdbAtomLinewithAlternateLocation(String value)Copy the current immutable object by setting a value for thealternateLocationattribute.ImmutablePdbAtomLinewithAtomName(String value)Copy the current immutable object by setting a value for theatomNameattribute.ImmutablePdbAtomLinewithChainIdentifier(String value)Copy the current immutable object by setting a value for thechainIdentifierattribute.ImmutablePdbAtomLinewithCharge(String value)Copy the current immutable object by setting a value for thechargeattribute.ImmutablePdbAtomLinewithElementSymbol(String value)Copy the current immutable object by setting a value for theelementSymbolattribute.ImmutablePdbAtomLinewithInsertionCode(String value)Copy the current immutable object by setting a value for theinsertionCodeattribute.ImmutablePdbAtomLinewithOccupancy(double value)Copy the current immutable object by setting a value for theoccupancyattribute.ImmutablePdbAtomLinewithResidueName(String value)Copy the current immutable object by setting a value for theresidueNameattribute.ImmutablePdbAtomLinewithResidueNumber(int value)Copy the current immutable object by setting a value for theresidueNumberattribute.ImmutablePdbAtomLinewithSerialNumber(int value)Copy the current immutable object by setting a value for theserialNumberattribute.ImmutablePdbAtomLinewithTemperatureFactor(double value)Copy the current immutable object by setting a value for thetemperatureFactorattribute.ImmutablePdbAtomLinewithX(double value)Copy the current immutable object by setting a value for thexattribute.ImmutablePdbAtomLinewithY(double value)Copy the current immutable object by setting a value for theyattribute.ImmutablePdbAtomLinewithZ(double value)Copy the current immutable object by setting a value for thezattribute.doublex()doubley()doublez()-
Methods inherited from class pl.poznan.put.pdb.PdbAtomLine
detectAtomName, distanceTo, fromBioJavaAtom, parse, parse, toBioJavaAtom, toCif, toPdb, toString, toVector3D
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface pl.poznan.put.pdb.ChainNumberICode
compareTo
-
-
-
-
Method Detail
-
serialNumber
public int serialNumber()
- Specified by:
serialNumberin classPdbAtomLine- Returns:
- The value of the
serialNumberattribute
-
atomName
public String atomName()
- Specified by:
atomNamein classPdbAtomLine- Returns:
- The value of the
atomNameattribute
-
alternateLocation
public String alternateLocation()
- Specified by:
alternateLocationin classPdbAtomLine- Returns:
- The value of the
alternateLocationattribute
-
residueName
public String residueName()
- Specified by:
residueNamein classPdbAtomLine- Returns:
- The value of the
residueNameattribute
-
chainIdentifier
public String chainIdentifier()
- Specified by:
chainIdentifierin interfaceChainNumberICode- Specified by:
chainIdentifierin classPdbAtomLine- Returns:
- The value of the
chainIdentifierattribute
-
residueNumber
public int residueNumber()
- Specified by:
residueNumberin interfaceChainNumberICode- Specified by:
residueNumberin classPdbAtomLine- Returns:
- The value of the
residueNumberattribute
-
insertionCode
public String insertionCode()
- Specified by:
insertionCodein interfaceChainNumberICode- Specified by:
insertionCodein classPdbAtomLine- Returns:
- The value of the
insertionCodeattribute
-
x
public double x()
- Specified by:
xin classPdbAtomLine- Returns:
- The value of the
xattribute
-
y
public double y()
- Specified by:
yin classPdbAtomLine- Returns:
- The value of the
yattribute
-
z
public double z()
- Specified by:
zin classPdbAtomLine- Returns:
- The value of the
zattribute
-
occupancy
public double occupancy()
- Specified by:
occupancyin classPdbAtomLine- Returns:
- The value of the
occupancyattribute
-
temperatureFactor
public double temperatureFactor()
- Specified by:
temperatureFactorin classPdbAtomLine- Returns:
- The value of the
temperatureFactorattribute
-
elementSymbol
public String elementSymbol()
- Specified by:
elementSymbolin classPdbAtomLine- Returns:
- The value of the
elementSymbolattribute
-
charge
public String charge()
- Specified by:
chargein classPdbAtomLine- Returns:
- The value of the
chargeattribute
-
withSerialNumber
public final ImmutablePdbAtomLine withSerialNumber(int value)
Copy the current immutable object by setting a value for theserialNumberattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for serialNumber- Returns:
- A modified copy of the
thisobject
-
withAtomName
public final ImmutablePdbAtomLine withAtomName(String value)
Copy the current immutable object by setting a value for theatomNameattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for atomName- Returns:
- A modified copy of the
thisobject
-
withAlternateLocation
public final ImmutablePdbAtomLine withAlternateLocation(String value)
Copy the current immutable object by setting a value for thealternateLocationattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for alternateLocation- Returns:
- A modified copy of the
thisobject
-
withResidueName
public final ImmutablePdbAtomLine withResidueName(String value)
Copy the current immutable object by setting a value for theresidueNameattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for residueName- Returns:
- A modified copy of the
thisobject
-
withChainIdentifier
public final ImmutablePdbAtomLine withChainIdentifier(String value)
Copy the current immutable object by setting a value for thechainIdentifierattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for chainIdentifier- Returns:
- A modified copy of the
thisobject
-
withResidueNumber
public final ImmutablePdbAtomLine withResidueNumber(int value)
Copy the current immutable object by setting a value for theresidueNumberattribute. A value equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for residueNumber- Returns:
- A modified copy of the
thisobject
-
withInsertionCode
public final ImmutablePdbAtomLine withInsertionCode(String value)
Copy the current immutable object by setting a value for theinsertionCodeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for insertionCode- Returns:
- A modified copy of the
thisobject
-
withX
public final ImmutablePdbAtomLine withX(double value)
Copy the current immutable object by setting a value for thexattribute. A value strict bits equality used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for x- Returns:
- A modified copy of the
thisobject
-
withY
public final ImmutablePdbAtomLine withY(double value)
Copy the current immutable object by setting a value for theyattribute. A value strict bits equality used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for y- Returns:
- A modified copy of the
thisobject
-
withZ
public final ImmutablePdbAtomLine withZ(double value)
Copy the current immutable object by setting a value for thezattribute. A value strict bits equality used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for z- Returns:
- A modified copy of the
thisobject
-
withOccupancy
public final ImmutablePdbAtomLine withOccupancy(double value)
Copy the current immutable object by setting a value for theoccupancyattribute. A value strict bits equality used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for occupancy- Returns:
- A modified copy of the
thisobject
-
withTemperatureFactor
public final ImmutablePdbAtomLine withTemperatureFactor(double value)
Copy the current immutable object by setting a value for thetemperatureFactorattribute. A value strict bits equality used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for temperatureFactor- Returns:
- A modified copy of the
thisobject
-
withElementSymbol
public final ImmutablePdbAtomLine withElementSymbol(String value)
Copy the current immutable object by setting a value for theelementSymbolattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for elementSymbol- Returns:
- A modified copy of the
thisobject
-
withCharge
public final ImmutablePdbAtomLine withCharge(String value)
Copy the current immutable object by setting a value for thechargeattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for charge- Returns:
- A modified copy of the
thisobject
-
equals
public boolean equals(@Nullable Object another)
This instance is equal to all instances ofImmutablePdbAtomLinethat have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:atomName,residueName,chainIdentifier,residueNumber,insertionCode,x,y,z.
-
of
public static ImmutablePdbAtomLine of(int serialNumber, String atomName, String alternateLocation, String residueName, String chainIdentifier, int residueNumber, String insertionCode, double x, double y, double z, double occupancy, double temperatureFactor, String elementSymbol, String charge)
Construct a new immutablePdbAtomLineinstance.- Parameters:
serialNumber- The value for theserialNumberattributeatomName- The value for theatomNameattributealternateLocation- The value for thealternateLocationattributeresidueName- The value for theresidueNameattributechainIdentifier- The value for thechainIdentifierattributeresidueNumber- The value for theresidueNumberattributeinsertionCode- The value for theinsertionCodeattributex- The value for thexattributey- The value for theyattributez- The value for thezattributeoccupancy- The value for theoccupancyattributetemperatureFactor- The value for thetemperatureFactorattributeelementSymbol- The value for theelementSymbolattributecharge- The value for thechargeattribute- Returns:
- An immutable PdbAtomLine instance
-
copyOf
public static ImmutablePdbAtomLine copyOf(PdbAtomLine instance)
Creates an immutable copy of aPdbAtomLinevalue. 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 PdbAtomLine instance
-
builder
public static ImmutablePdbAtomLine.Builder builder()
Creates a builder forImmutablePdbAtomLine.ImmutablePdbAtomLine.builder() .serialNumber(int) // requiredserialNumber.atomName(String) // requiredatomName.alternateLocation(String) // requiredalternateLocation.residueName(String) // requiredresidueName.chainIdentifier(String) // requiredchainIdentifier.residueNumber(int) // requiredresidueNumber.insertionCode(String) // requiredinsertionCode.x(double) // requiredx.y(double) // requiredy.z(double) // requiredz.occupancy(double) // requiredoccupancy.temperatureFactor(double) // requiredtemperatureFactor.elementSymbol(String) // requiredelementSymbol.charge(String) // requiredcharge.build();- Returns:
- A new ImmutablePdbAtomLine builder
-
-