org.jboss.jca.deployers.fungal

## Class DsXmlDeployer

- java.lang.Object
- - org.jboss.jca.deployers.common.AbstractDsDeployer
  - - org.jboss.jca.deployers.fungal.DsXmlDeployer

- All Implemented Interfaces:
    com.github.fungal.spi.deployers.Deployer

      public class DsXmlDeployer
      extends org.jboss.jca.deployers.common.AbstractDsDeployer
      implements com.github.fungal.spi.deployers.Deployer

  The -ds.xml deployer for JCA/SJC
  Author:
    Jesper Pedersen

- - ### Field Summary

    - ### Fields inherited from class org.jboss.jca.deployers.common.AbstractDsDeployer

      `transactionIntegration, xaResourceRecoveryRegistry`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `DsXmlDeployer()` Constructor

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `accepts(java.net.URL url)`
    `protected java.lang.String[]` | `bindConnectionFactory(java.lang.String deployment, java.lang.String jndi, java.lang.Object cf)` Bind connection factory into JNDI
    `protected void` | `cleanTemporaryFiles(java.net.URL url)` Clean all potential temporary files
    `protected javax.resource.spi.ManagedConnectionFactory` | `createMcf(org.jboss.jca.common.api.metadata.ds.DataSource ds, java.lang.String uniqueId, java.lang.ClassLoader cl)` Create Mcf for ds
    `protected javax.resource.spi.ManagedConnectionFactory` | `createMcf(org.jboss.jca.common.api.metadata.ds.XaDataSource ds, java.lang.String uniqueId, java.lang.ClassLoader cl)` Create Mcf for xads
    `protected javax.resource.spi.ResourceAdapter` | `createRa(java.lang.String uniqueId, java.lang.ClassLoader cl)` Create Ra
    `com.github.fungal.spi.deployers.Deployment` | `deploy(java.net.URL url, com.github.fungal.spi.deployers.Context context, java.lang.ClassLoader parent)`
    `protected java.lang.ClassLoader` | `getDeploymentClassLoader(java.lang.String uniqueId)` Provide the classloader of the deployment identified by the unique id
    `protected java.lang.String` | `getDriver(java.lang.String driverName, java.lang.String moduleId)` Get the driver
    `protected java.io.File` | `getFileFromUrl(java.net.URL url)` Get File object of URL who locate xml resource
    `protected java.lang.String` | `getIronJacamarHome()` Get IronJacamar Home directory
    `java.lang.String` | `getJDBCLocal()` Get the name for the JDBC Local resource adapter
    `java.lang.String` | `getJDBCXA()` Get the name for the JDBC Xa resource adapter
    `protected org.jboss.jca.deployers.DeployersLogger` | `getLogger()` Get the logger
    `org.jboss.jca.core.spi.mdr.MetadataRepository` | `getMetadataRepository()` Get the metadata repository
    `int` | `getOrder()`
    `org.jboss.jca.core.spi.rar.ResourceAdapterRepository` | `getResourceAdapterRepository()` Get the resource adapter repository
    `protected org.jboss.jca.core.spi.security.SubjectFactory` | `getSubjectFactory(org.jboss.jca.common.api.metadata.common.Credential credential, java.lang.String jndiName)` Get a subject factory
    `java.lang.Object` | `initAndInject(java.lang.String className, java.util.List<? extends org.jboss.jca.common.api.metadata.spec.ConfigProperty> configs, java.lang.ClassLoader cl)` Initialize and inject configuration properties
    `protected java.lang.String` | `registerResourceAdapterToResourceAdapterRepository(javax.resource.spi.ResourceAdapter instance)` Register the ResourceAdapter to the ResourceAdapterRepository.
    `void` | `setDriverRegistry(DriverRegistry value)` Set the driver registry
    `void` | `setJDBCLocal(java.lang.String value)` Set the name for the JDBC Local resource adapter
    `void` | `setJDBCXA(java.lang.String value)` Set the name for the JDBC XA resource adapter
    `void` | `setMetadataRepository(org.jboss.jca.core.spi.mdr.MetadataRepository value)` Set the metadata repository
    `void` | `setResourceAdapterRepository(org.jboss.jca.core.spi.rar.ResourceAdapterRepository value)` Set the resource adapter repository
    `void` | `start()` Start

    - ### Methods inherited from class org.jboss.jca.deployers.common.AbstractDsDeployer

      `associateResourceAdapter, buildJndiName, createObjectsAndInjectValue, createSubject, getCachedConnectionManager, getManagementRepository, getTransactionIntegration, getXAResourceRecoveryRegistry, initAndInjectClassLoaderPlugin, needsBootstrapContext, numberOfDataSources, setCachedConnectionManager, setManagementRepository, setTransactionIntegration, setXAResourceRecoveryRegistry, startContext, verifyTypes`

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

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

