org.ow2.easybeans.mavenplugin
Class EasyBeansServerFactory

java.lang.Object
  extended by org.ow2.easybeans.mavenplugin.EasyBeansServerFactory

public final class EasyBeansServerFactory
extends Object

Provide an access to local or remote instance of EasyBeans.

Author:
Vincent Michaud

Method Summary
static org.ow2.util.maven.plugin.deployment.api.IPluginServer getLaunchedServer(String configXmlFile, List<String> partialConfigXmlFiles, String hostname, int stopPort, boolean supportAllPersistenceManager, org.ow2.util.maven.plugin.deployment.maven.MavenArtifactResolver resolver)
          Get an instance of launched EasyBeans server.
static org.ow2.util.maven.plugin.deployment.api.IPluginServer getLocalLaunchedServer(String configXmlFile, List<String> partialConfigXmlFiles, boolean supportAllPersistenceManager, org.ow2.util.maven.plugin.deployment.maven.MavenArtifactResolver resolver)
          Create and launch a local EasyBeans server instance with specified XML core and configuration files.
static org.ow2.util.maven.plugin.deployment.api.IPluginServer getRemoteLaunchedServer(String hostname, int stopPort)
          Get an instance of launched remote EasyBeans server.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLocalLaunchedServer

public static org.ow2.util.maven.plugin.deployment.api.IPluginServer getLocalLaunchedServer(String configXmlFile,
                                                                                            List<String> partialConfigXmlFiles,
                                                                                            boolean supportAllPersistenceManager,
                                                                                            org.ow2.util.maven.plugin.deployment.maven.MavenArtifactResolver resolver)
                                                                                     throws org.apache.maven.plugin.MojoExecutionException
Create and launch a local EasyBeans server instance with specified XML core and configuration files.

Parameters:
configXmlFile - Path of EasyBeans XML configuration file
partialConfigXmlFiles - Path list of partial EasyBeans XML configuration file.
supportAllPersistenceManager - Determine if all supported persistence providers dependencies are automatically added to the plugin classloader at the server launch.
resolver - An artifact resolver
Returns:
Instance of local and launched EasyBeans server
Throws:
org.apache.maven.plugin.MojoExecutionException - Execution error

getRemoteLaunchedServer

public static org.ow2.util.maven.plugin.deployment.api.IPluginServer getRemoteLaunchedServer(String hostname,
                                                                                             int stopPort)
                                                                                      throws org.apache.maven.plugin.MojoExecutionException
Get an instance of launched remote EasyBeans server.

Parameters:
hostname - Domaine name used to contact EasyBeans.
stopPort - Port number used to contact EasyBeans.
Returns:
An instance of launched remote EasyBeans server, or null is nothing is found
Throws:
org.apache.maven.plugin.MojoExecutionException

getLaunchedServer

public static org.ow2.util.maven.plugin.deployment.api.IPluginServer getLaunchedServer(String configXmlFile,
                                                                                       List<String> partialConfigXmlFiles,
                                                                                       String hostname,
                                                                                       int stopPort,
                                                                                       boolean supportAllPersistenceManager,
                                                                                       org.ow2.util.maven.plugin.deployment.maven.MavenArtifactResolver resolver)
                                                                                throws org.apache.maven.plugin.MojoExecutionException
Get an instance of launched EasyBeans server.

Parameters:
configXmlFile - Path of EasyBeans XML configuration file
partialConfigXmlFiles - Path list of partial EasyBeans XML configuration file.
hostname - Domaine name used to contact EasyBeans
stopPort - Port number used to contact EasyBeans
Returns:
An instance of launched EasyBeans server
Throws:
org.apache.maven.plugin.MojoExecutionException - Execution error


Copyright © 2006-2011 OW2 Consortium. All Rights Reserved.