Gant 1.9.6

org.codehaus.gant
[Groovy] Class IncludeTool

java.lang.Object
  org.codehaus.gant.AbstractInclude
      org.codehaus.gant.IncludeTool

class IncludeTool
extends AbstractInclude

An instance of this class is provided to each Gant script for including tools. A tool is a class that provides Gant related facilities. The class must have a single parameter constructor which is a Map. The map contains a binding of various useful things, in particular there is always an entry 'Ant' to give access to the global static instance of AntBuilder.

Authors:
Russel Winder


Field Summary
 
Fields inherited from class AbstractInclude
binding, loadedClasses, pendingClass
 
Constructor Summary
IncludeTool(GantBinding binding)

Constructor.

 
Method Summary
java.lang.Object leftShift(java.lang.Class theClass)

Implementation of the << operator taking a Class parameter.

java.lang.Object leftShift(java.io.File file)

Implementation of the << operator taking a File parameter.

java.lang.Object leftShift(java.lang.String script)

Implementation of the << operator taking a String parameter.

java.lang.Object multiply(java.util.Map keywordParameters)

Implementation of the * operator taking a Map parameter.

 
Methods inherited from class AbstractInclude
createInstance, createInstance, leftShift, leftShift, leftShift, leftShift, leftShift, multiply, power, readFile
 
Methods inherited from class java.lang.Object
java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Constructor Detail

IncludeTool

IncludeTool(GantBinding binding)
Constructor.
Parameters:
binding - The GantBinding to associate with.


 
Method Detail

leftShift

java.lang.Object leftShift(java.lang.Class theClass)
Implementation of the << operator taking a Class parameter.
Parameters:
theClass - The Class to load and instantiate.
Returns:
The includer object to allow for << chaining.


leftShift

java.lang.Object leftShift(java.io.File file)
Implementation of the << operator taking a File parameter.
Parameters:
file - The File to load, compile, and instantiate.
Returns:
The includer object to allow for << chaining.


leftShift

java.lang.Object leftShift(java.lang.String script)
Implementation of the << operator taking a String parameter.
Parameters:
s - The String to compile and instantiate.
Returns:
The includer object to allow for << chaining.


multiply

java.lang.Object multiply(java.util.Map keywordParameters)
Implementation of the * operator taking a Map parameter. This operator only makes sense immediately after a ** operator, since only then is there a Class to instantiate.
Parameters:
keywordParameter - The Map of parameters to the constructor.
Returns:
The includer object to allow for ** * operator chaining.


 

Copyright © 2006–9 The Codehaus. All Rights Reserved.