xdoclet

Class XmlSubTask

Implemented Interfaces:
Serializable

public class XmlSubTask
extends TemplateSubTask

Generic subtask for processing a user-supplied template, to generate an XML document.
Version:
$Revision: 1.22 $
Author:
Ara Abrahamian (ara_e@email.com)
ant.element
name = "xml" parent = "xdoclet.DocletTask" display-name = "Standard Subtask for XML generation"
created
Oct 13, 2001

Nested Class Summary

Nested classes/interfaces inherited from class xdoclet.TemplateSubTask

TemplateSubTask.ExtentTypes, TemplateSubTask.OfType

Field Summary

Fields inherited from class xdoclet.DocletSupport

currentClassTag, currentFieldTag, currentMethodTag

Method Summary

void
copyAttributesFrom(TemplateSubTask templateSrc)
Describe what the method does
protected void
engineFinished()
Describe what the method does
URL
getDtdURL()
Gets the DtdURL attribute of the XmlSubTask object.
String
getPublicId()
Gets the PublicId attribute of the XmlSubTask object.
String
getSchema()
Gets the Schema attribute of the XmlSubTask object.
String
getSystemId()
Gets the SystemId attribute of the XmlSubTask object.
boolean
getUseIds()
Gets the UseIds attribute of the XmlSubTask object.
String
getXmlencoding()
Gets the Xmlencoding attribute of the XmlSubTask object.
boolean
isValidateXML()
Gets the ValidateXML attribute of the XmlSubTask object.
protected void
setDtdURL(URL dtdURL)
Sets the DtdURL attribute of the XmlSubTask object.
protected void
setPublicId(String publicId)
The PUBLIC ID of the DTD to which the generated document should conform.
void
setSchema(String schema)
The XML Schema to which the generated document should conform.
protected void
setSystemId(String systemId)
The SYSTEM ID of the DTD to which the generated document should conform.
void
setUseIds(boolean useIds)
If this attribute is set to true, XDoclet will generate id attributes in the XML document.
void
setValidateXML(boolean flag)
If this is set to true, the generated XML will be validated against its DTD or XML Schema.
void
setXmlencoding(String xmlEncoding)
The encoding of the produced xml file.
void
startProcess()
Describe what the method does

Methods inherited from class xdoclet.TemplateSubTask

addOfType, addOfType, addPackageSubstitution, copyAttributesFrom, engineFinished, engineStarted, execute, generateForClass, getAcceptAbstractClasses, getAcceptInterfaces, getDestinationFile, getEngine, getExtent, getGeneratedFileName, getGenerationManager, getHavingClassTag, getOfType, getPackageSubstitutions, getSubTaskClassName, getTemplateURL, init, isPackageSubstitutionInheritanceSupported, isPrefixWithPackageStructure, javaFile, matchesGenerationRules, processInnerClasses, setAcceptAbstractClasses, setAcceptInterfaces, setDestinationFile, setEngine, setExtent, setExtentValue, setGenerationManager, setHavingClassTag, setOfType, setPackageSubstitutionInheritanceSupported, setPackageSubstitutions, setPrefixWithPackageStructure, setSubTaskClassName, setTemplateFile, setTemplateURL, startEngine, startProcess, startProcessForAll, startProcessPerClass, validateOptions

Methods inherited from class xdoclet.SubTask

addConfigParam, copyAttributesFrom, execute, getConfigParams, getConfigParamsAsMap, getContext, getDestDir, getMergeDir, getSubTaskName, getXJavaDoc, init, setDestDir, setMergeDir, setSubTaskName, validateOptions

Methods inherited from class xdoclet.DocletSupport

getCurrentClass, getCurrentClassTag, getCurrentConstructor, getCurrentField, getCurrentFieldTag, getCurrentMethod, getCurrentMethodTag, getCurrentPackage, getCurrentTag, isDocletGenerated, popCurrentClass, pushCurrentClass, setCurrentClass, setCurrentClassTag, setCurrentConstructor, setCurrentField, setCurrentFieldTag, setCurrentMethod, setCurrentMethodTag, setCurrentPackage

Method Details

copyAttributesFrom

public void copyAttributesFrom(TemplateSubTask templateSrc)
Describe what the method does
Overrides:
copyAttributesFrom in interface TemplateSubTask
Parameters:
templateSrc - Describe what the parameter does

engineFinished

protected void engineFinished()
            throws XDocletException
Describe what the method does
Overrides:
engineFinished in interface TemplateSubTask
Throws:
XDocletException - Describe the exception

getDtdURL

public URL getDtdURL()
Gets the DtdURL attribute of the XmlSubTask object.
Returns:
The DtdURL value

getPublicId

public String getPublicId()
Gets the PublicId attribute of the XmlSubTask object.
Returns:
The PublicId value

getSchema

public String getSchema()
Gets the Schema attribute of the XmlSubTask object.
Returns:
The Schema value

getSystemId

public String getSystemId()
Gets the SystemId attribute of the XmlSubTask object.
Returns:
The SystemId value

getUseIds

public boolean getUseIds()
Gets the UseIds attribute of the XmlSubTask object.
Returns:
The UseIds value

getXmlencoding

public String getXmlencoding()
Gets the Xmlencoding attribute of the XmlSubTask object.
Returns:
The Xmlencoding value

isValidateXML

public boolean isValidateXML()
Gets the ValidateXML attribute of the XmlSubTask object.
Returns:
The ValidateXML value

setDtdURL

protected void setDtdURL(URL dtdURL)
Sets the DtdURL attribute of the XmlSubTask object.
Parameters:
dtdURL - The new DtdURL value

setPublicId

protected void setPublicId(String publicId)
The PUBLIC ID of the DTD to which the generated document should conform.
Parameters:
publicId - The new PublicId value

setSchema

public void setSchema(String schema)
The XML Schema to which the generated document should conform.
Parameters:
schema - The new Schema value

setSystemId

protected void setSystemId(String systemId)
The SYSTEM ID of the DTD to which the generated document should conform.
Parameters:
systemId - The new SystemId value

setUseIds

public void setUseIds(boolean useIds)
If this attribute is set to true, XDoclet will generate id attributes in the XML document. Note that this is only available in some subtasks.
Parameters:
useIds - The new UseIds value
ant.not-required
"No. Default is 'false'"

setValidateXML

public void setValidateXML(boolean flag)
If this is set to true, the generated XML will be validated against its DTD or XML Schema.
Parameters:
flag - The new Validatexml value
ant.not-required
No,defaultis false.

setXmlencoding

public void setXmlencoding(String xmlEncoding)
The encoding of the produced xml file. If your XML file uses international characters, you might want to set this to "ISO-8859-1".
Parameters:
xmlEncoding - The new Xmlencoding value
ant.not-required
"No, default is 'UTF-8'"

startProcess

public void startProcess()
            throws XDocletException
Describe what the method does
Overrides:
startProcess in interface TemplateSubTask
Throws:
XDocletException - Describe the exception