|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.biojava.bio.structure.StructureImpl
public class StructureImpl
Implementation of a PDB Structure. This class provides the data contained in a PDB file. to get structure objects from different sources see io package.
| Constructor Summary | |
|---|---|
StructureImpl()
Constructs a StructureImpl object. |
|
StructureImpl(Chain c)
construct a Structure object that contains a particular chain |
|
StructureImpl(Group g)
construct a Structure object that only contains a single group |
|
| Method Summary | |
|---|---|
void |
addChain(Chain chain)
add a new chain. |
void |
addChain(Chain chain,
int modelnr)
add a new chain, if several models are available. |
void |
addModel(List model)
add a new model. |
Object |
clone()
returns an identical copy of this structure . |
Chain |
findChain(String chainId)
request a particular chain from a structure. |
Chain |
findChain(String chainId,
int modelnr)
request a particular chain from a particular model |
Group |
findGroup(String chainName,
String pdbResnum)
request a particular group from a structure. |
Group |
findGroup(String chainId,
String pdbResnum,
int modelnr)
request a particular group from a structure. |
Chain |
getChain(int number)
retrieve a chain by it's position within the Structure. |
Chain |
getChain(int modelnr,
int number)
retrieve a chain by it's position within the Structure and model number. |
Chain |
getChainByPDB(String chainId)
request a chain by it's PDB code by default takes only the first model |
Chain |
getChainByPDB(String chainId,
int modelnr)
request a chain by it's PDB code by default takes only the first model |
List |
getChains(int modelnr)
retrieve all chains of a model. |
List |
getConnections()
Returns the connections value. |
Map |
getHeader()
get Header data. |
List |
getModel(int modelnr)
retrieve all Chains belonging to a model . |
String |
getName()
get biological name of Structure. |
String |
getPDBCode()
get PDB code of structure . |
boolean |
hasChain(String chainId)
check if a chain with the id chainId is contained in this structure. |
boolean |
isNmr()
is this structure an nmr structure ? |
int |
nrModels()
return number of models. |
void |
setConnections(List conns)
sets/gets an List of Maps which corresponds to the CONECT lines in the PDB file: |
void |
setHeader(Map h)
set the Header data. |
void |
setName(String nam)
set biological name of Structure. |
void |
setNmr(boolean nmr)
set NMR flag. |
void |
setPDBCode(String pdb_id_)
set PDB code of structure . |
int |
size()
return number of chains , if NMR return number of chains of first model . |
int |
size(int modelnr)
return number of chains of model. |
String |
toPDB()
create a String that contains the contents of a PDB file. |
String |
toString()
string representation. |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public StructureImpl()
public StructureImpl(Group g)
g - public StructureImpl(Chain c)
c - | Method Detail |
|---|
public Object clone()
clone in interface Structureclone in class Object
public Group findGroup(String chainId,
String pdbResnum,
int modelnr)
throws StructureException
Structure
findGroup in interface StructurechainId - the ID of the chain to usepdbResnum - the PDB residue number of the requested groupmodelnr - the number of the model to use
StructureException
public Group findGroup(String chainName,
String pdbResnum)
throws StructureException
Structure
findGroup in interface StructurechainName - the ID of the chain to usepdbResnum - the PDB residue number of the requested group
StructureException
public Chain findChain(String chainId,
int modelnr)
throws StructureException
Structure
findChain in interface StructurechainId - the ID of a chain that should be returnedmodelnr - the number of the model to use
StructureException
public Chain findChain(String chainId)
throws StructureException
Structure
findChain in interface StructurechainId - the ID of a chain that should be returned
StructureExceptionpublic void setPDBCode(String pdb_id_)
setPDBCode in interface Structurepdb_id_ - a String specifying the PDBCodegetPDBCode()public String getPDBCode()
getPDBCode in interface StructuresetPDBCode(java.lang.String)public void setName(String nam)
setName in interface Structurenam - a String specifying the biological name of the StructuregetName()public String getName()
getName in interface StructuresetName(java.lang.String)public void setHeader(Map h)
setHeader in interface Structureh - a Map object specifying the headergetHeader()public Map getHeader()
getHeader in interface StructuresetHeader(java.util.Map)public void setConnections(List conns)
Structure
COLUMNS DATA TYPE FIELD DEFINITION
---------------------------------------------------------------------------------
1 - 6 Record name "CONECT"
7 - 11 Integer serial Atom serial number
12 - 16 Integer serial Serial number of bonded atom
17 - 21 Integer serial Serial number of bonded atom
22 - 26 Integer serial Serial number of bonded atom
27 - 31 Integer serial Serial number of bonded atom
32 - 36 Integer serial Serial number of hydrogen bonded
atom
37 - 41 Integer serial Serial number of hydrogen bonded
atom
42 - 46 Integer serial Serial number of salt bridged
atom
47 - 51 Integer serial Serial number of hydrogen bonded
atom
52 - 56 Integer serial Serial number of hydrogen bonded
atom
57 - 61 Integer serial Serial number of salt bridged
atom
the HashMap for a single CONECT line contains the following fields:
setConnections in interface Structureconns - a List object specifying the connectionsinterface.public List getConnections()
getConnections in interface Structureinterface,
setConnections(java.util.List)public void addChain(Chain chain)
addChain in interface Structurechain - a Chain object
public void addChain(Chain chain,
int modelnr)
addChain in interface Structurechain - a Chain objectmodelnr - an int specifying to which model the Chain should be addedpublic Chain getChain(int number)
getChain in interface Structurenumber - an int
public Chain getChain(int modelnr,
int number)
getChain in interface Structuremodelnr - an intnumber - an int
public void addModel(List model)
addModel in interface Structuremodel - a List object containing the Chains of the new Modelpublic String toString()
toString in interface StructuretoString in class Objectpublic int size()
size in interface Structurepublic int size(int modelnr)
size in interface Structuremodelnr - an int specifying the number of the Model that should be used
public int nrModels()
nrModels in interface Structurepublic boolean isNmr()
isNmr in interface Structurepublic void setNmr(boolean nmr)
Structure
setNmr in interface Structurenmr - true to declare that this Structure has been solved by NMR.public List getChains(int modelnr)
getChains in interface Structuremodelnr - an int
Structure.getModel(int)public List getModel(int modelnr)
getModel in interface Structuremodelnr - an int
Structure.getChains(int)
public Chain getChainByPDB(String chainId,
int modelnr)
throws StructureException
Structure
getChainByPDB in interface StructurechainId - the chain identifiermodelnr - request a particular model;
StructureException
public Chain getChainByPDB(String chainId)
throws StructureException
Structure
getChainByPDB in interface StructurechainId - the chain identifier
StructureExceptionpublic String toPDB()
toPDB in interface Structurepublic boolean hasChain(String chainId)
Structure
hasChain in interface StructurechainId - the name of the chain
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||