public class StructureImpl extends Object implements Structure, Serializable
Constructor and Description |
---|
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
|
Modifier and Type | Method and Description |
---|---|
void |
addChain(Chain chain)
Add a new chain.
|
void |
addChain(Chain chain,
int modelnr)
Add a new chain, if several models are available.
|
void |
addCompound(Compound compound)
Add a Compound to this Structure
|
void |
addModel(List<Chain> model)
Add a new model.
|
void |
addSSBond(Bond ssbond)
Adds a single disulfide Bond to this structure
|
Structure |
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 its position within the Structure .
|
Chain |
getChain(int modelnr,
int number)
Retrieve a chain by its position within the Structure and model number.
|
Chain |
getChainByPDB(String chainId)
Request a chain by its PDB code
by default takes only the first model
|
Chain |
getChainByPDB(String chainId,
int modelnr)
Request a chain by its PDB code
by default takes only the first model
|
List<Chain> |
getChains()
Retrieve all chains - if it is a NMR structure will return the chains of the first model.
|
List<Chain> |
getChains(int modelnr)
retrieve all chains of a model.
|
Compound |
getCompoundById(int molId)
Request a particular compound by its molId (entity_id in mmCIF dictionary)
|
List<Compound> |
getCompounds()
Get all the Compounds for this Structure.
|
List<Map<String,Integer>> |
getConnections()
Return the connections value.
|
PDBCrystallographicInfo |
getCrystallographicInfo()
Gets crystallographic information for this structure
|
List<DBRef> |
getDBRefs()
Get the list of database references
|
List<Group> |
getHetGroups()
Caution: we should probably remove this to avoid confusion.
|
Long |
getId()
get the ID used by Hibernate
|
String |
getIdentifier()
Get a string representing this structure's contents.
|
JournalArticle |
getJournalArticle()
get the associated publication as defined by the JRNL records in a PDB
file.
|
List<Chain> |
getModel(int modelnr)
retrieve all Chains belonging to a model .
|
String |
getName()
Get biological name of Structure.
|
String |
getPDBCode()
Get PDB code of structure.
|
PDBHeader |
getPDBHeader()
Return the header information for this PDB file
|
String |
getPdbId()
Deprecated.
|
List<String> |
getRanges()
Deprecated.
|
List<ResidueRange> |
getResidueRanges()
Deprecated.
|
List<Site> |
getSites() |
List<Bond> |
getSSBonds()
Get the list of disulfide Bonds as they have been defined in the PDB files
|
StructureIdentifier |
getStructureIdentifier()
Get an identifier corresponding to this structure
|
boolean |
hasChain(String chainId)
Check if a chain with the id chainId is contained in this structure.
|
boolean |
hasJournalArticle()
Return whether or not the entry has an associated journal article
or publication.
|
boolean |
isBiologicalAssembly()
Gets flag that indicates if this structure is a biological assembly
|
boolean |
isCrystallographic()
Whether this Structure is a crystallographic structure or not.
|
boolean |
isNmr()
Whether this Structure is a NMR structure or not.
|
int |
nrModels()
return number of models.
|
void |
resetModels()
Resets all models of this Structure
|
void |
setBiologicalAssembly(boolean biologicalAssembly)
Sets a flag to indicate if this structure is a biological assembly
|
void |
setChains(int modelnr,
List<Chain> chains)
Set the chains for a model
|
void |
setChains(List<Chain> chains)
Set the chains of a structure, if this is a NMR structure,
this will only set model 0.
|
void |
setCompounds(List<Compound> molList)
Set the Compounds
|
void |
setConnections(List<Map<String,Integer>> conns)
sets/gets an List of Maps which corresponds to the CONECT lines in the PDB file:
|
void |
setCrystallographicInfo(PDBCrystallographicInfo crystallographicInfo)
Sets crystallographic information for this structure
|
void |
setDBRefs(List<DBRef> dbrefs)
Set the list of database references for this structure
|
void |
setId(Long id)
set the ID used by Hibernate
|
void |
setJournalArticle(JournalArticle journalArticle)
set the associated publication as defined by the JRNL records in a PDB
file.
|
void |
setModel(int position,
List<Chain> model)
A convenience function if one wants to edit and replace the
models in a structure.
|
void |
setName(String nam)
Set biological name of Structure .
|
void |
setNmr(boolean nmr)
Deprecated.
|
void |
setPDBCode(String pdb_id_)
Set PDB code of structure .
|
void |
setPDBHeader(PDBHeader pdbHeader)
Set the the header information for this PDB file
|
void |
setSites(List<Site> sites) |
void |
setSSBonds(List<Bond> ssbonds)
Set the list of SSBonds for this structure
|
void |
setStructureIdentifier(StructureIdentifier structureIdentifier)
Set the identifier corresponding to this 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 |
toMMCIF()
Create a String that contains this Structure's contents in MMCIF file format.
|
String |
toPDB()
Create a String that contains this Structure's contents in PDB file format.
|
String |
toString()
string representation.
|
public StructureImpl()
public StructureImpl(Group g)
g
- public StructureImpl(Chain c)
c
- public Long getId()
public void setId(Long id)
public Structure clone()
public Group findGroup(String chainId, String pdbResnum, int modelnr) throws StructureException
findGroup
in interface Structure
chainId
- the ID of the chain to usepdbResnum
- the PDB residue number of the requested groupmodelnr
- the number of the model to useStructureException
public Group findGroup(String chainName, String pdbResnum) throws StructureException
findGroup
in interface Structure
chainName
- the ID of the chain to usepdbResnum
- the PDB residue number of the requested groupStructureException
public Chain findChain(String chainId, int modelnr) throws StructureException
findChain
in interface Structure
chainId
- the ID of a chain that should be returnedmodelnr
- the number of the model to useStructureException
public Chain findChain(String chainId) throws StructureException
findChain
in interface Structure
chainId
- the ID of a chain that should be returnedStructureException
public void setPDBCode(String pdb_id_)
setPDBCode
in interface Structure
pdb_id_
- a String specifying the PDBCodeStructure.getPDBCode()
public String getPDBCode()
getPDBCode
in interface Structure
Structure.setPDBCode(java.lang.String)
public void setName(String nam)
setName
in interface Structure
nam
- a String specifying the biological name of the StructureStructure.getName()
public String getName()
getName
in interface Structure
Structure.setName(java.lang.String)
public StructureIdentifier getStructureIdentifier()
Structure
getStructureIdentifier
in interface Structure
public void setStructureIdentifier(StructureIdentifier structureIdentifier)
Structure
setStructureIdentifier
in interface Structure
structureIdentifier
- the structureIdentifier corresponding to this structurepublic void setConnections(List<Map<String,Integer>> conns)
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 atomthe HashMap for a single CONECT line contains the following fields:
setConnections
in interface Structure
conns
- a List object specifying the connectionsStructure.getConnections()
public List<Map<String,Integer>> getConnections()
getConnections
in interface Structure
Structure.setConnections(java.util.List<java.util.Map<java.lang.String, java.lang.Integer>>)
public void addChain(Chain chain)
public void addChain(Chain chain, int modelnr)
public Chain getChain(int number)
public Chain getChain(int modelnr, int number)
public void setChains(List<Chain> chains)
setChains
in interface Structure
chains
- the list of chains for this structure.Structure.setChains(int, List)
public void setModel(int position, List<Chain> model)
public String toString()
public int size()
public int size(int modelnr)
public int nrModels()
nrModels
in interface Structure
Structure.isNmr()
public boolean isCrystallographic()
isCrystallographic
in interface Structure
public boolean isNmr()
isNmr
in interface Structure
Structure.nrModels()
@Deprecated public void setNmr(boolean nmr)
public List<Chain> getChains(int modelnr)
getChains
in interface Structure
modelnr
- an intStructure.getModel(int)
public List<Chain> getChains()
getChains
in interface Structure
Structure.getModel(int modelnr)
,
Structure.getChains(int modelnr)
public List<Chain> getModel(int modelnr)
getModel
in interface Structure
modelnr
- an intStructure.getChains(int modelnr)
public Chain getChainByPDB(String chainId, int modelnr) throws StructureException
getChainByPDB
in interface Structure
chainId
- the chain identifiermodelnr
- request a particular model;StructureException
public Chain getChainByPDB(String chainId) throws StructureException
getChainByPDB
in interface Structure
chainId
- the chain identifierStructureException
public String toPDB()
toPDB
in interface Structure
FileConvert
public String toMMCIF()
public boolean hasChain(String chainId)
public void setCompounds(List<Compound> molList)
setCompounds
in interface Structure
public void addCompound(Compound compound)
addCompound
in interface Structure
public List<Compound> getCompounds()
getCompounds
in interface Structure
public Compound getCompoundById(int molId)
getCompoundById
in interface Structure
public void setDBRefs(List<DBRef> dbrefs)
public PDBHeader getPDBHeader()
getPDBHeader
in interface Structure
public void setPDBHeader(PDBHeader pdbHeader)
setPDBHeader
in interface Structure
pdbHeader
- the PDBHeader objectpublic List<Bond> getSSBonds()
getSSBonds
in interface Structure
public void setSSBonds(List<Bond> ssbonds)
setSSBonds
in interface Structure
public void addSSBond(Bond ssbond)
public boolean hasJournalArticle()
hasJournalArticle
in interface Structure
public JournalArticle getJournalArticle()
getJournalArticle
in interface Structure
public void setJournalArticle(JournalArticle journalArticle)
setJournalArticle
in interface Structure
journalArticle
- the articlepublic List<Group> getHetGroups()
getHetGroups
in interface Structure
public void setBiologicalAssembly(boolean biologicalAssembly)
setBiologicalAssembly
in interface Structure
biologicalAssembly
- true if biological assembly, otherwise falsepublic boolean isBiologicalAssembly()
isBiologicalAssembly
in interface Structure
public void setCrystallographicInfo(PDBCrystallographicInfo crystallographicInfo)
setCrystallographicInfo
in interface Structure
crystallographicInfo
- crystallographic informationpublic PDBCrystallographicInfo getCrystallographicInfo()
getCrystallographicInfo
in interface Structure
public String getIdentifier()
Structure.getStructureIdentifier()
.getIdentifier(), which should give
the string originally used to create the structure
Structure.getName()
Structure.getPDBCode()
with a heuristic description
of the residue ranges, in SubstructureIdentifier
format.
getIdentifier
in interface Structure
SubstructureIdentifier
-format string describing the residue ranges in this structure@Deprecated public String getPdbId()
public void resetModels()
resetModels
in interface Structure
@Deprecated public List<ResidueRange> getResidueRanges()
ResidueRanges
that this StructureIdentifier defines.
This is a unique representation.getResidueRanges
in interface Structure
@Deprecated public List<String> getRanges()
getRanges().get(0): 'A' getRanges().get(1): 'B_5-100'This is a unique representation.
Copyright © 2000–2016 BioJava. All rights reserved.