Sample: SubstitutionGroup
Author: Rashmi Banthia (rjain29@gmail.com)
Last Updated: Oct. 6th, 2004
Versions:
xmlbeans-1.0.3
-----------------------------------------------------------------------------
This sample illustrates substitution group elements in an XML document.
When you run this sample, you'll see it print substitution group element names and values.
Also it creates a new XML document to demonstrate how to write substitution group elements.
For example, for the following schema and XML fragment:
Sample ship comment
Sample comment
It will print:
--------------
ship-comment
Sample ship comment
comment
Sample comment
Also it will write the following fragment to a XML document:
Sample bill comment
To try out this sample:
1. Set XMLBEANS_HOME in your environment
2. Ant must be on your PATH
3. To compile the schemas and sample source, run "ant build"
4. To execute the sample, run "ant run"