Before building the Enterprise Console Feature Option 1 samples, you must first install all the prerequisite software and set up your environment for access to all of the required class libraries. These include the Apache Axis libraries, Eclipse EMF, and Eclipse TPTP toolkit libraries.
Open the file <sdk_install_dir>/samples/wsnt-axis/sample-axis.properties
and modify it as follows:
AXIS_JARS_PATH=<axis_jars_directory> ECLIPSE_JARS_PATH=<eclipse_jars_directory> SERVICE_ADDRESS=<NotificationConsumerService_URL>
where
lib
directory of the
Apache Axis image.
Attention:
You must use forward slashes "/" as the directory separator for the
AXIS_JAR_PATH
and ECLIPSE_JAR_PATH
properties.
For instance, if the Apache Axis libraries are located under
E:\axis-1.2\lib
, you must set the AXIS_JAR_PATH
property to E:/axis_1.2/lib
.
Apache Axis provides a code generation tool called wsdl2java
which generates Java classes from a Web Services wsdl file. The
generated classes are the client side stubs for accessing Web Services
from Web Services specifications
In this example, the wsdl2java tool is invoked through an Apache Ant script, called build.xml. Apache Ant is a very sophisticated scripting environment and is very popular amongst Java developers.
The build.xml
file in the <sdk_install_dir>/samples/wsnt-axis
directory of the SDK contains Apache Ant tasks for building the sample.
To build the samples, perform the following steps:
set JAVA_HOME=<location of jdk>
set ANT_HOME=<location of ant installation>
cd <sdk_install_dir>\samples\wsnt-axis
%ANT_HOME%\bin\ant
export JAVA_HOME=<location of jdk>
export ANT_HOME=<location of ant installation>
cd <sdk_install_dir>/samples/wsnt-axis
$ANT_HOME/bin/ant
The Java class files will be generated from the wsdl file and placed
in the <sdk_install_dir>/samples/wsnt-axis/src
directory. They will be compiled into directory <sdk_install_dir>/samples/wsnt-axis/build/classes
.
A jar file called wsnt-axis-samples.jar
of the classes is
created in <sdk_install_dir>/samples/wsnt-axis/build/lib
directory.
Note
The following error message appears in the console during building of
the sample and can be safely ignored.
[axis-wsdl2java] - Unable to find required classes (javax.activation.DataHandler and javax.mail.internet.MimeMultipart). Attachment support is disabled.
Parent topic
Apache Axis samples
Related topics
WS-Notification sample
walkthrough
Running the samples