Class RemotePDPProvider

  • All Implemented Interfaces:
    PDPProvider

    public class RemotePDPProvider
    extends SerializableCache<java.lang.String,​java.util.SortedSet<java.lang.String>>
    implements PDPProvider
    A class that provided PDP assignments that are loaded from a remote web server
    Author:
    Andreas Prlic
    • Constructor Detail

      • RemotePDPProvider

        public RemotePDPProvider()
      • RemotePDPProvider

        public RemotePDPProvider​(boolean useCache)
                          throws java.io.IOException
        Parameters:
        useCache -
        Throws:
        java.io.IOException
    • Method Detail

      • getServer

        public java.lang.String getServer()
      • setServer

        public void setServer​(java.lang.String server)
      • getDomain

        public Structure getDomain​(java.lang.String pdpDomainName,
                                   AtomCache cache)
                            throws java.io.IOException,
                                   StructureException
        Get the structure for a particular PDP domain
        Specified by:
        getDomain in interface PDPProvider
        Parameters:
        pdpDomainName - PDP identifier, e.g. "PDP:4HHBAa"
        cache - AtomCache, responsible for fetching and storing the coordinates
        Returns:
        Structure representing the PDP domain
        Throws:
        java.io.IOException - if the server cannot be reached
        StructureException - For errors parsing the structure
      • getPDPDomain

        public PDPDomain getPDPDomain​(java.lang.String pdpDomainName)
                               throws java.io.IOException
        Get a StructureIdentifier representing the specified PDP domain.
        Specified by:
        getPDPDomain in interface PDPProvider
        Parameters:
        pdpDomainName - PDP domain name
        Returns:
        a PDPDomain representing this domain name
        Throws:
        java.io.IOException - if the server cannot be reached
      • getPDPDomainNamesForPDB

        public java.util.SortedSet<java.lang.String> getPDPDomainNamesForPDB​(java.lang.String pdbId)
                                                                      throws java.io.IOException
        Get a list of all PDP domains for a given PDB entry
        Specified by:
        getPDPDomainNamesForPDB in interface PDPProvider
        Parameters:
        pdbId - PDB ID
        Returns:
        Set of domain names, e.g. "PDP:4HHBAa"
        Throws:
        java.io.IOException - if the server cannot be reached