net.sf.antcontrib.cpptasks.types
Class DefineSet

java.lang.Object
  |
  +--org.apache.tools.ant.ProjectComponent
        |
        +--org.apache.tools.ant.types.DataType
              |
              +--net.sf.antcontrib.cpptasks.types.DefineSet

public class DefineSet
extends org.apache.tools.ant.types.DataType

Set of preprocessor macro defines and undefines.

Author:
Mark A Russell mark_russell@csg_systems.com, Adam Murdoch

Fields inherited from class org.apache.tools.ant.types.DataType
checked, description, ref
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
project
 
Constructor Summary
DefineSet()
           
 
Method Summary
 void addDefine(DefineArgument arg)
          Adds a define element.
 void addUndefine(UndefineArgument arg)
          Adds an undefine element.
 void execute()
           
 UndefineArgument[] getDefines()
          Returns the defines and undefines in this set.
 void setDefine(CUtil.StringArrayBuilder defList)
          A comma-separated list of preprocessor macros to define.
 void setDescription(java.lang.String desc)
          Sets a description of the current data type.
 void setId(java.lang.String id)
          Sets an id that can be used to reference this element.
 void setRefid(org.apache.tools.ant.types.Reference r)
          Specifies that this element should behave as if the content of the element with the matching id attribute was inserted at this location.
 void setUndefine(CUtil.StringArrayBuilder undefList)
          A comma-separated list of preprocessor macros to undefine.
 
Methods inherited from class org.apache.tools.ant.types.DataType
circularReference, dieOnCircularReference, getCheckedRef, getDescription, isReference, noChildrenAllowed, tooManyAttributes
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
getProject, log, log, setProject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefineSet

public DefineSet()
Method Detail

setDefine

public void setDefine(CUtil.StringArrayBuilder defList)
               throws org.apache.tools.ant.BuildException
A comma-separated list of preprocessor macros to define. Use nested define elements to define macro values.
Parameters:
defList - comma-separated list of preprocessor macros
Throws:
org.apache.tools.ant.BuildException - throw if defineset is a reference

setUndefine

public void setUndefine(CUtil.StringArrayBuilder undefList)
                 throws org.apache.tools.ant.BuildException
A comma-separated list of preprocessor macros to undefine.
Parameters:
defList - comma-separated list of preprocessor macros
Throws:
org.apache.tools.ant.BuildException - throw if defineset is a reference

addDefine

public void addDefine(DefineArgument arg)
               throws org.apache.tools.ant.BuildException
Adds a define element.
Throws:
org.apache.tools.ant.BuildException - if reference

addUndefine

public void addUndefine(UndefineArgument arg)
                 throws org.apache.tools.ant.BuildException
Adds an undefine element.
Throws:
org.apache.tools.ant.BuildException - if reference

setRefid

public void setRefid(org.apache.tools.ant.types.Reference r)
              throws org.apache.tools.ant.BuildException
Specifies that this element should behave as if the content of the element with the matching id attribute was inserted at this location. If specified, no other attributes or child content should be specified, other than "description".
Overrides:
setRefid in class org.apache.tools.ant.types.DataType

getDefines

public UndefineArgument[] getDefines()
                              throws org.apache.tools.ant.BuildException
Returns the defines and undefines in this set.

setId

public void setId(java.lang.String id)
Sets an id that can be used to reference this element.
Parameters:
id - id

setDescription

public void setDescription(java.lang.String desc)
Sets a description of the current data type.
Overrides:
setDescription in class org.apache.tools.ant.types.DataType

execute

public void execute()
             throws org.apache.tools.ant.BuildException


Copyright © 2001-2002 Ant-Contrib project. All Rights Reserved.