blob: 5bc6be82751b4f0dd4fc85b5b25ab4aaab0b1ccc [file] [log] [blame]
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="../../../../wtp.xsl"?>
<html>
<head>
<meta name="root" content="../../../../../" />
<title>j2ee operations api overview</title>
</head>
<body>
<h1>jst j2ee</h1>
<h2>Overview</h2>
<h3><P>This document describes the J2EE Operations API contributed to M2.
This API will be growing and changing over the subsequent milestone
releases.<br/> For M2, the API allows for for simple project creation,
import, and export for:</P>
</h3>
<p>
<ul>
<li><A href="#EAR">Enterprise Applications</A></li>
<li><A href="#WAR">Web Modules</A></li>
<li><A href="#EJB">EJB Modules</A></li>
<li><A href="#AppClient">Application Client Modules</A></li>
<li><A href="#RAR">Connector Modules</A></li>
</ul>
The WTPOperationDataModel classes mentioned below will likely become API in the future.
Please note, however, that these classes will go through significant changes as they <br/>
are cleaned up for API and modified to handle the upcoming flexible project structure (i.e. feel free to look at them, but do not use them as API).
</p>
<h2><A name="EAR"></A>Enterprise Applications</h2>
<h3><b><FONT SIZE="4">org.eclipse.jst.j2ee.application.operations.EnterpriseApplicationCreationDataModel</FONT></b></h3>
<p>
<pre>
public static void <B>createProject</B>(java.lang.String&#160;projectName,
org.eclipse.core.runtime.IPath&#160;projectLocation,
int&#160;applicationVersion)
</pre>
<DL>
<DD>Creates an Enterprise Application project with the specified
name and version in the specified location.</DD>
<BR/>
<BR/>
<DL>
<DT><B>Parameters:</B></DT>
<DD><CODE>projectName</CODE> - The name of the Enterprise
Application project to create.
</DD>
<DD><CODE>projectLocation</CODE> - Sets the local file system
location for the described project. The path must be either an
absolute file system path, or a relative path whose first segment
is the name of a defined workspace path variable. If <code>null</code>
is specified, the default location is used.
</DD>
<DD><CODE>applicationVersion</CODE> - Sets the J2EE Version for the
descibed project. The version must be one of <code>J2EEVersionConstants.J2EE_1_2_ID</code>,
<code>J2EEVersionConstants.J2EE_1_3_ID</code>, or <code>J2EEVersionConstants.J2EE_1_4_ID</code>.
</DD>
<DT><B>Since:</B></DT>
<DD>WTP 1.0</DD>
</DL>
</DL>
</p>
<hr></hr>
<br/>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.application.operations.EnterpriseApplicationImportDataModel</FONT></b></h4>
<pre>
public static void <B>importArchive</B>(java.lang.String earFileName,
java.lang.String earProjectName)
</pre>
<DL>
<DD>Imports the specified Enterprise Application archive file into
the specified Enterprise Application project.
</DD>
<BR/>
<DL>
<DT><B>Parameters:</B></DT>
<DD><CODE>earFileName</CODE> - The path to the EAR file.
</DD>
<DD><CODE>earProjectName</CODE> - The name of the Enterprise
Application project where the Enterprise Application should be
imported.
</DD>
<DT><B>Since:</B></DT>
<DD>WTP 1.0</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.application.operations.EnterpriseApplicationExportDataModel</FONT></b></h4>
<PRE>
public static void <B>exportProject</B>(java.lang.String earProjectName,
java.lang.String earFileName,
boolean overwriteExisting,
boolean exportSource)
</PRE>
<DL>
<DD>Exports the specified Enterprise Appliction project to the
specified EAR file.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>earProjectName</CODE> - The name of the Enterprise
Application project to export.
</DD>
<DD><CODE>earFileName</CODE> - The fully qualified EAR file
location to export the specified Enterprise Application project.
</DD>
<DD><CODE>overwriteExisting</CODE> - If this is <code>true</code>
then an existing file at the location specified by <code>earFileName</code>
will be overwritten.
</DD>
<DD><CODE>exportSource</CODE> - If this is <code>true</code> then
all source files in the specified Enterprise Application Project
and all its modules will be included in the resulting EAR file.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<h2><A name="WAR"></A>Web Modules</h2>
<h3><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.web.archive.operations.WebModuleCreationDataModel</FONT></b></h3>
<PRE>
public static void <B>createProject</B>(java.lang.String projectName,
org.eclipse.core.runtime.IPath projectLocation,
int webModuleVersion)</PRE>
<DL>
<DD>Creates a Web project with the specified name and version in the
specified location.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>projectName</CODE> - The name of the Web project to
create.
</DD>
<DD><CODE>projectLocation</CODE> - Sets the local file system
location for the described project. The path must be either an
absolute file system path, or a relative path whose first segment
is the name of a defined workspace path variable. If <code>null</code>
is specified, the default location is used.
</DD>
<DD><CODE>webModuleVersion</CODE> - Version for the descibed project. The version must be one of the
following: <code>J2EEVersionConstants.WEB_2_2_ID</code>, <code>J2EEVersionConstants.WEB_2_3_ID</code>,
or <code>J2EEVersionConstants.WEB_2_4_ID</code>.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.web.archive.operations.WebModuleImportDataModel</FONT></b></h4>
<PRE>
public static void <B>importArchive</B>(java.lang.String warFileName,
java.lang.String webProjectName,
boolean addToEar,
java.lang.String earProjectName)</PRE>
<DL>
<DD>Imports the specified WAR file into the specified Web Module
project.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>warFileName</CODE> - The path to the WAR file.
</DD>
<DD><CODE>webProjectName</CODE> - The name of the Web project where
the Web Module should be imported.
</DD>
<DD><CODE>addToEar</CODE> - If this is <code>true</code> then Web
project specified by <code>webProjectName</code> will be added to
the Enterprise Application project specified by <code>earProjectName</code>.
</DD>
<DD><CODE>earProjectName</CODE> - The name of the Enterprise
Application project to add the specified Web project to. This field
is only relevant if <code>addToEar</code> is set to <code>true</code>.
If this is set to <code>null</code> then a default name computed
from the <code>webProjectName</code> will be used.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.web.archive.operations.WebModuleExportDataModel</FONT></b></h4>
<PRE>
public static void <B>exportProject</B>(java.lang.String webProjectName,
java.lang.String warFileName,
boolean overwriteExisting,
boolean exportSource)</PRE>
<DL>
<DD>Exports the specified Web Module project to the specified WAR
file.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>webProjectName</CODE> - The name of the Web Module
project to export.
</DD>
<DD><CODE>warFileName</CODE> - The fully qualified WAR file
location to export the specified Web Module project.
</DD>
<DD><CODE>overwriteExisting</CODE> - If this is <code>true</code>
then an existing file at the location specified by <code>earFileName</code>
will be overwritten.
</DD>
<DD><CODE>exportSource</CODE> - If this is <code>true</code> then
all source files in the specified Web Module will be included in
the resulting WAR file.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<h2><A name="EJB"></A>EJB Modules</h2>
<h3><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.ejb.project.operations.EJBModuleCreationDataModel</FONT></b></h3>
<PRE>
public static void <B>createProject</B>(java.lang.String projectName,
org.eclipse.core.runtime.IPath projectLocation,
int ejbModuleVersion)
</PRE>
<DL>
<DD>Creates an EJB project with the specified name and version in
the specified location.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>projectName</CODE> - The name of the EJB project to
create.
</DD>
<DD><CODE>projectLocation</CODE> - Sets the local file system
location for the described project. The path must be either an
absolute file system path, or a relative path whose first segment
is the name of a defined workspace path variable. If <code>null</code>
is specified, the default location is used.
</DD>
<DD><CODE>ejbModuleVersion</CODE> - Sets the EJB Module Version for
the descibed project. The version must be one of <code>J2EEVersionConstants.EJB_1_1_ID</code>,
<code>J2EEVersionConstants.EJB_2_0_ID</code>, or <code>J2EEVersionConstants.EJB_2_1_ID</code>.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.ejb.project.operations.EJBModuleImportDataModel</FONT></b></h4>
<PRE>
public static void <B>importArchive</B>(java.lang.String ejbJarFileName,
java.lang.String ejbProjectName,
boolean addToEar,
java.lang.String earProjectName)</PRE>
<DL>
<DD>Imports the specified EJB Jar file into the specified EJB Module
project.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>ejbJarFileName</CODE> - The path to the EJB Jar file.
</DD>
<DD><CODE>ejbProjectName</CODE> - The name of the EJB project where
the EJB Module should be imported.
</DD>
<DD><CODE>addToEar</CODE> - If this is <code>true</code> then EJB
project specified by <code>ejbProjectName</code> will be added to
the Enterprise Application project specified by <code>earProjectName</code>.
</DD>
<DD><CODE>earProjectName</CODE> - The name of the Enterprise
Application project to add the specified EJB project to. This field
is only relevant if <code>addToEar</code> is set to <code>true</code>.
If this is set to <code>null</code> then a default name computed
from the <code>ejbProjectName</code> will be used.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.ejb.project.operations.EJBModuleExportDataModel</FONT></b></h4>
<PRE>
public static void <B>exportProject</B>(java.lang.String ejbProjectName,
java.lang.String ejbJarFileName,
boolean overwriteExisting,
boolean exportSource)
</PRE>
<DL>
<DD>Exports the specified EJB Module project to the specified EJB
JAR file.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>ejbProjectName</CODE> - The name of the EJB Module
project to export.
</DD>
<DD><CODE>ejbJarFileName</CODE> - The fully qualified EJB JAR file
location to export the specified EJB Module project.
</DD>
<DD><CODE>overwriteExisting</CODE> - If this is <code>true</code>
then an existing file at the location specified by <code>earFileName</code>
will be overwritten.
</DD>
<DD><CODE>exportSource</CODE> - If this is <code>true</code> then
all source files in the specified EJB Module will be included in
the resulting EJB JAR file.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<h2><A name="AppClient"></A>Application Client Modules</h2>
<h3><b><FONT SIZE="4">org.eclipse.jst.j2ee.applicationclient.creation.AppClientModuleCreationDataModel</FONT></b></h3>
<PRE>
public static void <B>createProject</B>(java.lang.String projectName,
org.eclipse.core.runtime.IPath projectLocation,
int applicationClientVersion)
</PRE>
<DL>
<DD>Creates an Application Client project with the specified name
and version in the specified location.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>projectName</CODE> - The name of the Application Client
project to create.
</DD>
<DD><CODE>projectLocation</CODE> - Sets the local file system
location for the described project. The path must be either an
absolute file system path, or a relative path whose first segment
is the name of a defined workspace path variable. If <code>null</code>
is specified, the default location is used.
</DD>
<DD><CODE>applicationClientVersion</CODE> - Sets the Application
Client Module Version for the descibed project. The version must be
one of <code>J2EEVersionConstants.J2EE_1_2_ID</code>, <code>J2EEVersionConstants.J2EE_1_3_ID</code>,
or <code>J2EEVersionConstants.J2EE_1_4_ID</code>.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.applicationclient.creation.AppClientModuleImportDataModel</FONT></b></h4>
<PRE>
public static void <B>importArchive</B>(java.lang.String appClientJarFileName,
java.lang.String appClientProjectName,
boolean addToEar,
java.lang.String earProjectName)
</PRE>
<DL>
<DD>Imports the specified Application Client Jar file into the
specified Application Client Module project.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>appClientJarFileName</CODE> - The path to the Application
Client Jar file.
</DD>
<DD><CODE>appClientProjectName</CODE> - The name of the Application
Client project where the Application Client Module should be
imported.
</DD>
<DD><CODE>addToEar</CODE> - If this is <code>true</code> then
Application Client project specified by <code>appClientJarFileName</code>
will be added to the Enterprise Application project specified by <code>earProjectName</code>.
</DD>
<DD><CODE>earProjectName</CODE> - The name of the Enterprise
Application project to add the specified Application Client project
to. This field is only relevant if <code>addToEar</code> is set to
<code>true</code>. If this is set to <code>null</code> then a
default name computed from the <code>appClientJarFileName</code>
will be used.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.application.operations.AppClientModuleExportDataModel</FONT></b></h4>
<PRE>
public static void <B>exportProject</B>(java.lang.String appClientProjectName,
java.lang.String appClientJarFileName,
boolean overwriteExisting,
boolean exportSource)
</PRE>
<DL>
<DD>
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>appClientProjectName</CODE> - The name of the Application
Client Module project to export.
</DD>
<DD><CODE>appClientJarFileName</CODE> - The fully qualified
Application Client Jar file location to export the specified
Application Client Module project.
</DD>
<DD><CODE>overwriteExisting</CODE> - If this is <code>true</code>
then an existing file at the location specified by <code>earFileName</code>
will be overwritten.
</DD>
<DD><CODE>exportSource</CODE> - If this is <code>true</code> then
all source files in the specified Application Client Module will be
included in the resulting Application Client Jar file.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<h2><A name="RAR"></A>Connector Modules</h2>
<h3><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.jca.operations.ConnectorModuleCreationDataModel</FONT></b></h3>
<PRE>
public static void <B>createProject</B>(java.lang.String projectName,
org.eclipse.core.runtime.IPath projectLocation,
int connectorModuleVersion)
</PRE>
<DL>
<DD>Creates an Connector project with the specified name and version
in the specified location.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>projectName</CODE> - The name of the Connector project to
create.
</DD>
<DD><CODE>projectLocation</CODE> - Sets the local file system
location for the described project. The path must be either an
absolute file system path, or a relative path whose first segment
is the name of a defined workspace path variable. If <code>null</code>
is specified, the default location is used.
</DD>
<DD><CODE>connectorModuleVersion</CODE> - Sets the JCA Version for
the descibed project. The version must be either <code>J2EEVersionConstants.JCA_1_0_ID</code>
or <code>J2EEVersionConstants.JCA_1_5_ID</code>.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.jca.operations.ConnectorModuleImportDataModel</FONT></b></h4>
<PRE>
public static void <B>importArchive</B>(java.lang.String rarFileName,
java.lang.String connectorProjectName,
boolean addToEar,
java.lang.String earProjectName)
</PRE>
<DL>
<DD>
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>rarFileName</CODE> - The path to the RAR file.
</DD>
<DD><CODE>connectorProjectName</CODE> - The name of the Connector
project where the Connector Module should be imported.
</DD>
<DD><CODE>addToEar</CODE> - If this is <code>true</code> then
Connector project specified by <code>connectorProjectName</code>
will be added to the Enterprise Application project specified by <code>earProjectName</code>.
</DD>
<DD><CODE>earProjectName</CODE> - The name of the Enterprise
Application project to add the specified Connector project to. This
field is only relevant if <code>addToEar</code> is set to <code>true</code>.
If this is set to <code>null</code> then a default name computed
from the <code>connectorProjectName</code> will be used.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
<h4><b><FONT SIZE="4">org.eclipse.jst.j2ee.internal.jca.operations.ConnectorModuleExportDataModel</FONT></b></h4>
<PRE>
public static void <B>exportProject</B>(java.lang.String connectorProjectName,
java.lang.String rarFileName,
boolean overwriteExisting,
boolean exportSource)
</PRE>
<DL>
<DD>Exports the specified Connector Module project to the specified
Connector RAR file.
</DD>
<BR/>
<DL>
<DT><B>Parameters:
</B>
</DT>
<DD><CODE>connectorProjectName</CODE> - The name of the Connector
Module project to export.
</DD>
<DD><CODE>rarFileName</CODE> - The fully qualified Connector RAR
file location to export the specified Connector Module project.
</DD>
<DD><CODE>overwriteExisting</CODE> - If this is <code>true</code>
then an existing file at the location specified by <code>earFileName</code>
will be overwritten.
</DD>
<DD><CODE>exportSource</CODE> - If this is <code>true</code> then
all source files in the specified Connector Module will be included
in the resulting Connector RAR file.
</DD>
<DT><B>Since:
</B></DT>
<DD>WTP 1.0
</DD>
</DL>
</DL>
<HR></HR>
</body>
</html>