org.apache.hivemind.sdl
Class SDLResourceParser

java.lang.Object
  |
  +--org.apache.hivemind.sdl.SDLResourceParser

public class SDLResourceParser
extends java.lang.Object

Wrapper around SimpleDataLanguageParser (which is generated code). Parses resources that contained Simple Data Language - a language inspired by XML, but rationalized for storing hiearachical data (a frequent application of XML, even though XML is better suited for rich document markup than storing of data). SDL is isomorphic to a subset of XML: It has equivalents for XML elements, XML attributes, and parsable character data (text within an element), but does not support processing instructions, namespaces, internal or external entities, doctype, etc.

Author:
Howard Lewis Ship

Constructor Summary
SDLResourceParser()
           
 
Method Summary
 void parseResource(Resource resource, org.xml.sax.ContentHandler handler)
          Parses the resource, passing SAX parse events to the handler.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SDLResourceParser

public SDLResourceParser()
Method Detail

parseResource

public void parseResource(Resource resource,
                          org.xml.sax.ContentHandler handler)
                   throws org.xml.sax.SAXParseException,
                          java.io.IOException
Parses the resource, passing SAX parse events to the handler. SDL does not (at this time) support namespaces or other constructs of XML, so only the following methods of ContentHandler will be invoked:

At some future point, SDL may support more XML-like things, including names spaces.

org.xml.sax.SAXParseException
java.io.IOException