Class Subunit
- java.lang.Object
-
- org.biojava.nbio.structure.cluster.Subunit
-
public class Subunit extends Object
A Subunit consists of a set of residues from a Structure, which may correspond to an entire Chain, a Domain, or any subset or combination of residues from them. All the residues of a Subunit are of the same type.The Subunit object can contain additional fields for identification and annotation.
- Since:
- 5.0.0
- Author:
- Aleix Lafita
-
-
Constructor Summary
Constructors Constructor Description Subunit(Atom[] reprAtoms, String name, StructureIdentifier identifier, Structure structure)
A Subunit is solely defined by the coordinates of the representative Atoms of its residues.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StructureIdentifier
getIdentifier()
The standard identifier of the Subunit.String
getName()
The Name of a Subunit is a free-text field, user defined.ProteinSequence
getProteinSequence()
Get the protein sequence of the Subunit.String
getProteinSequenceString()
Get the protein sequence of the Subunit as String.Atom[]
getRepresentativeAtoms()
Get all the representative Atoms of the Subunit.Structure
getStructure()
The parent Structure from which the Subunit atoms were obtained.void
setName(String name)
The Name of a Subunit is a free-text field, user defined.int
size()
The size of a Subunit is the number of residues it contains.String
toString()
-
-
-
Constructor Detail
-
Subunit
public Subunit(Atom[] reprAtoms, String name, StructureIdentifier identifier, Structure structure)
A Subunit is solely defined by the coordinates of the representative Atoms of its residues. It can be identified with a StructureIdentifier and/or a name and stores a reference to the Structure from which the Atoms were obtained.- Parameters:
reprAtoms
- representative Atoms. It cannot be null or emptyname
- String field that identifies the Subunit. It can be nullidentifier
- StructureIdentifier. It can be nullstructure
- parent Structure object. It can be null
-
-
Method Detail
-
getRepresentativeAtoms
public Atom[] getRepresentativeAtoms()
Get all the representative Atoms of the Subunit. These Atoms are used for clustering and displaying the Subunit.- Returns:
- representative Atom[]
-
size
public int size()
The size of a Subunit is the number of residues it contains.- Returns:
- the size of the Subunit
-
getProteinSequenceString
public String getProteinSequenceString()
Get the protein sequence of the Subunit as String.- Returns:
- protein sequence String
-
getProteinSequence
public ProteinSequence getProteinSequence() throws CompoundNotFoundException
Get the protein sequence of the Subunit.- Returns:
- sequence ProteinSequence
- Throws:
CompoundNotFoundException
-
getName
public String getName()
The Name of a Subunit is a free-text field, user defined.- Returns:
- the Subunit name
-
setName
public void setName(String name)
The Name of a Subunit is a free-text field, user defined.- Parameters:
name
- of the Subunit
-
getStructure
public Structure getStructure()
The parent Structure from which the Subunit atoms were obtained.- Returns:
- Structure object
-
getIdentifier
public StructureIdentifier getIdentifier()
The standard identifier of the Subunit.- Returns:
- StructureIdentifier object
-
-