org.apache.ws.jaxme.generator
public interface Generator extends PropertySource
The Generator is a frontend for working with the SchemaReaders, SourceWriters and whatever else.
Usage: Generates java source definitions from various inputs:
The inputs are interpreted into schema definitions by the SchemaReader set by calling Generator.
Other properties give fine grained control over various aspects of the file generation:
and the processing of the schema:
Implementation note: If you update this interface, you should consider updating the following files and classes as well:
Version: $Id: Generator.java 358956 2005-12-25 00:43:38Z jochen $
Method Summary | |
---|---|
void | addBindings(InputSource pSource) Sets the external schema bindings. |
SchemaSG | generate(File pFile)
Generates java source from the given |
SchemaSG | generate(URL pURL)
Generates java source from the given |
SchemaSG | generate(InputSource pSource)
Generates java source from the given |
Document[] | getBindings() Returns the external schema bindings, if any, or null. |
EntityResolver | getEntityResolver() Returns the EntityResolver being used to import external schemata. |
String | getKey() Returns a key for getting and setting custom data. |
File | getResourceTargetDirectory() Sets the directory where resource files are being
created. |
SchemaReader | getSchemaReader() Returns the SchemaReader being used. |
File | getTargetDirectory() Returns the directory where Java source files are being
created. |
boolean | isForcingOverwrite() Returns whether the generator is forcing an overwrite of files. |
boolean | isSettingReadOnly() Returns whether the generator will create files in read-only mode. |
boolean | isValidating() Returns whether the generator is using a validating XML schema parser. |
void | setEntityResolver(EntityResolver pEntityResolver) Sets the EntityResolver being used to import external schemata. |
void | setForcingOverwrite(boolean pIsForcingOverwrite) Sets whether the generator is forcing an overwrite of files. |
void | setResourceTargetDirectory(File pDirectory) Sets the directory where resource files are being
created. |
void | setSchemaReader(SchemaReader pSchemaReader) Sets the SchemaReader to use. |
void | setSettingReadOnly(boolean pIsSettingReadOnly) Sets whether the generator will create files in read-only mode. |
void | setTargetDirectory(File pDirectory) Sets the directory where Java source files are being
created. |
void | setValidating(boolean pValidating) Sets whether the generator is using a validating XML schema parser. |
Generates java source from the given File
.
Parameters: pFile reads the schema (from which the source is to be generated) from the given file.
Returns: SchemaSG
describing the source generated
Generates java source from the given URL
.
Parameters: pURL reads the schema (from which the source is to be generated) from the given URL.
Returns: SchemaSG
describing the source generated
Generates java source from the given URL
.
Parameters: pSource reads the schema (from which the source is to be generated) from the SAX Input Source. The System ID should be (if possible) set.
Returns: SchemaSG
describing the source generated
Returns the EntityResolver being used to import external schemata.
Returns a key for getting and setting custom data.
Returns the SchemaReader being used.
Returns whether the generator is forcing an overwrite of files.
Returns whether the generator will create files in read-only mode.
Returns whether the generator is using a validating XML schema parser. Defaults to false.
Sets the EntityResolver being used to import external schemata.
Sets whether the generator is forcing an overwrite of files.
Sets the SchemaReader to use.
Sets whether the generator will create files in read-only mode.
Sets whether the generator is using a validating XML schema parser. Defaults to false.