Klasse UnitDescriptor
java.lang.Object
org.apache.torque.generator.configuration.UnitDescriptor
Contains all necessary information about a generation unit.
-
Verschachtelte Klassen - Übersicht
Verschachtelte KlassenModifizierer und TypKlasseBeschreibungstatic enum
Possible packaging forms of a unit of generation. -
Konstruktorübersicht
KonstruktorenKonstruktorBeschreibungUnitDescriptor
(UnitDescriptor.Packaging packaging, ProjectPaths projectPaths, TorqueGeneratorPaths configurationPaths) Constructor without inheritance, override options, overrideSourceFileset, loglevel and addDebuggingInfoToOutput. -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungReturns the class loader to use by the generator when accessing the templates or classes defined within the templates.Returns the paths in the configuration of this generation unit.Returns the output encoding if no specific encoding has been set in the output.Returns the descriptor of the generation unit from which this generation unit inherits, or null if this generation unit does not inherit from another generation unit.Returns the log level overriding the loglevel defined in the configuration unit.Returns the configuration of the overriding options, if any.Returns the source provider overriding the source defined in the control file, or null if the control file definition is not overridden.Returns the packaging of the unit of generation.Returns the paths which the Torque generator must know about the surrounding project.boolean
Returns whether debugging info should be added to the output.boolean
Returns true if only the sources should be processed which have changed since last generation.void
setAddDebuggingInfoToOutput
(boolean addDebuggingInfoToOutput) Sets whether debugging info should be added to the output.void
setClassLoader
(ClassLoader classLoader) Sets the class loader to use by the generator when accessing the templates or classes defined within the templates.void
setDefaultOutputEncoding
(Charset defaultOutputCharset) Sets the output encoding which is used if no specific encoding has been set in the output.void
setInheritsFrom
(UnitDescriptor inheritsFrom) Sets the descriptor of the generation unit from which this generation unit inherits.void
setLoglevel
(Loglevel loglevel) Sets the log level overriding the loglevel defined in the configuration unit.void
setOverrideOptions
(OptionsConfiguration overrideOptions) Sets the configuration of the overriding options, if any.void
setOverrideSourceProvider
(SourceProvider overrideSourceProvider) Sets the source provider overriding the source defined in the control file.void
setRunOnlyOnSourceChange
(boolean runOnlyOnSourceChange) Sets whether only the sources should be processed which have changed since last generation.
-
Konstruktordetails
-
UnitDescriptor
public UnitDescriptor(UnitDescriptor.Packaging packaging, ProjectPaths projectPaths, TorqueGeneratorPaths configurationPaths) Constructor without inheritance, override options, overrideSourceFileset, loglevel and addDebuggingInfoToOutput.- Parameter:
packaging
- The packaging of the generation unit, not null.projectPaths
- The paths the Torque generator must know about the surrounding project, not null.configurationPaths
- The paths within the configuration of the configuration unit, not null.
-
-
Methodendetails
-
getPackaging
Returns the packaging of the unit of generation.- Gibt zurück:
- the packaging of the unit of generation, not null.
-
getProjectPaths
Returns the paths which the Torque generator must know about the surrounding project.- Gibt zurück:
- the paths of the surrounding project, not null.
-
getConfigurationPaths
Returns the paths in the configuration of this generation unit.- Gibt zurück:
- the paths in the configuration of this generation unit, not null.
-
getInheritsFrom
Returns the descriptor of the generation unit from which this generation unit inherits, or null if this generation unit does not inherit from another generation unit.- Gibt zurück:
- the parents unit descriptor, or null if no parent exists.
-
setInheritsFrom
Sets the descriptor of the generation unit from which this generation unit inherits.- Parameter:
inheritsFrom
- the parents unit descriptor, or null if no parent exists.
-
getOverrideSourceProvider
Returns the source provider overriding the source defined in the control file, or null if the control file definition is not overridden.- Gibt zurück:
- the overriding source provider, or null.
-
setOverrideSourceProvider
Sets the source provider overriding the source defined in the control file.- Parameter:
overrideSourceProvider
- the overriding source provider, or null if the control file definition is not overridden.
-
getOverrideOptions
Returns the configuration of the overriding options, if any.- Gibt zurück:
- the configuration of the overriding options, or null.
-
setOverrideOptions
Sets the configuration of the overriding options, if any.- Parameter:
overrideOptions
- the configuration of the overriding options, or null.
-
getLoglevel
Returns the log level overriding the loglevel defined in the configuration unit.- Gibt zurück:
- the log level, or null.
-
setLoglevel
Sets the log level overriding the loglevel defined in the configuration unit.- Parameter:
loglevel
- the log level, or null.
-
isAddDebuggingInfoToOutput
public boolean isAddDebuggingInfoToOutput()Returns whether debugging info should be added to the output.- Gibt zurück:
- true if debugging info should be added to the output, false if not.
-
setAddDebuggingInfoToOutput
public void setAddDebuggingInfoToOutput(boolean addDebuggingInfoToOutput) Sets whether debugging info should be added to the output.- Parameter:
addDebuggingInfoToOutput
- true if debugging info should be added to the output, false if not.
-
getDefaultOutputEncoding
Returns the output encoding if no specific encoding has been set in the output.- Gibt zurück:
- the default output encoding, null for the default platform encoding.
-
setDefaultOutputEncoding
Sets the output encoding which is used if no specific encoding has been set in the output.- Parameter:
defaultOutputCharset
- the default output encoding, null for the default platform encoding.
-
getClassLoader
Returns the class loader to use by the generator when accessing the templates or classes defined within the templates.- Gibt zurück:
- the class loader for the templates, or null if the standard class loader of the torque generator classes is used.
-
setClassLoader
Sets the class loader to use by the generator when accessing the templates or classes defined within the templates.- Parameter:
classLoader
- the class loader for the templates, or null if the standard class loader of the torque generator classes should be used.
-
isRunOnlyOnSourceChange
public boolean isRunOnlyOnSourceChange()Returns true if only the sources should be processed which have changed since last generation.- Gibt zurück:
- false if the controller should be run irrespective of changes in the source files, true if the controller should be run for source files which have changed during last generation.
-
setRunOnlyOnSourceChange
public void setRunOnlyOnSourceChange(boolean runOnlyOnSourceChange) Sets whether only the sources should be processed which have changed since last generation.- Parameter:
runOnlyOnSourceChange
- false if the controller should be run irrespective of changes in the source files, true if the controller should be run for source files which have changed during last generation.
-