Top Description Fields Constructors Methods
org.apache.tools.ant.taskdefs

public Class AugmentReference

extends Task
implements TypeAdapter
Class Inheritance
All Implemented Interfaces
org.apache.tools.ant.TypeAdapter
Imports
org.apache.tools.ant.BuildException, .Project, .RuntimeConfigurable, .Task, .TypeAdapter

Ant task to dynamically augment a previously declared reference.
Since
Ant 1.8.1

Field Summary

Modifier and TypeField and Description
private String
Inherited from org.apache.tools.ant.Task:
targettaskNametaskTypewrapper

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
checkProxyClass(Class<?>
the class to be checked.
proxyClass
)

Implements org.apache.tools.ant.TypeAdapter.checkProxyClass.

Check if the proxy class is compatible with this adapter - i.e. the adapter will be able to adapt instances of the give class.
public void
execute()

Overrides org.apache.tools.ant.Task.execute.

Overridden to restore the wrapper once it is no longer needed.
public synchronized Object
getProxy()

Implements org.apache.tools.ant.TypeAdapter.getProxy.

Returns the proxy object.
private synchronized void
private synchronized void
restoreWrapperId()

Needed if two different targets reuse the same instance.

public void
setProxy(Object
The target object. Must not be null.
o
)

Implements org.apache.tools.ant.TypeAdapter.setProxy.

Sets the proxy object, whose methods are going to be invoked by ant.
Inherited from org.apache.tools.ant.Task:
bindToOwnergetOwningTargetgetRuntimeConfigurableWrappergetTaskNamegetTaskTypegetWrapperhandleErrorFlushhandleErrorOutputhandleFlushhandleInputhandleOutputinitisInvalidloglogloglogmaybeConfigureperformreconfiguresetOwningTargetsetRuntimeConfigurableWrappersetTaskNamesetTaskType

Field Detail

idback to summary
private String id

Constructor Detail

AugmentReferenceback to summary
public AugmentReference()

Method Detail

checkProxyClassback to summary
public void checkProxyClass(Class<?> proxyClass)

Implements org.apache.tools.ant.TypeAdapter.checkProxyClass.

Doc from org.apache.tools.ant.TypeAdapter.checkProxyClass.

Check if the proxy class is compatible with this adapter - i.e. the adapter will be able to adapt instances of the give class.

Parameters
proxyClass:Class<?>

the class to be checked.

executeback to summary
public void execute()

Overrides org.apache.tools.ant.Task.execute.

Overridden to restore the wrapper once it is no longer needed.

Since
Ant 1.8.3
getProxyback to summary
public synchronized Object getProxy()

Implements org.apache.tools.ant.TypeAdapter.getProxy.

Doc from org.apache.tools.ant.TypeAdapter.getProxy.

Returns the proxy object.

Returns:Object

the target proxy object

hijackIdback to summary
private synchronized void hijackId()
restoreWrapperIdback to summary
private synchronized void restoreWrapperId()

Needed if two different targets reuse the same instance.

See Also
https://issues.apache.org/bugzilla/show_bug.cgi?id=50894
setProxyback to summary
public void setProxy(Object o)

Implements org.apache.tools.ant.TypeAdapter.setProxy.

Doc from org.apache.tools.ant.TypeAdapter.setProxy.

Sets the proxy object, whose methods are going to be invoked by ant. A proxy object is normally the object defined by a <typedef/> task that is adapted by the "adapter" attribute.

Parameters
o:Object

The target object. Must not be null.