- - ### Constructor Detail

    - #### DsXmlDeployer

          public DsXmlDeployer()

      Constructor

  - ### Method Detail

    - #### setJDBCLocal

          public void setJDBCLocal(java.lang.String value)

      Set the name for the JDBC Local resource adapter
      Parameters:
        `value` - The value

    - #### getJDBCLocal

          public java.lang.String getJDBCLocal()

      Get the name for the JDBC Local resource adapter
      Returns:
        The value

    - #### setJDBCXA

          public void setJDBCXA(java.lang.String value)

      Set the name for the JDBC XA resource adapter
      Parameters:
        `value` - The value

    - #### getJDBCXA

          public java.lang.String getJDBCXA()

      Get the name for the JDBC Xa resource adapter
      Returns:
        The value

    - #### getLogger

          protected org.jboss.jca.deployers.DeployersLogger getLogger()

      Get the logger
      Specified by:
        `getLogger` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Returns:
        The value

    - #### setDriverRegistry

          public void setDriverRegistry(DriverRegistry value)

      Set the driver registry
      Parameters:
        `value` - The value

    - #### accepts

          public boolean accepts(java.net.URL url)

      Specified by:
        `accepts` in interface `com.github.fungal.spi.deployers.Deployer`

    - #### getOrder

          public int getOrder()

      Specified by:
        `getOrder` in interface `com.github.fungal.spi.deployers.Deployer`

    - #### deploy

          public com.github.fungal.spi.deployers.Deployment deploy(java.net.URL url,
                                                                   com.github.fungal.spi.deployers.Context context,
                                                                   java.lang.ClassLoader parent)
                                                            throws com.github.fungal.spi.deployers.DeployException

      Specified by:
        `deploy` in interface `com.github.fungal.spi.deployers.Deployer`
      Throws:
        `com.github.fungal.spi.deployers.DeployException`

    - #### getFileFromUrl

          protected java.io.File getFileFromUrl(java.net.URL url)
                                         throws java.net.URISyntaxException,
                                                java.io.IOException

      Get File object of URL who locate xml resource
      Parameters:
        `url` - url of the archive
      Returns:
        a File object pointing of xml resource
      Throws:
        `java.net.URISyntaxException` - Thrown if the resource adapter cant be found
        `java.io.IOException` - Thrown if the resource adapter cant be accessible

    - #### getIronJacamarHome

          protected java.lang.String getIronJacamarHome()

      Get IronJacamar Home directory
      Returns:
        a String object

    - #### cleanTemporaryFiles

          protected void cleanTemporaryFiles(java.net.URL url)
                                      throws com.github.fungal.spi.deployers.DeployException

      Clean all potential temporary files
      Parameters:
        `url` - url of the archive
      Throws:
        `com.github.fungal.spi.deployers.DeployException` - Thrown if the resource cant be cleaned

    - #### initAndInject

          public java.lang.Object initAndInject(java.lang.String className,
                                                java.util.List<? extends org.jboss.jca.common.api.metadata.spec.ConfigProperty> configs,
                                                java.lang.ClassLoader cl)
                                         throws org.jboss.jca.deployers.common.DeployException

      Initialize and inject configuration properties
      Specified by:
        `initAndInject` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `className` - The fully qualified class name
        `configs` - The configuration properties
        `cl` - The class loader
      Returns:
        The object
      Throws:
        `org.jboss.jca.deployers.common.DeployException` - Thrown if the object cant be initialized

    - #### bindConnectionFactory

          protected java.lang.String[] bindConnectionFactory(java.lang.String deployment,
                                                             java.lang.String jndi,
                                                             java.lang.Object cf)
                                                      throws java.lang.Throwable

      Bind connection factory into JNDI
      Specified by:
        `bindConnectionFactory` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `deployment` - The deployment name
        `jndi` - The JNDI name
        `cf` - The connection factory
      Returns:
        The JNDI names bound
      Throws:
        `java.lang.Throwable` - thrown if an error occurs

    - #### getDriver

          protected java.lang.String getDriver(java.lang.String driverName,
                                               java.lang.String moduleId)

      Get the driver
      Overrides:
        `getDriver` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `driverName` - The name of the driver
        `moduleId` - The id of the module
      Returns:
        The driver class name; or `null` if not found

    - #### start

          public void start()

      Start

    - #### getDeploymentClassLoader

          protected java.lang.ClassLoader getDeploymentClassLoader(java.lang.String uniqueId)

      Description copied from class: `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Provide the classloader of the deployment identified by the unique id
      Specified by:
        `getDeploymentClassLoader` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `uniqueId` - The
      Returns:
        The classloader used by this deployment

    - #### getSubjectFactory

          protected org.jboss.jca.core.spi.security.SubjectFactory getSubjectFactory(org.jboss.jca.common.api.metadata.common.Credential credential,
                                                                                     java.lang.String jndiName)
                                                                              throws org.jboss.jca.deployers.common.DeployException

      Description copied from class: `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Get a subject factory
      Specified by:
        `getSubjectFactory` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `credential` - The security credential
        `jndiName` - optionally used for authentication context matching
      Returns:
        The subject factory; must return `null` if credential security isn't enabled or if credential is `null`
      Throws:
        `org.jboss.jca.deployers.common.DeployException` - Thrown if the security info can't be resolved

    - #### createRa

          protected javax.resource.spi.ResourceAdapter createRa(java.lang.String uniqueId,
                                                                java.lang.ClassLoader cl)
                                                         throws org.jboss.jca.core.spi.mdr.NotFoundException,
                                                                java.lang.Exception,
                                                                com.github.fungal.spi.deployers.DeployException

      Description copied from class: `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Create Ra
      Specified by:
        `createRa` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `uniqueId` - the uniqueId
        `cl` - the classloader
      Returns:
        the resource adapter
      Throws:
        `org.jboss.jca.core.spi.mdr.NotFoundException` - in case it's not found in cl
        `java.lang.Exception` - in case of other error
        `org.jboss.jca.deployers.common.DeployException` - in case of deploy error
        `com.github.fungal.spi.deployers.DeployException`

    - #### registerResourceAdapterToResourceAdapterRepository

          protected java.lang.String registerResourceAdapterToResourceAdapterRepository(javax.resource.spi.ResourceAdapter instance)

      Description copied from class: `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Register the ResourceAdapter to the ResourceAdapterRepository. Implementer should provide the implementation to get repository and do the registration
      Specified by:
        `registerResourceAdapterToResourceAdapterRepository` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `instance` - the instance
      Returns:
        The key

    - #### createMcf

          protected javax.resource.spi.ManagedConnectionFactory createMcf(org.jboss.jca.common.api.metadata.ds.XaDataSource ds,
                                                                          java.lang.String uniqueId,
                                                                          java.lang.ClassLoader cl)
                                                                   throws org.jboss.jca.core.spi.mdr.NotFoundException,
                                                                          java.lang.Exception,
                                                                          com.github.fungal.spi.deployers.DeployException

      Description copied from class: `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Create Mcf for xads
      Specified by:
        `createMcf` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `ds` - the xsds
        `uniqueId` - the uniqueId
        `cl` - the classloader
      Returns:
        the mcf
      Throws:
        `org.jboss.jca.core.spi.mdr.NotFoundException` - in case it's not found in cl
        `java.lang.Exception` - in case of other errro
        `org.jboss.jca.deployers.common.DeployException` - in case of deoloy error
        `com.github.fungal.spi.deployers.DeployException`

    - #### createMcf

          protected javax.resource.spi.ManagedConnectionFactory createMcf(org.jboss.jca.common.api.metadata.ds.DataSource ds,
                                                                          java.lang.String uniqueId,
                                                                          java.lang.ClassLoader cl)
                                                                   throws org.jboss.jca.core.spi.mdr.NotFoundException,
                                                                          java.lang.Exception,
                                                                          com.github.fungal.spi.deployers.DeployException

      Description copied from class: `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Create Mcf for ds
      Specified by:
        `createMcf` in class `org.jboss.jca.deployers.common.AbstractDsDeployer`
      Parameters:
        `ds` - the xsds
        `uniqueId` - the uniqueId
        `cl` - the classloader
      Returns:
        the mcf
      Throws:
        `org.jboss.jca.core.spi.mdr.NotFoundException` - in case it's not found in cl
        `java.lang.Exception` - in case of other errro
        `org.jboss.jca.deployers.common.DeployException` - in case of deoloy error
        `com.github.fungal.spi.deployers.DeployException`

    - #### setMetadataRepository

          public void setMetadataRepository(org.jboss.jca.core.spi.mdr.MetadataRepository value)

      Set the metadata repository
      Parameters:
        `value` - The value

    - #### getMetadataRepository

          public org.jboss.jca.core.spi.mdr.MetadataRepository getMetadataRepository()

      Get the metadata repository
      Returns:
        The handle

    - #### setResourceAdapterRepository

          public void setResourceAdapterRepository(org.jboss.jca.core.spi.rar.ResourceAdapterRepository value)

      Set the resource adapter repository
      Parameters:
        `value` - The value

    - #### getResourceAdapterRepository

          public org.jboss.jca.core.spi.rar.ResourceAdapterRepository getResourceAdapterRepository()

      Get the resource adapter repository
      Returns:
        The handle

Copyright © 2014 IronJacamar (http://www.ironjacamar.org)