tigase.db

## Class RepositoryFactory

- java.lang.Object
- - tigase.db.RepositoryFactory

-     public abstract class RepositoryFactory
      extends Object

  Describe class RepositoryFactory here. Created: Tue Oct 24 22:13:52 2006
  Version:
    $Rev$
  Author:
    Artur Hefczyc

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `RepositoryFactory.RepositoryFactoryStatisticsContainer`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `AUTH_DOMAIN_POOL_CLASS` Field description
    `static String` | `AUTH_DOMAIN_POOL_CLASS_PROP_KEY` Field description
    `static String` | `AUTH_DOMAIN_POOL_CLASS_PROP_VAL` Field description
    `static String` | `AUTH_REPO_CLASS_PROP_KEY` Field description
    `static String` | `AUTH_REPO_CLASS_PROP_VAL` Deprecated.
    `static String` | `AUTH_REPO_DOMAINS_PROP_KEY` Field description
    `static String` | `AUTH_REPO_PARAMS_NODE` Field description
    `static String` | `AUTH_REPO_POOL_CLASS` Field description
    `static String` | `AUTH_REPO_POOL_CLASS_PROP_DEF` Field description
    `static String` | `AUTH_REPO_POOL_CLASS_PROP_KEY` Field description
    `static String` | `AUTH_REPO_POOL_CLASS_PROP_VAL` Field description
    `static String` | `AUTH_REPO_POOL_SIZE` Field description
    `static String` | `AUTH_REPO_POOL_SIZE_PROP_KEY` Field description
    `static int` | `AUTH_REPO_POOL_SIZE_PROP_VAL` Field description
    `static String` | `AUTH_REPO_URL_PROP_KEY` Field description
    `static String` | `DATA_REPO_CLASS_PROP_KEY` Field description
    `static String` | `DATA_REPO_CLASS_PROP_VAL` Deprecated.
    `static String` | `DATA_REPO_POOL_CLASS_PROP_KEY` Field description
    `static String` | `DATA_REPO_POOL_CLASS_PROP_VAL` Field description
    `static String` | `DATA_REPO_POOL_SIZE` Field description
    `static String` | `DATA_REPO_POOL_SIZE_PROP_KEY` Field description
    `static int` | `DATA_REPO_POOL_SIZE_PROP_VAL` Field description
    `static String` | `DATABASE_TYPE_PROP_KEY` Field description
    `static String` | `DERBY_REPO_CLASS_PROP_VAL` Field description
    `static String` | `DERBY_REPO_URL_PROP_VAL` Field description
    `static String` | `DRUPAL_REPO_URL_PROP_VAL` Field description
    `static String` | `DRUPALWP_REPO_CLASS_PROP_VAL` Field description
    `static String` | `DUMMY_REPO_CLASS_PROP_VAL` Field description
    `static String` | `GEN_AUTH_DB` Field description
    `static String` | `GEN_AUTH_DB_URI` Field description
    `static String` | `GEN_USER_DB`
    `static String` | `GEN_USER_DB_PROP_KEY` Field description
    `static String` | `GEN_USER_DB_URI`
    `static String` | `GEN_USER_DB_URI_PROP_KEY` Field description
    `static String` | `LIBRESOURCE_REPO_CLASS_PROP_VAL` Field description
    `static String` | `LIBRESOURCE_REPO_URL_PROP_VAL` Field description
    `static String` | `MYSQL_REPO_CLASS_PROP_VAL` Field description
    `static String` | `MYSQL_REPO_URL_PROP_VAL` Field description
    `static String` | `PGSQL_REPO_CLASS_PROP_VAL` Field description
    `static String` | `PGSQL_REPO_URL_PROP_VAL` Field description
    `static int` | `REPO_POOL_SIZE_FACTOR_PROP_VAL`
    `static String` | `SHARED_AUTH_REPO_PARAMS_PROP_KEY` Field description
    `static String` | `SHARED_AUTH_REPO_PROP_KEY` Field description
    `static String` | `SHARED_USER_REPO_PARAMS_PROP_KEY` Field description
    `static String` | `SHARED_USER_REPO_PROP_KEY` Field description
    `static String` | `SQLSERVER_REPO_CLASS_PROP_VAL` Default MS SQL Server JDBC class
    `static String` | `SQLSERVER_REPO_URL_PROP_VAL` Default MS SQL Server JDBC connection string
    `static StatisticsContainerIfc` | `statistics`
    `static String` | `TIGASE_AUTH_REPO_CLASS_PROP_VAL` Field description
    `static String` | `TIGASE_AUTH_REPO_URL_PROP_VAL` Field description
    `static String` | `TIGASE_CUSTOM_AUTH_REPO_CLASS_PROP_VAL` Field description
    `static String` | `USER_DOMAIN_POOL_CLASS` Field description
    `static String` | `USER_DOMAIN_POOL_CLASS_PROP_KEY` Field description
    `static String` | `USER_DOMAIN_POOL_CLASS_PROP_VAL` Field description
    `static String` | `USER_REPO_CLASS_PROP_KEY` Field description
    `static String` | `USER_REPO_CLASS_PROP_VAL` Deprecated.
    `static String` | `USER_REPO_DOMAINS_PROP_KEY` Field description
    `static String` | `USER_REPO_PARAMS_NODE` Field description
    `static String` | `USER_REPO_POOL_CLASS` Field description
    `static String` | `USER_REPO_POOL_CLASS_PROP_DEF` Field description
    `static String` | `USER_REPO_POOL_CLASS_PROP_KEY` Field description
    `static String` | `USER_REPO_POOL_CLASS_PROP_VAL` Field description
    `static String` | `USER_REPO_POOL_SIZE` Field description
    `static String` | `USER_REPO_POOL_SIZE_PROP_KEY` Field description
    `static int` | `USER_REPO_POOL_SIZE_PROP_VAL` Field description
    `static String` | `USER_REPO_URL_PROP_KEY` Field description
    `static String` | `XML_REPO_CLASS_PROP_VAL` Field description
    `static String` | `XML_REPO_URL_PROP_VAL` Field description

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `RepositoryFactory()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static AuthRepository` | `getAuthRepository(String class_name, String resource, Map<String,String> params)` Method description
    `static DataRepository` | `getDataRepository(String class_name, String resource, Map<String,String> params)` Method description
    `static String` | `getRepoClass(String repo_name)`
    `static <T extends Class<? extends Repository>> T` | `getRepoClass(T cls, String uri)` Method returns class which would be by default used as implementation of class
    `static String` | `getRepoClassName(Class cls, String uri)` Returns name of class which would be used as repository implementation
    `static UserRepository` | `getUserRepository(String class_name, String resource, Map<String,String> params)` Method description
    `static void` | `initialize(Collection<Class<Repository>> classes)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### AUTH_DOMAIN_POOL_CLASS

          public static final String AUTH_DOMAIN_POOL_CLASS

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_DOMAIN_POOL_CLASS_PROP_KEY

          public static final String AUTH_DOMAIN_POOL_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_DOMAIN_POOL_CLASS_PROP_VAL

          public static final String AUTH_DOMAIN_POOL_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_CLASS_PROP_KEY

          public static final String AUTH_REPO_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_CLASS_PROP_VAL

          @Deprecated
          public static final String AUTH_REPO_CLASS_PROP_VAL

      Deprecated.
      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_DOMAINS_PROP_KEY

          public static final String AUTH_REPO_DOMAINS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_PARAMS_NODE

          public static final String AUTH_REPO_PARAMS_NODE

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_POOL_CLASS

          public static final String AUTH_REPO_POOL_CLASS

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_POOL_CLASS_PROP_DEF

          public static final String AUTH_REPO_POOL_CLASS_PROP_DEF

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_POOL_CLASS_PROP_KEY

          public static final String AUTH_REPO_POOL_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_POOL_CLASS_PROP_VAL

          public static final String AUTH_REPO_POOL_CLASS_PROP_VAL

      Field description

    - #### AUTH_REPO_POOL_SIZE

          public static final String AUTH_REPO_POOL_SIZE

      Field description
      See Also:
        Constant Field Values

    - #### AUTH_REPO_POOL_SIZE_PROP_KEY

          public static final String AUTH_REPO_POOL_SIZE_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### REPO_POOL_SIZE_FACTOR_PROP_VAL

          public static final int REPO_POOL_SIZE_FACTOR_PROP_VAL

      See Also:
        Constant Field Values

    - #### AUTH_REPO_POOL_SIZE_PROP_VAL

          public static final int AUTH_REPO_POOL_SIZE_PROP_VAL

      Field description

    - #### AUTH_REPO_URL_PROP_KEY

          public static final String AUTH_REPO_URL_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_CLASS_PROP_KEY

          public static final String DATA_REPO_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_CLASS_PROP_VAL

          @Deprecated
          public static final String DATA_REPO_CLASS_PROP_VAL

      Deprecated.
      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_POOL_CLASS_PROP_KEY

          public static final String DATA_REPO_POOL_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_POOL_CLASS_PROP_VAL

          public static final String DATA_REPO_POOL_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_POOL_SIZE

          public static final String DATA_REPO_POOL_SIZE

      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_POOL_SIZE_PROP_KEY

          public static final String DATA_REPO_POOL_SIZE_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### DATA_REPO_POOL_SIZE_PROP_VAL

          public static final int DATA_REPO_POOL_SIZE_PROP_VAL

      Field description

    - #### DERBY_REPO_CLASS_PROP_VAL

          public static final String DERBY_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### DERBY_REPO_URL_PROP_VAL

          public static final String DERBY_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### DRUPAL_REPO_URL_PROP_VAL

          public static final String DRUPAL_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### DRUPALWP_REPO_CLASS_PROP_VAL

          public static final String DRUPALWP_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### DUMMY_REPO_CLASS_PROP_VAL

          public static final String DUMMY_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### GEN_AUTH_DB

          public static final String GEN_AUTH_DB

      Field description
      See Also:
        Constant Field Values

    - #### GEN_AUTH_DB_URI

          public static final String GEN_AUTH_DB_URI

      Field description
      See Also:
        Constant Field Values

    - #### GEN_USER_DB_PROP_KEY

          public static final String GEN_USER_DB_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### GEN_USER_DB

          public static final String GEN_USER_DB

      See Also:
        Constant Field Values

    - #### GEN_USER_DB_URI_PROP_KEY

          public static final String GEN_USER_DB_URI_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### GEN_USER_DB_URI

          public static final String GEN_USER_DB_URI

      See Also:
        Constant Field Values

    - #### LIBRESOURCE_REPO_CLASS_PROP_VAL

          public static final String LIBRESOURCE_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### LIBRESOURCE_REPO_URL_PROP_VAL

          public static final String LIBRESOURCE_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### SQLSERVER_REPO_CLASS_PROP_VAL

          public static final String SQLSERVER_REPO_CLASS_PROP_VAL

      Default MS SQL Server JDBC class
      See Also:
        Constant Field Values

    - #### SQLSERVER_REPO_URL_PROP_VAL

          public static final String SQLSERVER_REPO_URL_PROP_VAL

      Default MS SQL Server JDBC connection string
      See Also:
        Constant Field Values

    - #### MYSQL_REPO_CLASS_PROP_VAL

          public static final String MYSQL_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### MYSQL_REPO_URL_PROP_VAL

          public static final String MYSQL_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### PGSQL_REPO_CLASS_PROP_VAL

          public static final String PGSQL_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### PGSQL_REPO_URL_PROP_VAL

          public static final String PGSQL_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### SHARED_AUTH_REPO_PARAMS_PROP_KEY

          public static final String SHARED_AUTH_REPO_PARAMS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### SHARED_AUTH_REPO_PROP_KEY

          public static final String SHARED_AUTH_REPO_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### SHARED_USER_REPO_PARAMS_PROP_KEY

          public static final String SHARED_USER_REPO_PARAMS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### SHARED_USER_REPO_PROP_KEY

          public static final String SHARED_USER_REPO_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### TIGASE_AUTH_REPO_CLASS_PROP_VAL

          public static final String TIGASE_AUTH_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### TIGASE_AUTH_REPO_URL_PROP_VAL

          public static final String TIGASE_AUTH_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### TIGASE_CUSTOM_AUTH_REPO_CLASS_PROP_VAL

          public static final String TIGASE_CUSTOM_AUTH_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### USER_DOMAIN_POOL_CLASS

          public static final String USER_DOMAIN_POOL_CLASS

      Field description
      See Also:
        Constant Field Values

    - #### USER_DOMAIN_POOL_CLASS_PROP_KEY

          public static final String USER_DOMAIN_POOL_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### USER_DOMAIN_POOL_CLASS_PROP_VAL

          public static final String USER_DOMAIN_POOL_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_CLASS_PROP_KEY

          public static final String USER_REPO_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_CLASS_PROP_VAL

          @Deprecated
          public static final String USER_REPO_CLASS_PROP_VAL

      Deprecated.
      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_DOMAINS_PROP_KEY

          public static final String USER_REPO_DOMAINS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_PARAMS_NODE

          public static final String USER_REPO_PARAMS_NODE

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_POOL_CLASS

          public static final String USER_REPO_POOL_CLASS

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_POOL_CLASS_PROP_DEF

          public static final String USER_REPO_POOL_CLASS_PROP_DEF

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_POOL_CLASS_PROP_KEY

          public static final String USER_REPO_POOL_CLASS_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_POOL_CLASS_PROP_VAL

          public static final String USER_REPO_POOL_CLASS_PROP_VAL

      Field description

    - #### USER_REPO_POOL_SIZE

          public static final String USER_REPO_POOL_SIZE

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_POOL_SIZE_PROP_KEY

          public static final String USER_REPO_POOL_SIZE_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### USER_REPO_POOL_SIZE_PROP_VAL

          public static final int USER_REPO_POOL_SIZE_PROP_VAL

      Field description

    - #### USER_REPO_URL_PROP_KEY

          public static final String USER_REPO_URL_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### XML_REPO_CLASS_PROP_VAL

          public static final String XML_REPO_CLASS_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### XML_REPO_URL_PROP_VAL

          public static final String XML_REPO_URL_PROP_VAL

      Field description
      See Also:
        Constant Field Values

    - #### DATABASE_TYPE_PROP_KEY

          public static final String DATABASE_TYPE_PROP_KEY

      Field description
      See Also:
        Constant Field Values

    - #### statistics

          public static final StatisticsContainerIfc statistics

  - ### Constructor Detail

    - #### RepositoryFactory

          public RepositoryFactory()

  - ### Method Detail

    - #### initialize

          public static void initialize(Collection<Class<Repository>> classes)

    - #### getAuthRepository

          public static AuthRepository getAuthRepository(String class_name,
                                                         String resource,
                                                         Map<String,String> params)
                                                  throws ClassNotFoundException,
                                                         InstantiationException,
                                                         IllegalAccessException,
                                                         DBInitException

      Method description
      Parameters:
        `class_name` -
        `resource` -
        `params` -
      Throws:
        `ClassNotFoundException`
        `DBInitException`
        `IllegalAccessException`
        `InstantiationException`

    - #### getDataRepository

          public static DataRepository getDataRepository(String class_name,
                                                         String resource,
                                                         Map<String,String> params)
                                                  throws ClassNotFoundException,
                                                         InstantiationException,
                                                         IllegalAccessException,
                                                         DBInitException,
                                                         SQLException

      Method description
      Parameters:
        `class_name` -
        `resource` -
        `params` -
      Throws:
        `ClassNotFoundException`
        `DBInitException`
        `IllegalAccessException`
        `InstantiationException`
        `SQLException`

    - #### getRepoClass

          public static <T extends Class<? extends Repository>> T getRepoClass(T cls,
                                                                               String uri)
                                                                        throws DBInitException

      Method returns class which would be by default used as implementation of class
      Parameters:
        `cls` -
        `uri` -
      Returns:
      Throws:
        `DBInitException`

    - #### getRepoClassName

          public static String getRepoClassName(Class cls,
                                                String uri)
                                         throws DBInitException

      Returns name of class which would be used as repository implementation
      Parameters:
        `cls` - - interface class needs to implement
        `uri` - - uri which needs to be supported by implementation
      Returns:
      Throws:
        `DBInitException`

    - #### getRepoClass

          public static String getRepoClass(String repo_name)

    - #### getUserRepository

          public static UserRepository getUserRepository(String class_name,
                                                         String resource,
                                                         Map<String,String> params)
                                                  throws ClassNotFoundException,
                                                         InstantiationException,
                                                         IllegalAccessException,
                                                         DBInitException

      Method description
      Parameters:
        `class_name` -
        `resource` -
        `params` -
      Throws:
        `ClassNotFoundException`
        `DBInitException`
        `IllegalAccessException`
        `InstantiationException`

Copyright © 2022 "Tigase, Inc.". All rights reserved.