Methods Summary |
---|
public javax.enterprise.deploy.spi.DeploymentManager | getDeploymentManager(java.lang.String uri, java.lang.String userName, java.lang.String password)Get a connected deployment manager
log.debug("getDeploymentManager (uri=" + uri + ")");
DeploymentManager mgr = null;
try
{
URI deployURI = parseURI(uri);
mgr = new DeploymentManagerImpl(deployURI, true, userName, password);
}
catch (URISyntaxException e)
{
DeploymentManagerCreationException ex = new DeploymentManagerCreationException("Failed to create DeploymentManagerImpl");
ex.initCause(e);
throw ex;
}
return mgr;
|
public javax.enterprise.deploy.spi.DeploymentManager | getDisconnectedDeploymentManager(java.lang.String uri)Get a disconnected version of the deployment manager
log.debug("getDisconnectedDeploymentManager (uri=" + uri + ")");
DeploymentManager mgr = null;
try
{
URI deployURI = parseURI(uri);
mgr = new DeploymentManagerImpl(deployURI, false);
}
catch (URISyntaxException e)
{
DeploymentManagerCreationException ex = new DeploymentManagerCreationException("Failed to create DeploymentManagerImpl");
ex.initCause(e);
throw ex;
}
return mgr;
|
public java.lang.String | getDisplayName()The name of the JBoss DeploymentFactory.
return DISPLAY_NAME;
|
public java.lang.String | getProductVersion()The version of the deployment manager
return PRODUCT_VERSION;
|
public boolean | handlesURI(java.lang.String uri)Look for jboss-deployer:.... URIs. Returns true if uri is has a
scheme of jboss-deployer, false otherwise.
/* Obtain the display name and version from the Package object for
org.jboss.deploy.spi.factories
*/
Package pkg = Package.getPackage("org.jboss.deploy.spi.factories");
if (pkg != null)
{
DISPLAY_NAME = pkg.getImplementationVendor();
PRODUCT_VERSION = pkg.getImplementationVersion();
}
if (DISPLAY_NAME == null || PRODUCT_VERSION == null)
{
DISPLAY_NAME = "DeploymentFactoryImpl";
PRODUCT_VERSION = "1.1-DEV";
}
// Register this deployment factory with the manager
DeploymentFactoryManager manager = DeploymentFactoryManager.getInstance();
manager.registerDeploymentFactory(new DeploymentFactoryImpl());
boolean handlesURI = DeploymentManagerImpl.DEPLOYER_URI.equals(uri);
if (handlesURI == false)
{
try
{
URI deployURI = parseURI(uri);
handlesURI = "jnp".equals(deployURI.getScheme());
}
catch (URISyntaxException e)
{
log.warn("Failed to parse uri: " + uri, e);
}
}
log.debug("handlesURI [" + uri + "]: " + handlesURI);
return handlesURI;
|
private java.net.URI | parseURI(java.lang.String uri)
URI deployURI = new URI(uri);
return deployURI;
|