org.openanzo.jdbc.utils.opgen.ant
Class CompositionTask.PSTask

java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by org.openanzo.jdbc.utils.opgen.ant.CompositionTask.PSTask
Enclosing class:
CompositionTask

public static class CompositionTask.PSTask
extends org.apache.tools.ant.Task

Provides file listings of prepared statements.

Author:
Joe Betz

Constructor Summary
CompositionTask.PSTask()
           
 
Method Summary
 void addFileset(org.apache.tools.ant.types.FileSet fileSet)
          Add a fileset to this task
 void execute()
           
 java.lang.String getDestBase()
          Get the destination directory
 java.util.List<org.apache.tools.ant.types.FileSet> getFiles()
          Get the files that make up the fileset for this task
 java.lang.String getJavaClass()
          Get the name for the class
 boolean isExcludeNamespace()
          Return true if parser should ignore the namespce of the sql statements
 boolean isRethrowSQLException()
          Get if SQL exceptions should be rethrown or wrapped
 void setDestBase(java.lang.String destBase)
          Set the destination directory
 void setException(java.lang.String rethrowExceptionName)
          Set the type of exception to use in generated code
 void setExcludeNamespace(boolean excludeNamespace)
          Set whether to exclude the namespace of the sql statements
 void setJavaClass(java.lang.String javaClass)
          Set the name for the class
 void setRethrowSQLException(boolean rethrowSQLException)
          Set if SQL exceptions should be rethrown or wrapped
 void write(java.io.OutputStreamWriter writer, java.lang.String outputFormat)
          Write out the transformed SQL file
 
Methods inherited from class org.apache.tools.ant.Task
getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, init, 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
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompositionTask.PSTask

public CompositionTask.PSTask()
Method Detail

addFileset

public void addFileset(org.apache.tools.ant.types.FileSet fileSet)
Add a fileset to this task

Parameters:
fileSet - to add

setException

public void setException(java.lang.String rethrowExceptionName)
Set the type of exception to use in generated code

Parameters:
rethrowExceptionName - type of exception to use in generated code

getFiles

public java.util.List<org.apache.tools.ant.types.FileSet> getFiles()
Get the files that make up the fileset for this task

Returns:
the files that make up the fileset for this task

setJavaClass

public void setJavaClass(java.lang.String javaClass)
Set the name for the class

Parameters:
javaClass - the name for the class

getJavaClass

public java.lang.String getJavaClass()
Get the name for the class

Returns:
the name for the class

setDestBase

public void setDestBase(java.lang.String destBase)
Set the destination directory

Parameters:
destBase - the destination directory

getDestBase

public java.lang.String getDestBase()
Get the destination directory

Returns:
the destination directory

execute

public void execute()
Overrides:
execute in class org.apache.tools.ant.Task

write

public void write(java.io.OutputStreamWriter writer,
                  java.lang.String outputFormat)
           throws java.io.FileNotFoundException,
                  java.io.IOException,
                  javax.xml.parsers.ParserConfigurationException,
                  javax.xml.parsers.FactoryConfigurationError,
                  org.xml.sax.SAXException
Write out the transformed SQL file

Parameters:
writer - output writer used to write file
outputFormat - format of output file
Throws:
java.io.FileNotFoundException
java.io.IOException
javax.xml.parsers.ParserConfigurationException
javax.xml.parsers.FactoryConfigurationError
org.xml.sax.SAXException

setExcludeNamespace

public void setExcludeNamespace(boolean excludeNamespace)
Set whether to exclude the namespace of the sql statements

Parameters:
excludeNamespace - whether to exclude the namespace of the sql statements

isExcludeNamespace

public boolean isExcludeNamespace()
Return true if parser should ignore the namespce of the sql statements

Returns:
true if parser should ignore the namespce of the sql statements

setRethrowSQLException

public void setRethrowSQLException(boolean rethrowSQLException)
Set if SQL exceptions should be rethrown or wrapped

Parameters:
rethrowSQLException - if SQL exceptions should be rethrown or wrapped

isRethrowSQLException

public boolean isRethrowSQLException()
Get if SQL exceptions should be rethrown or wrapped

Returns:
true if SQL exceptions should be rethrown, else wrapped


Copyright © 2007 Cambridge Semantics Inc.. All Rights Reserved.