Package org.biojava.nbio.structure.cath
Class CathInstallation
- java.lang.Object
-
- org.biojava.nbio.structure.cath.CathInstallation
-
- All Implemented Interfaces:
CathDatabase
public class CathInstallation extends Object implements CathDatabase
- Author:
- Daniel Asarnow
-
-
Field Summary
Fields Modifier and Type Field Description static StringCATH_DOWNLOAD_ALL_RELEASES_DIRstatic StringCATH_DOWNLOAD_CLASSIFICATION_DATA_DIRstatic StringCATH_DOWNLOAD_URLstatic StringDEFAULT_VERSIONstatic StringdomainDescriptionFileNamestatic StringdomainListFileNamestatic StringdomallFileNamestatic StringFILESPLITstatic StringNEWLINEstatic StringnodeListFileName
-
Constructor Summary
Constructors Constructor Description CathInstallation()CathInstallation(String cacheLocation)CathInstallation(String cacheLocation, boolean usingCDDF, boolean parseCF)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddownloadDomainDescriptionFile()protected voiddownloadDomainListFile()protected voiddownloadDomallFile()protected voiddownloadFileFromRemote(URL remoteURL, File localFile)protected voiddownloadNodeListFile()voidensureDomainDescriptionInstalled()voidensureDomainListInstalled()voidensureDomallInstalled()voidensureNodeListInstalled()List<CathDomain>filterByCathCode(String query)Return list of CATH descriptions whose CATH codes (e.g. 1.4.6.10) start with the query.List<CathDomain>filterByDescription(String query)Return list of CATH descriptions whose descriptions (name field) starts with the query.List<CathDomain>filterByNodeName(String query)Return list of CATH domains whose node name (e.g.List<CathDomain>getByCategory(CathCategory category)Return list of CATH descriptions for node representatives at a CATH category (e.g.StringgetCacheLocation()StringgetCathDownloadUrl()CathNodegetCathNode(String nodeId)Return the CathNode for a node ID.StringgetCathVersion()Return the CATH release version.CathDomaingetDescriptionByCathId(String cathId)Return CATH description for CATH domain ID.CathDomaingetDescriptionByNodeId(String nodeId)Return CATH description for node representative by node ID.CathDomaingetDomainByCathId(String cathId)Return CATH domain for CATH domain ID.StringgetDomainDescriptionFileName()StringgetDomainListFileName()List<CathDomain>getDomainsByNodeId(String nodeId)Return all CATH domains for a particular CATH node.List<CathDomain>getDomainsForPdb(String pdbId)Return all CATH domains for a PDB ID.StringgetDomallFileName()List<CathFragment>getFragmentsByPdbId(String pdbId)AtomicBooleangetInstalledDomainDescription()AtomicBooleangetInstalledDomainList()AtomicBooleangetInstalledDomall()AtomicBooleangetInstalledNodeList()StringgetNodeListFileName()List<CathNode>getTree(CathDomain domain)Return the CATH sub-tree for a particular domain.voidsetCacheLocation(String cacheLocation)voidsetCathDownloadUrl(String cathDownloadUrl)voidsetCathVersion(String cathVersion)voidsetInstalledDomainDescription(AtomicBoolean installedDomainDescription)voidsetInstalledDomainList(AtomicBoolean installedDomainList)voidsetInstalledDomall(AtomicBoolean installedDomall)voidsetInstalledNodeList(AtomicBoolean installedNodeList)
-
-
-
Field Detail
-
DEFAULT_VERSION
public static final String DEFAULT_VERSION
- See Also:
- Constant Field Values
-
domainListFileName
public static final String domainListFileName
- See Also:
- Constant Field Values
-
domainDescriptionFileName
public static final String domainDescriptionFileName
- See Also:
- Constant Field Values
-
nodeListFileName
public static final String nodeListFileName
- See Also:
- Constant Field Values
-
domallFileName
public static final String domallFileName
- See Also:
- Constant Field Values
-
CATH_DOWNLOAD_URL
public static final String CATH_DOWNLOAD_URL
- See Also:
- Constant Field Values
-
CATH_DOWNLOAD_ALL_RELEASES_DIR
public static final String CATH_DOWNLOAD_ALL_RELEASES_DIR
- See Also:
- Constant Field Values
-
CATH_DOWNLOAD_CLASSIFICATION_DATA_DIR
public static final String CATH_DOWNLOAD_CLASSIFICATION_DATA_DIR
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
CathInstallation
public CathInstallation(String cacheLocation, boolean usingCDDF, boolean parseCF)
-
CathInstallation
public CathInstallation(String cacheLocation)
-
CathInstallation
public CathInstallation()
-
-
Method Detail
-
getDomainListFileName
public String getDomainListFileName()
-
getDomainDescriptionFileName
public String getDomainDescriptionFileName()
-
getNodeListFileName
public String getNodeListFileName()
-
getDomallFileName
public String getDomallFileName()
-
getCathDownloadUrl
public String getCathDownloadUrl()
-
setCathDownloadUrl
public void setCathDownloadUrl(String cathDownloadUrl)
-
getCacheLocation
public String getCacheLocation()
-
setCacheLocation
public void setCacheLocation(String cacheLocation)
-
getInstalledDomainList
public AtomicBoolean getInstalledDomainList()
-
setInstalledDomainList
public void setInstalledDomainList(AtomicBoolean installedDomainList)
-
getInstalledDomainDescription
public AtomicBoolean getInstalledDomainDescription()
-
setInstalledDomainDescription
public void setInstalledDomainDescription(AtomicBoolean installedDomainDescription)
-
getInstalledNodeList
public AtomicBoolean getInstalledNodeList()
-
getInstalledDomall
public AtomicBoolean getInstalledDomall()
-
setInstalledNodeList
public void setInstalledNodeList(AtomicBoolean installedNodeList)
-
setInstalledDomall
public void setInstalledDomall(AtomicBoolean installedDomall)
-
getCathVersion
public String getCathVersion()
Description copied from interface:CathDatabaseReturn the CATH release version.- Specified by:
getCathVersionin interfaceCathDatabase- Returns:
- CATH version
-
getCathNode
public CathNode getCathNode(String nodeId)
Description copied from interface:CathDatabaseReturn the CathNode for a node ID.- Specified by:
getCathNodein interfaceCathDatabase- Returns:
- CATH node
-
getByCategory
public List<CathDomain> getByCategory(CathCategory category)
Description copied from interface:CathDatabaseReturn list of CATH descriptions for node representatives at a CATH category (e.g. "T").- Specified by:
getByCategoryin interfaceCathDatabase- Returns:
- CATH descriptions
-
filterByCathCode
public List<CathDomain> filterByCathCode(String query)
Description copied from interface:CathDatabaseReturn list of CATH descriptions whose CATH codes (e.g. 1.4.6.10) start with the query. This is currently redundant with getDescriptionsByNodeId.- Specified by:
filterByCathCodein interfaceCathDatabase- Returns:
- CATH descriptions
-
getTree
public List<CathNode> getTree(CathDomain domain)
Description copied from interface:CathDatabaseReturn the CATH sub-tree for a particular domain.- Specified by:
getTreein interfaceCathDatabase- Returns:
- CATH sub-tree
-
filterByNodeName
public List<CathDomain> filterByNodeName(String query)
Description copied from interface:CathDatabaseReturn list of CATH domains whose node name (e.g. Orthogonal Bundle) starts with the query.- Specified by:
filterByNodeNamein interfaceCathDatabase- Returns:
- CATH domains
-
filterByDescription
public List<CathDomain> filterByDescription(String query)
Description copied from interface:CathDatabaseReturn list of CATH descriptions whose descriptions (name field) starts with the query.- Specified by:
filterByDescriptionin interfaceCathDatabase- Returns:
- CATH descriptions
-
getDescriptionByNodeId
public CathDomain getDescriptionByNodeId(String nodeId)
Description copied from interface:CathDatabaseReturn CATH description for node representative by node ID.- Specified by:
getDescriptionByNodeIdin interfaceCathDatabase- Returns:
- CATH description
-
getDomainsForPdb
public List<CathDomain> getDomainsForPdb(String pdbId)
Description copied from interface:CathDatabaseReturn all CATH domains for a PDB ID.- Specified by:
getDomainsForPdbin interfaceCathDatabase- Returns:
- CATH domains
-
getDomainByCathId
public CathDomain getDomainByCathId(String cathId)
Description copied from interface:CathDatabaseReturn CATH domain for CATH domain ID.- Specified by:
getDomainByCathIdin interfaceCathDatabase- Returns:
- CATH domain
-
getDescriptionByCathId
public CathDomain getDescriptionByCathId(String cathId)
Description copied from interface:CathDatabaseReturn CATH description for CATH domain ID.- Specified by:
getDescriptionByCathIdin interfaceCathDatabase- Returns:
-
getDomainsByNodeId
public List<CathDomain> getDomainsByNodeId(String nodeId)
Description copied from interface:CathDatabaseReturn all CATH domains for a particular CATH node.- Specified by:
getDomainsByNodeIdin interfaceCathDatabase- Returns:
-
getFragmentsByPdbId
public List<CathFragment> getFragmentsByPdbId(String pdbId)
- Specified by:
getFragmentsByPdbIdin interfaceCathDatabase
-
downloadFileFromRemote
protected void downloadFileFromRemote(URL remoteURL, File localFile) throws IOException
- Throws:
IOException
-
downloadDomainListFile
protected void downloadDomainListFile() throws IOException
- Throws:
IOException
-
downloadDomainDescriptionFile
protected void downloadDomainDescriptionFile() throws IOException
- Throws:
IOException
-
downloadNodeListFile
protected void downloadNodeListFile() throws IOException
- Throws:
IOException
-
downloadDomallFile
protected void downloadDomallFile() throws IOException
- Throws:
IOException
-
ensureDomainListInstalled
public void ensureDomainListInstalled()
-
ensureDomainDescriptionInstalled
public void ensureDomainDescriptionInstalled()
-
ensureNodeListInstalled
public void ensureNodeListInstalled()
-
ensureDomallInstalled
public void ensureDomallInstalled()
-
setCathVersion
public void setCathVersion(String cathVersion)
-
-