org.oXML.engine
Class CompilationContext

java.lang.Object
  extended byorg.oXML.engine.CompilationContext

public class CompilationContext
extends java.lang.Object

represents the context in which an xml document is being compiled


Field Summary
protected static DocumentMapping docMapping
           
protected static TemplateMapping elementMapping
           
protected  Parser mixedparser
           
protected static Template noTemplate
           
static java.lang.String OXML_NS
           
protected  Parser parser
           
 
Constructor Summary
CompilationContext(Program program)
           
 
Method Summary
 void addType(Type type)
           
 boolean attributeSubstitution()
           
 void attributeSubstitution(boolean evaluate)
           
 Template compile(org.w3c.dom.Node node)
           
 Expression evaluate(java.lang.String mixed)
           
 Template getBody(org.w3c.dom.Node node)
           
protected  org.w3c.dom.Document getDocument(java.net.URL url)
           
 ProgramTemplate getProgramTemplate()
           
 Resolver getResolver(org.w3c.dom.Node ctxt)
           
 java.lang.String getSystemId()
           
protected  Template getTemplate(org.w3c.dom.Node node)
           
 Type getType(Name name)
           
 boolean ignoreComments()
           
 void ignoreComments(boolean ignore)
           
 boolean ignoreWhitespace()
           
 void ignoreWhitespace(boolean ignore)
           
 Template importURL(java.net.URL url)
           
 void init()
           
 Expression parse(java.lang.String expr)
          parse a ObjectBox expression
 void setMapping(Name name, TemplateMapping mapping)
           
 void setProgramTemplate(ProgramTemplate program)
           
 boolean textSubstitution()
           
 void textSubstitution(boolean evaluate)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

parser

protected Parser parser

mixedparser

protected Parser mixedparser

OXML_NS

public static final java.lang.String OXML_NS
See Also:
Constant Field Values

noTemplate

protected static final Template noTemplate

elementMapping

protected static final TemplateMapping elementMapping

docMapping

protected static final DocumentMapping docMapping
Constructor Detail

CompilationContext

public CompilationContext(Program program)
Method Detail

ignoreComments

public void ignoreComments(boolean ignore)

ignoreComments

public boolean ignoreComments()

ignoreWhitespace

public void ignoreWhitespace(boolean ignore)

ignoreWhitespace

public boolean ignoreWhitespace()

attributeSubstitution

public boolean attributeSubstitution()

attributeSubstitution

public void attributeSubstitution(boolean evaluate)

textSubstitution

public boolean textSubstitution()

textSubstitution

public void textSubstitution(boolean evaluate)

init

public void init()

getProgramTemplate

public ProgramTemplate getProgramTemplate()

setProgramTemplate

public void setProgramTemplate(ProgramTemplate program)
                        throws ObjectBoxException
Throws:
ObjectBoxException

getSystemId

public java.lang.String getSystemId()

getType

public Type getType(Name name)
             throws ObjectBoxException
Throws:
ObjectBoxException

addType

public void addType(Type type)
             throws ObjectBoxException
Throws:
ObjectBoxException

setMapping

public void setMapping(Name name,
                       TemplateMapping mapping)

getResolver

public Resolver getResolver(org.w3c.dom.Node ctxt)

compile

public Template compile(org.w3c.dom.Node node)
                 throws ObjectBoxException
Throws:
ObjectBoxException

getTemplate

protected Template getTemplate(org.w3c.dom.Node node)
                        throws ObjectBoxException
Throws:
ObjectBoxException

getBody

public Template getBody(org.w3c.dom.Node node)
                 throws ObjectBoxException
Throws:
ObjectBoxException

parse

public Expression parse(java.lang.String expr)
                 throws ObjectBoxException
parse a ObjectBox expression

Throws:
ObjectBoxException

evaluate

public Expression evaluate(java.lang.String mixed)
                    throws ObjectBoxException
Throws:
ObjectBoxException

importURL

public Template importURL(java.net.URL url)
                   throws ObjectBoxException,
                          org.xml.sax.SAXException,
                          java.io.IOException
Throws:
ObjectBoxException
org.xml.sax.SAXException
java.io.IOException

getDocument

protected org.w3c.dom.Document getDocument(java.net.URL url)
                                    throws org.xml.sax.SAXException,
                                           java.io.IOException
Throws:
org.xml.sax.SAXException
java.io.IOException