org.modeshape.jdbc.delegate

## Class RepositoryDelegateFactory

- java.lang.Object
- - org.modeshape.jdbc.delegate.RepositoryDelegateFactory

-     public class RepositoryDelegateFactory
      extends Object

  The RepositoryDelegateFactory is used to create the required type of `RepositoryDelegate` based upon the url provided. The url must be prefixed by .

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static int` | `PROTOCOL_JNDI`
    `protected static int` | `PROTOCOL_UNKNOWN`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `RepositoryDelegateFactory()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `acceptUrl(String url)` Determine if this factory accepts the supplied URL.
    `protected RepositoryDelegate` | `create(int protocol, String url, Properties info, LocalJcrDriver.JcrContextFactory contextFactory)`
    `RepositoryDelegate` | `createRepositoryDelegate(String url, Properties info, LocalJcrDriver.JcrContextFactory contextFactory)` Create a RepositoryDelegate instance, given the connection information.
    `protected int` | `determineProtocol(String url)`

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

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

- - ### Field Detail

    - #### PROTOCOL_UNKNOWN

          protected static final int PROTOCOL_UNKNOWN

      See Also:
        Constant Field Values

    - #### PROTOCOL_JNDI

          protected static final int PROTOCOL_JNDI

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### RepositoryDelegateFactory

          protected RepositoryDelegateFactory()

  - ### Method Detail

    - #### createRepositoryDelegate

          public RepositoryDelegate createRepositoryDelegate(String url,
                                                    Properties info,
                                                    LocalJcrDriver.JcrContextFactory contextFactory)
                                                      throws SQLException

      Create a RepositoryDelegate instance, given the connection information.
      Parameters:
        `url` - the JDBC URL; may be null
        `info` - the connection properties
        `contextFactory` - the factory for a JCR context; may not be null
      Returns:
        the RepositoryDelegate for the supplied connection information
      Throws:
        `SQLException` - if the URL is unknown

    - #### acceptUrl

          public boolean acceptUrl(String url)

      Determine if this factory accepts the supplied URL.
      Parameters:
        `url` - the connection URL
      Returns:
        true if this factory accepts the supplied URL, or false otherwise

    - #### determineProtocol

          protected int determineProtocol(String url)

    - #### create

          protected RepositoryDelegate create(int protocol,
                                  String url,
                                  Properties info,
                                  LocalJcrDriver.JcrContextFactory contextFactory)

Copyright © 2008-2014 JBoss, a division of Red Hat. All Rights Reserved.