Package org.biojava.nbio.structure
Class PassthroughIdentifier
- java.lang.Object
-
- org.biojava.nbio.structure.PassthroughIdentifier
-
- All Implemented Interfaces:
Serializable,StructureIdentifier
public class PassthroughIdentifier extends Object implements StructureIdentifier
A stub StructureIdentifier, representing the full structure in all cases.- Author:
- Spencer Bliven
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PassthroughIdentifier(String identifier)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetIdentifier()Get the String form of this identifier.StructureloadStructure(AtomCache cache)Passthrough identifiers don't know how to load a structureStructurereduce(Structure input)Takes a complete structure as input and reduces it to the substructure represented by this StructureIdentifier.SubstructureIdentifiertoCanonical()Convert to a canonical SubstructureIdentifier.
-
-
-
Constructor Detail
-
PassthroughIdentifier
public PassthroughIdentifier(String identifier)
-
-
Method Detail
-
getIdentifier
public String getIdentifier()
Description copied from interface:StructureIdentifierGet the String form of this identifier. It is recommended that the#toString()method also return the identifier, for consistency during serialization.- Specified by:
getIdentifierin interfaceStructureIdentifier- Returns:
- The String form of this identifier
-
toCanonical
public SubstructureIdentifier toCanonical()
Description copied from interface:StructureIdentifierConvert to a canonical SubstructureIdentifier.This allows all domains to be converted to a standard format String.
- Specified by:
toCanonicalin interfaceStructureIdentifier- Returns:
- A SubstructureIdentifier without ranges (e.g. including all residues)
-
reduce
public Structure reduce(Structure input) throws StructureException
Description copied from interface:StructureIdentifierTakes a complete structure as input and reduces it to the substructure represented by this StructureIdentifier.The returned structure may be a shallow copy of the input, with shared Chains, Residues, etc.
- Specified by:
reducein interfaceStructureIdentifier- Parameters:
input- A full structure, e.g. as loaded from the PDB. The structure ID should match that returned by getPdbId(), if applicable.- Returns:
- Throws:
StructureException- See Also:
StructureTools.getReducedStructure(Structure, String)
-
loadStructure
public Structure loadStructure(AtomCache cache) throws StructureException, IOException
Passthrough identifiers don't know how to load a structure- Specified by:
loadStructurein interfaceStructureIdentifier- Returns:
- null
- Throws:
StructureException- For errors loading and parsing the structureIOException- Errors reading the structure from disk
-
-