Class ImmutablePdbNamedResidueIdentifier

    • Method Detail

      • withChainIdentifier

        public final ImmutablePdbNamedResidueIdentifier withChainIdentifier​(String value)
        Copy the current immutable object by setting a value for the chainIdentifier attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for chainIdentifier
        Returns:
        A modified copy of the this object
      • withResidueNumber

        public final ImmutablePdbNamedResidueIdentifier withResidueNumber​(int value)
        Copy the current immutable object by setting a value for the residueNumber attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for residueNumber
        Returns:
        A modified copy of the this object
      • withInsertionCode

        public final ImmutablePdbNamedResidueIdentifier withInsertionCode​(String value)
        Copy the current immutable object by setting a value for the insertionCode attribute. An equals check used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for insertionCode
        Returns:
        A modified copy of the this object
      • withOneLetterName

        public final ImmutablePdbNamedResidueIdentifier withOneLetterName​(char value)
        Copy the current immutable object by setting a value for the oneLetterName attribute. A value equality check is used to prevent copying of the same value by returning this.
        Parameters:
        value - A new value for oneLetterName
        Returns:
        A modified copy of the this object
      • equals

        public boolean equals​(@Nullable
                              Object another)
        This instance is equal to all instances of ImmutablePdbNamedResidueIdentifier that have equal attribute values.
        Overrides:
        equals in class Object
        Returns:
        true if this is equal to another instance
      • hashCode

        public int hashCode()
        Computes a hash code from attributes: chainIdentifier, residueNumber, insertionCode, oneLetterName.
        Overrides:
        hashCode in class Object
        Returns:
        hashCode value
      • of

        public static ImmutablePdbNamedResidueIdentifier of​(String chainIdentifier,
                                                            int residueNumber,
                                                            String insertionCode,
                                                            char oneLetterName)
        Construct a new immutable PdbNamedResidueIdentifier instance.
        Parameters:
        chainIdentifier - The value for the chainIdentifier attribute
        residueNumber - The value for the residueNumber attribute
        insertionCode - The value for the insertionCode attribute
        oneLetterName - The value for the oneLetterName attribute
        Returns:
        An immutable PdbNamedResidueIdentifier instance