Task in a special class loader that allows us to control
where to load particular APIs.
| Modifier and Type | Class and Description |
|---|---|
| private class | ProtectedTask.
Captures the elements and attributes. |
| Modifier and Type | Field and Description |
|---|---|
| private final ProtectedTask. |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected abstract ClassLoader | Returns: ClassLoader use d for task executionCreates a protective class loader that will host the actual task. |
| public Object | createDynamicElement(String name)
Implements org. Create an element with the given name |
| public void | execute()
Overrides org. Called by the project to let the task do its work. |
| protected abstract String | Returns: Task class nameReturns the name of the class that extends |
| private ClassLoader | |
| public void | setDynamicAttribute(String name, String value)
Implements org. Set a named attribute to the given value |
| root | back to summary |
|---|---|
| private final ProtectedTask. | |
| ProtectedTask | back to summary |
|---|---|
| public ProtectedTask() | |
| createClassLoader | back to summary |
|---|---|
| protected abstract ClassLoader createClassLoader() throws ClassNotFoundException, IOException Creates a protective class loader that will host the actual task.
| |
| createDynamicElement | back to summary |
|---|---|
| public Object createDynamicElement(String name) throws BuildException Implements org. Doc from org. Create an element with the given name
| |
| execute | back to summary |
|---|---|
| public void execute() throws BuildException Overrides org. Doc from org. Called by the project to let the task do its work. This method may be called more than once, if the task is invoked more than once. For example, if target1 and target2 both depend on target3, then running "ant target1 target2" will run all tasks in target3 twice.
| |
| getCoreClassName | back to summary |
|---|---|
| protected abstract String getCoreClassName() Returns the name of the class that extends
| |
| getParentClassLoader | back to summary |
|---|---|
| private ClassLoader getParentClassLoader(final ClassLoader cl) | |
| setDynamicAttribute | back to summary |
|---|---|
| public void setDynamicAttribute(String name, String value) throws BuildException Implements org. Doc from org. Set a named attribute to the given value
| |
| Modifier and Type | Field and Description |
|---|---|
| private final Map | |
| private final List | |
| private final String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public Object | createDynamicElement(String name)
Implements org. Create an element with the given name |
| public void | setDynamicAttribute(String name, String value)
Implements org. Set a named attribute to the given value |
| attributes | back to summary |
|---|---|
| private final Map<String, String> attributes | |
| elements | back to summary |
|---|---|
| private final List<ProtectedTask. | |
| name | back to summary |
|---|---|
| private final String name | |
| AntElement | back to summary |
|---|---|
| public AntElement(String name) | |
| configure | back to summary |
|---|---|
| public void configure(Object antObject) Copies the properties into the Ant task. | |
| createDynamicElement | back to summary |
|---|---|
| public Object createDynamicElement(String name) throws BuildException Implements org. Doc from org. Create an element with the given name
| |
| setDynamicAttribute | back to summary |
|---|---|
| public void setDynamicAttribute(String name, String value) throws BuildException Implements org. Doc from org. Set a named attribute to the given value
| |