Class CouchDbClientAndroid


  • public class CouchDbClientAndroid
    extends CouchDbClientBase
    Presents a client to CouchDB database server; targeted to run on Android platform.
    Since:
    0.1.0
    See Also:
    CouchDbClient
    • Constructor Detail

      • CouchDbClientAndroid

        public CouchDbClientAndroid()
        Constructs a new client instance.
      • CouchDbClientAndroid

        public CouchDbClientAndroid​(java.lang.String configFileName)
        Constructs a new client instance.
        Parameters:
        configFileName - The configuration file
      • CouchDbClientAndroid

        public CouchDbClientAndroid​(java.lang.String dbName,
                                    boolean createDbIfNotExist,
                                    java.lang.String protocol,
                                    java.lang.String host,
                                    int port,
                                    java.lang.String username,
                                    java.lang.String password)
        Constructs a new client instance.
        Parameters:
        dbName - The database name.
        createDbIfNotExist - To create a new database if it does not already exist.
        protocol - The protocol to use (i.e http or https)
        host - The database host address
        port - The database listening port
        username - The Username credential
        password - The Password credential
      • CouchDbClientAndroid

        public CouchDbClientAndroid​(CouchDbProperties properties)
        Constructs a new client instance.
        Parameters:
        properties - An object containing configuration properties.
    • Method Detail

      • createContext

        org.apache.http.protocol.HttpContext createContext()
        Specified by:
        createContext in class CouchDbClientBase
        Returns:
        HttpContext instance for HTTP request execution.
      • createRegistry

        private org.apache.http.conn.scheme.SchemeRegistry createRegistry​(CouchDbProperties properties)
                                                                   throws java.security.NoSuchAlgorithmException,
                                                                          java.security.KeyManagementException,
                                                                          java.security.KeyStoreException,
                                                                          java.security.cert.CertificateException,
                                                                          java.io.IOException,
                                                                          java.security.UnrecoverableKeyException
        Throws:
        java.security.NoSuchAlgorithmException
        java.security.KeyManagementException
        java.security.KeyStoreException
        java.security.cert.CertificateException
        java.io.IOException
        java.security.UnrecoverableKeyException
      • registerInterceptors

        private void registerInterceptors​(org.apache.http.impl.client.DefaultHttpClient httpclient)