org.exolab.castor.builder
public class BuilderConfiguration extends Object
Version: $Revision: 6302 $ $Date: 2006-04-25 15:08:23 -0600 (Tue, 25 Apr 2006) $
Nested Class Summary | |
---|---|
static class | BuilderConfiguration.Property
Names of properties used in the configuration file. |
Constructor Summary | |
---|---|
BuilderConfiguration()
Creates a default BuilderConfiguration. |
Method Summary | |
---|---|
boolean | boundPropertiesEnabled()
Returns true if bound properties are enabled.
|
boolean | classDescFieldNames()
Returns true if we generate a 'public static final String' for the name
of each attribute and element described by the class descriptor
Enabling this property is controlled via the org.exolab.castor.builder.classdescfieldnames item in the castorbuilder.properties file. |
boolean | equalsMethod()
Returns true if we generate an 'equals' method for each generated class.
|
boolean | generateExtraCollectionMethods()
Returns true if extra methods for collection fields should be generated.
|
Properties | getDefault()
Returns the default configuration file. |
String | getProperty(String name, String defValue)
Returns a property from the default configuration file. |
protected void | load()
Called by BuilderConfiguration to load the configuration the first time.
|
String | lookupPackageByLocation(String schemaLocation)
Converts a schema location into a Java package.
|
String | lookupPackageByNamespace(String nsURL)
Gets a Java package to an XML namespace URL |
boolean | mappingSchemaElement2Java()
Tests the org.exolab.castor.builder.javaclassmapping property for the
'element' value.
|
boolean | mappingSchemaType2Java()
Tests the org.exolab.castor.builder.javaclassmapping property for the 'type' value.
|
protected void | processNamespacePackageMappings(String mappings)
processes the given String which contains namespace-to-package mappings
|
void | setClassDescFieldNames(boolean classDescFieldNames)
Sets the 'classDescFieldNames' property
|
void | setDefaultProperties(Properties properties)
Overrides the current set of properties with the given properties. |
void | setEqualsMethod(boolean equals)
Sets the 'equalsmethod' property.
|
void | setLocationPackageMapping(String schemaLocation, String packageName)
Sets the schemaLocation to package mapping.
|
void | setNamespacePackageMapping(String ns, String packageName)
Sets the namespace to package mapping.
|
void | setPrimitiveWrapper(boolean wrapper)
Sets the 'primitivetowrapper' property
|
void | setUseEnumeratedTypeInterface(boolean flag)
Sets the 'enumTypeAccessInterface' property
|
boolean | useEnumeratedTypeInterface()
Returns true if we generate the implements EnumeratedTypeAccess interface
for enumerated type classes. |
boolean | useJava50()
Returns true if we generate the implements EnumeratedTypeAccess interface
for enumerated type classes. |
boolean | usePrimitiveWrapper()
Returns true if primitive types have to be used as Objects (eg.
replacing float by java.lang.Float). |
Enabling bound properties is controlled via the org.exolab.castor.builder.boundproperties item in the castorbuilder.properties file. The value is either 'true' or 'false'.
Returns: true if bound properties are enabled.
Enabling this property is controlled via the org.exolab.castor.builder.classdescfieldnames item in the castorbuilder.properties file. The value is either 'true' or 'false'.
Returns: true if bound properties are enabled.
Enabling this property is controlled via the org.exolab.castor.builder.equalsmethod item in the castorbuilder.properties file. The value is either 'true' or 'false'.
Returns: true if bound properties are enabled.
Enabling extra collection methods is controlled via the org.exolab.castor.builder.extraCollectionMethods property in the castorbuilder.properties file. The value is either 'true' or 'false'.
Returns: true if extra collection methods are enabled.
Returns: The default configuration
Parameters: name The property name defValue The property's default value
Returns: The property's value
Parameters: schemaLocation the Schema location to use to look up the Java package
Returns: a Java package name
Parameters: nsURL the XML namespace URL to convert into a Java package name
Returns: a Java package name
Returns: True if the Source Generator is mapping schema elements to Java classes.
Returns: True if the Source Generator is mapping schema types to Java classes.
Parameters: mappings the namespace-to-package mappings
Parameters: classDescFieldNames the value we want to ues
Parameters: properties the Properties file
Parameters: equals The value we want to use.
Parameters: schemaLocation the schemaLocation to map packageName the package name to map to
Parameters: ns the namespace URI to map packageName the package name
Parameters: wrapper the value we want to use.
Parameters: flag the value we want to use
Returns: true if use enumerated type interface is enabled
Returns: true if use enumerated type interface is enabled
Returns: true if primitive types have to be used as Objects.