to the main page about the tutorial  INTERACTIVE WEB SERVICES WITH JAVA back up next

The XML Class

Template are implemented by the XML class.

An XML object corresponds to an XML fragment possibly containing named gaps.

The XML class offers the following features:

The JWIG system allows elaborate syntactic sugar for these constructions.

A template constant is written as:
[[ <table border="0" cellspacing="0">
     <tr><td align="left">
       <a href=[js]>
         <img border="0" src=""/>
     <tr><td align="left">
  <[rest]> ]]
where js, name, and rest are gaps.

Templates are plugged by writing, for instance:
options = options<[rest=templateOption<[inx=versionInx(contents[i]),
                                        date=versionDate(contents[i])] ];

This is different from JDOM documents in the following ways:

- and different from Servlets in the following ways: