EclipseLink 1.0_1.0M2 API Reference - Incubation

org.eclipse.persistence.tools.weaving.jpa
Class StaticWeaveAntTask

java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by org.eclipse.persistence.tools.weaving.jpa.StaticWeaveAntTask

public class StaticWeaveAntTask
extends org.apache.tools.ant.Task

Description: This is the static weave ant task definition class that verifies the value of specified attributes and invokes StaticWeaveProcessor to weave classes.

Usage:

Example: <target name="define.task" description="New task definition for toplink static weaving"/>
  <taskdef name="weave" classname="org.eclipse.persistence.tools.weaving.jpa.StaticWeaveAntTask"/>
</target>
<target name="weaving" description="perform weaving." depends="define.task">
  <weave source= "c:\foo.jar" target = "c:\wovenfoo.jar" persistenceinfo="c:\foo-containing-persistenceinfo.jar">
    <classpath>
      <pathelement path="c:\foo-dependent.jar"/>
    </classpath>
  </weave>
</target>


Field Summary
 
Fields inherited from class org.apache.tools.ant.Task
description, location, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
project
 
Constructor Summary
StaticWeaveAntTask()
           
 
Method Summary
 void addClasspath(org.apache.tools.ant.types.Path path)
          Add the dependent classpath in order to load classes from the specified input jar.
 void execute()
          Execute ant task
 void setLog(java.lang.String logFile)
          Set the archive containing persistence.xml while input archive does not contain it.
 void setLogLevel(java.lang.String logLevel)
           
 void setPersistenceinfo(java.lang.String persistenceinfo)
           
 void setSource(java.lang.String source)
          Set the input archive to be used to weave.
 void setTarget(java.lang.String target)
          Set output archive to be used to weave to
 
Methods inherited from class org.apache.tools.ant.Task
getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
getProject, setProject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StaticWeaveAntTask

public StaticWeaveAntTask()
Method Detail

setSource

public void setSource(java.lang.String source)
Set the input archive to be used to weave.

Parameters:
inputJarFile -

setTarget

public void setTarget(java.lang.String target)
Set output archive to be used to weave to

Parameters:
outputJarFile -

setLog

public void setLog(java.lang.String logFile)
            throws java.io.IOException
Set the archive containing persistence.xml while input archive does not contain it.

Parameters:
inputMainJarFile -
Throws:
java.io.IOException

setLogLevel

public void setLogLevel(java.lang.String logLevel)

setPersistenceinfo

public void setPersistenceinfo(java.lang.String persistenceinfo)

addClasspath

public void addClasspath(org.apache.tools.ant.types.Path path)
Add the dependent classpath in order to load classes from the specified input jar.

Parameters:
path -

execute

public void execute()
Execute ant task

Overrides:
execute in class org.apache.tools.ant.Task

EclipseLink 1.0_1.0M2 API Reference - Incubation