net.sf.colle.xml
Class SystemMapper

java.lang.Object
  extended bynet.sf.colle.xml.SystemMapper

public class SystemMapper
extends Object

Maps objects and lists of objects into a DOM document. Created: 26 Sep 2001

Version:
$Revision: 1.3 $, $Date: 2004/06/04 05:52:54 $
Author:
Jeremy Miller

Method Summary
static SystemMapper getInstance()
          Returns the system mapper singleton.
 void map(org.jdom.Element pxParent, String psName, Object pxObject, Set pxPaths)
          Maps the object into a DOM document.
 void mapCollection(org.jdom.Element pxParent, String psName, Collection pxCollection, Set pxPaths)
          Maps the collection into a DOM document.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static final SystemMapper getInstance()
Returns the system mapper singleton.


mapCollection

public final void mapCollection(org.jdom.Element pxParent,
                                String psName,
                                Collection pxCollection,
                                Set pxPaths)
Maps the collection into a DOM document. This special method exists so a collection of objects can be mapped directly as children of the parent. If mapObject was called with a Collection, the collection object itself would be mapped as a seperate element.

Parameters:
pxParent - parent element to add new elements onto
psName - name the first element tag should be called
pxCollection - collection being mapped
pxPaths - paths to each explicitly requested object

map

public final void map(org.jdom.Element pxParent,
                      String psName,
                      Object pxObject,
                      Set pxPaths)
Maps the object into a DOM document.

Parameters:
pxParent - parent element to add new elements onto
psName - name the top element tag should be called
pxObject - object being mapped
pxPaths - paths to each explicitly requested object