Project OracleDropJavaAntTask Notes


Title:OracleDropJava
Author:Nicholas Whitehead
Description:An Ant Custom Tool To Drop Java & Resources From Oracle JServer

OracleDropJava

Requirements

This taks requires an Oracle 9i database to drop the java classes and resources from and the following client resources:

Description

Invokes the Oracle dropjava process on a set of Java source files, class files, jar files and java resources.

dropjava removes Java source files, class files, jar files and java resources from the Oracle database.

Parameters

Attribute Description Required
noserverside Forces the access to server side objects to be accessed using the JDBC driver at the cost of performance. Benefits are unclear. No
oci | oci8 Instructs the loadjava process to use the OCI driver to communicate with the database. Yes (unless thin is specified)
schema Specifies the schema where the Java objects are dropped from. No
stdout Sends stderr output to stdout. No
synonym Drops the PUBLIC synonym for dropped classes. No
thin Instructs the loadjava process to use the thin driver to communicate with the database. Yes (unless oci is specified)
time Places a timestamp message on all output messages. No
user Specifies a connect string.
eg. thin: SCOTT/TIGER@localhost:1521:NICKMAN
eg. oci: SCOTT/TIGER@LOCAL
Yes
verbose Prints detailed status messages to stdout. No

Nested elements

For specifying the Java source, class files, jar files, zip files or resource files to be dropped from Oracle, specify a FileSet that encompasses the desired target. See example below.

Example

<?xml version="1.0" encoding="UTF-8"?>
<project name="OracleLoadJavaExample" default="main" basedir=".">
	<taskdef name="OracleDropJava" classname="org.apache.tools.ant.taskdefs.optional.oraclejava.OracleDropJava"/>
	<target name="main">
		<patternset id="oracle.drop.classes">
			<include name="props.class"/>
			<include name="Char.java"/>
			<include name="eyes.gif"/>
		</patternset>
		<OracleDropJava oci="on" user="SCOTT/TIGER@local" debug="on" verbose="on" noserverside="on" schema="scott" synonym="on" time="on">
			<fileset dir="${class.dir}">
				<patternset refid="oracle.load.classes"/>
			</fileset>
		</OracleDropJava>
	</target>
</project>

This invokes the dropjava process and drops four resources from the database specified in the user attribute of the the OracleDropJava element.

To Do List:

  1. None yet.

Copyright © 2001-2002 Apache Software Foundation. All rights Reserved.