User's Guide

Using XML Initialization Settings

The AbtXmlConfiguration singleton object is used to reference initialization information from an application's .ini file. You can add any desired XML related constants to the [Xml] section of an .ini file. To determine where XML resources are located, use the predefined setting DefaultResourceQualifier in applications.

For example:

[Xml]
DefaultResourceQualifier=http://vasthost/xml
sstwsdl.xsd=http://vashost/wsdlschema.xsd
PrintTypesEnabled=false	
 

The VisualAge XML support uses the settings from the AbtXmlConfiguration to initialize various runtime behaviors. Below is a list of the predefined keys that are resolved from the active AbtXmlConfiguration. Users can add associations to the [Xml] stanza and reference these associations in their applications.

Table 1.

Name Purpose Default
DefaultResourceQualifier The default location where XML parser attempts to locate resources image startup directory
MappingExceptionsEnabled Boolean value that is set to true if mapping exceptions should be signalled false
ParserDecodingEnabled Boolean value that is set to true if the code page conversion should be performed on incoming XML streams true
PrintTypesEnabled Boolean value that is set to true if xsi:type information should be printed with rendered XML elements true
SchemaDefinitionDefaultUri The schema definition namespace URI http://www.w3.org/2001/XMLSchema
SchemaInstanceDefaultUri The schema instance namespace URI http://www.w3.org/2001/XMLSchema-instance
StreamFormattingEnabled Boolean value that is set to true if rendered XML stream contents should include tabs, carriage returns, etc. true

The following code demonstrates some of the API for AbtXmlConfiguration.

	AbtXmlConfiguration current booleanPropertyNamed: 'PrintTypesEnabled' ifAbsent: [ true ].	
	AbtXmlConfiguration current propertyNamed: 'DefaultResourceQualifier'.
	AbtXmlConfiguration current  defaultResourceQualifier.	
 
	AbtXmlConfiguration current addProperty: 'VAST' named: 'MyCustomProperty'.
	AbtXmlConfiguration current propertyNamed: 'MyCustomProperty'.
 
Note:
Each time the image is started, the AbtXmlConfiguration is refreshed so that resources set via the addProperty:named: must be redeclared.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]