org.ow2.jonas.deployment.rar.lib
Class RarDeploymentDescManager

java.lang.Object
  extended by org.ow2.jonas.deployment.common.lib.AbsDeploymentDescManager
      extended by org.ow2.jonas.deployment.rar.lib.RarDeploymentDescManager
All Implemented Interfaces:
DeploymentDescManager

public class RarDeploymentDescManager
extends AbsDeploymentDescManager

Manage Rar deployment descriptors

Author:
Guillaume Sauthier

Field Summary
static String JONAS_RA_FILE_NAME
          Path of the jonas-ra.xml deploymnet descriptor file
static String RA_FILE_NAME
          Path of the ra.xml deploymnet descriptor file
 
Fields inherited from class org.ow2.jonas.deployment.common.lib.AbsDeploymentDescManager
LINK_SEPARATOR
 
Method Summary
static RarDeploymentDesc getInstance(Context ctx)
          Get an instance of an RAR deployment descriptor by parsing the ra.xml and jonas-ra.xml deployment descriptors.
static boolean getParsingWithValidation()
          Controls whether the parser is reporting all validity errors.
static Connector loadConnector(Reader reader, String fileName)
          Load the ra.xml file.
static JonasConnector loadJonasConnector(Reader reader, String fileName)
          Load the jonas-ra.xml file.
static void setParsingWithValidation(boolean validation)
          Controls whether the parser is reporting all validity errors.
 
Methods inherited from class org.ow2.jonas.deployment.common.lib.AbsDeploymentDescManager
containsResource, findJonasServiceRef, mergeWebServiceRef, xmlContent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RA_FILE_NAME

public static final String RA_FILE_NAME
Path of the ra.xml deploymnet descriptor file

See Also:
Constant Field Values

JONAS_RA_FILE_NAME

public static final String JONAS_RA_FILE_NAME
Path of the jonas-ra.xml deploymnet descriptor file

See Also:
Constant Field Values
Method Detail

getInstance

public static RarDeploymentDesc getInstance(Context ctx)
                                     throws DeploymentDescException
Get an instance of an RAR deployment descriptor by parsing the ra.xml and jonas-ra.xml deployment descriptors.

Parameters:
ctx - the context which contains the configuration in order to load the deployment descriptors. There are 6 possible parameters : - rarFileName is the path of the RAR file (required param). - classLoader is the classloader (required param) - altDD is the optional deployment descriptor (optional param).
Returns:
an RAR deployment descriptor by parsing the ra.xml(or altdd) & jonas-ra.xml deployment descriptors.
Throws:
DeploymentDescException - if the deployment descriptors are corrupted.

loadConnector

public static Connector loadConnector(Reader reader,
                                      String fileName)
                               throws DeploymentDescException
Load the ra.xml file.

Parameters:
reader - the Reader of the XML file.
fileName - the name of the file (ra.xml).
Returns:
a connector object.
Throws:
DeploymentDescException - if the deployment descriptor is corrupted.

loadJonasConnector

public static JonasConnector loadJonasConnector(Reader reader,
                                                String fileName)
                                         throws DeploymentDescException
Load the jonas-ra.xml file.

Parameters:
reader - the Reader of the XML file.
fileName - the name of the file (jonas-ra.xml).
Returns:
a JonasConnector object.
Throws:
DeploymentDescException - if the deployment descriptor is corrupted.

getParsingWithValidation

public static boolean getParsingWithValidation()
Controls whether the parser is reporting all validity errors.

Returns:
if true, all external entities will be read.

setParsingWithValidation

public static void setParsingWithValidation(boolean validation)
Controls whether the parser is reporting all validity errors.

Parameters:
validation - if true, all external entities will be read.


Copyright © 2010 OW2 Consortium. All Rights Reserved.