Class AllChemCompProvider
- java.lang.Object
 - 
- org.biojava.nbio.structure.io.mmcif.AllChemCompProvider
 
 
- 
- All Implemented Interfaces:
 Runnable,ChemCompProvider
public class AllChemCompProvider extends Object implements ChemCompProvider, Runnable
A ChemComp provider that downloads and caches the components.cif file from the wwPDB site. It then loads all chemical components at startup and keeps them in memory. This provider is not used as a default since it is slower at startup and requires more memory than theDownloadChemCompProviderthat is used by default.- Author:
 - Andreas Prlic
 
 
- 
- 
Field Summary
Fields Modifier and Type Field Description static StringCOMPONENTS_FILE_LOCATION 
- 
Constructor Summary
Constructors Constructor Description AllChemCompProvider() 
- 
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static voiddownloadFile()Downloads the components.cif.gz file from the wwPDB site.ChemCompgetChemComp(String recordName)Returns a new instance of a chemical component definition.voidrun()Do the actual loading of the dictionary in a thread. 
 - 
 
- 
- 
Field Detail
- 
COMPONENTS_FILE_LOCATION
public static final String COMPONENTS_FILE_LOCATION
- See Also:
 - Constant Field Values
 
 
 - 
 
- 
Constructor Detail
- 
AllChemCompProvider
public AllChemCompProvider()
 
 - 
 
- 
Method Detail
- 
downloadFile
public static void downloadFile() throws IOException
Downloads the components.cif.gz file from the wwPDB site.- Throws:
 IOException
 
- 
getChemComp
public ChemComp getChemComp(String recordName)
Returns a new instance of a chemical component definition.- Specified by:
 getChemCompin interfaceChemCompProvider- Parameters:
 recordName- the ID of theChemComp- Returns:
 - a new 
ChemCompdefinition. 
 
 - 
 
 -