org.jomc.ant
Class CommitClassesTask

Package class diagram package CommitClassesTask
java.lang.Object
  extended by org.apache.tools.ant.ProjectComponent
      extended by org.apache.tools.ant.Task
          extended by org.jomc.ant.JomcTask
              extended by org.jomc.ant.JomcModelTask
                  extended by org.jomc.ant.JomcToolTask
                      extended by org.jomc.ant.ClassFileProcessorTask
                          extended by org.jomc.ant.CommitClassesTask
All Implemented Interfaces:
Cloneable

public final class CommitClassesTask
extends ClassFileProcessorTask

Task for committing model objects to class files.

Version:
$JOMC: CommitClassesTask.java 4174 2012-01-15 09:30:01Z schulte2005 $
Author:
Christian Schulte

Field Summary
 
Fields inherited from class org.apache.tools.ant.Task
target, taskName, taskType, wrapper
 
Fields inherited from class org.apache.tools.ant.ProjectComponent
description, location, project
 
Constructor Summary
CommitClassesTask()
          Creates a new CommitClassesTask instance.
 
Method Summary
 CommitClassesTask clone()
          Creates and returns a copy of this object.
 TransformerResourceType createModelObjectStylesheetResource()
          Creates a new modelObjectStylesheetResource element instance.
 File getClassesDirectory()
          Gets the directory holding the class files to commit model objects to.
 List<TransformerResourceType> getModelObjectStylesheetResources()
          Gets the XSLT documents to use for transforming model objects.
 void preExecuteTask()
          Called by the execute method prior to the executeTask method.
 void processClassFiles()
          Commits model objects to class files.
 void setClassesDirectory(File value)
          Sets the directory holding the class files to commit model objects to.
 
Methods inherited from class org.jomc.ant.ClassFileProcessorTask
configureClassFileProcessor, executeTask, getClassFileProcessorClass, isClassProcessingEnabled, newClassFileProcessor, setClassFileProcessorClass, setClassProcessingEnabled
 
Methods inherited from class org.jomc.ant.JomcToolTask
configureJomcTool, createLocale, createTemplateParameter, createTemplateParameterResource, createVelocityProperty, createVelocityPropertyResource, getDefaultTemplateProfile, getImplementation, getImplementation, getIndentation, getInputEncoding, getLineSeparator, getLocale, getModule, getModule, getOutputEncoding, getSpecification, getSpecification, getTemplateEncoding, getTemplateLocation, getTemplateParameterResources, getTemplateParameters, getTemplateProfile, getVelocityProperties, getVelocityPropertyResources, isModulesProcessingRequested, postExecuteTask, setDefaultTemplateProfile, setImplementation, setIndentation, setInputEncoding, setLineSeparator, setModule, setOutputEncoding, setSpecification, setTemplateEncoding, setTemplateLocation, setTemplateProfile
 
Methods inherited from class org.jomc.ant.JomcModelTask
createModuleResource, getModel, getModuleLocation, getModuleResources, getTransformerLocation, isModelObjectClasspathResolutionEnabled, isModelResourceValidationEnabled, newModelContext, setModelObjectClasspathResolutionEnabled, setModelResourceValidationEnabled, setModuleLocation, setTransformerLocation
 
Methods inherited from class org.jomc.ant.JomcTask
assertKeysNotNull, assertLocationsNotNull, assertNamesNotNull, assertNotNull, createClasspath, createModelContextAttribute, createTransformationOutputProperty, createTransformationParameter, createTransformationParameterResource, execute, getClasspath, getDirectory, getIf, getModel, getModelContextAttributes, getModelContextFactoryClassName, getModletLocation, getModletSchemaSystemId, getPlatformProviderLocation, getProperties, getProviderLocation, getResource, getResources, getTransformationOutputProperties, getTransformationParameterResources, getTransformationParameters, getTransformer, getUnless, isModelProcessingEnabled, isModletResourceValidationEnabled, logMessage, logMessage, logSeparator, logValidationReport, newProjectClassLoader, setClasspath, setClasspathRef, setIf, setModel, setModelContextFactoryClassName, setModelProcessingEnabled, setModletLocation, setModletResourceValidationEnabled, setModletSchemaSystemId, setPlatformProviderLocation, setProviderLocation, setUnless
 
Methods inherited from class org.apache.tools.ant.Task
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
 
Methods inherited from class org.apache.tools.ant.ProjectComponent
getDescription, getLocation, getProject, setDescription, setLocation, setProject
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommitClassesTask

public CommitClassesTask()
Creates a new CommitClassesTask instance.

Method Detail

getClassesDirectory

public File getClassesDirectory()
Gets the directory holding the class files to commit model objects to.

Returns:
The directory holding the class files to commit model objects to or null.
See Also:
setClassesDirectory(java.io.File)

setClassesDirectory

public void setClassesDirectory(File value)
Sets the directory holding the class files to commit model objects to.

Parameters:
value - The new directory holding the class files to commit model objects to or null.
See Also:
getClassesDirectory()

getModelObjectStylesheetResources

public List<TransformerResourceType> getModelObjectStylesheetResources()
Gets the XSLT documents to use for transforming model objects.

This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the object. This is why there is no set method for the model object stylesheet resources property.

Returns:
The XSLT documents to use for transforming model objects.
See Also:
createModelObjectStylesheetResource()

createModelObjectStylesheetResource

public TransformerResourceType createModelObjectStylesheetResource()
Creates a new modelObjectStylesheetResource element instance.

Returns:
A new modelObjectStylesheetResource element instance.
See Also:
getModelObjectStylesheetResources()

preExecuteTask

public void preExecuteTask()
                    throws org.apache.tools.ant.BuildException
Called by the execute method prior to the executeTask method.

Overrides:
preExecuteTask in class JomcToolTask
Throws:
org.apache.tools.ant.BuildException - if execution fails.
See Also:
JomcTask.execute()

processClassFiles

public void processClassFiles()
                       throws org.apache.tools.ant.BuildException
Commits model objects to class files.

Overrides:
processClassFiles in class ClassFileProcessorTask
Throws:
org.apache.tools.ant.BuildException - if committing model objects fails.
See Also:
ClassFileProcessorTask.executeTask()

clone

public CommitClassesTask clone()
Creates and returns a copy of this object.

Overrides:
clone in class ClassFileProcessorTask
Returns:
A copy of this object.


Copyright © 2005-2012 The JOMC Project. All Rights Reserved.Get JOMC at SourceForge.net. Fast, secure and Free Open Source software downloads
Please note that this documentation is maintained by non-native english speaking authors. As such, you may encounter phrases or wordings which seem imprecise or may even have a totally different meaning to native english speaking readers than what the individual author was trying to express. If you are a native english speaking reader and find any such phrases or wordings we kindly ask you to send an email to the corresponding author and help us improve this documentation in order to avoid misunderstandings. You will find the authors' email addresses at the top of each class. Please accept our apologies for any inconvenience caused.