interpreter
Class Signification

java.lang.Object
  extended by interpreter.Signification

public class Signification
extends java.lang.Object

Version:
1.0, 2006-06-06
Author:
Baris Ulucinar, Dominik Zindel (Universitad da Friburg, Svizra)

Constructor Summary
Signification()
           
 
Method Summary
protected  TTLNodeRule firstmatch(java.util.ArrayList<TTLNodeRule> rules, XMLNode currentNode)
          Gets the first matching rule.
private  java.util.ArrayList<XMLNode> mApplication(TTLApplication a, Context c)
          mApplication selects the appropriate pattern
private  XMLAttribute mAttrNode(TTLAttrNode anode, Context c)
          MAttrNode takes an attributeNode and creates an attribute
private  XMLNode mCopy(TTLCopy x, Context c)
          Copy the content
private  XMLElement mElmtNode(TTLElmtNode enode, Context c)
          Handles the element node.
private  java.util.ArrayList<XMLNode> mItem(TTLItem i, Context c)
          Develops the items
private  java.util.ArrayList<XMLNode> mNodeRule(TTLNodeRule r, Context c)
          mNodeRule, for the recursion
private  java.util.ArrayList<XMLNode> mPattern(TTLPattern p, Context c)
          Find the matching pattern
 XMLDocument mProgram(TTLProgram p, XMLDocument d)
          Starts the process, returns the Document
private  java.util.ArrayList<XMLNode> mSelection(TTLSelection s, java.util.ArrayList<XMLNode> nodes)
          mSelection applies mStepExpression if !mSelection.EMPTY
private  java.util.ArrayList<XMLNode> mStepExpr(TTLStepExpr s, java.util.ArrayList<XMLNode> nodes)
          Handles a StepExpression
private  java.lang.String mStringExpr(TTLStringExpr expr, Context c)
          Get the string value.
private  java.util.ArrayList<XMLNode> mTemplate(TTLTemplate t, Context initContext)
          Applies the Template.
private  XMLText mTextNode(TTLTextNode tnode, Context c)
          Get the text of a node
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Signification

public Signification()
Method Detail

mProgram

public XMLDocument mProgram(TTLProgram p,
                            XMLDocument d)
Starts the process, returns the Document

Parameters:
p - TTLProgram
d - Input-Document
Returns:
Document

mTemplate

private java.util.ArrayList<XMLNode> mTemplate(TTLTemplate t,
                                               Context initContext)
Applies the Template.

Parameters:
t - Template
initContext - Context
Returns:
List of XMLNodes

mItem

private java.util.ArrayList<XMLNode> mItem(TTLItem i,
                                           Context c)
Develops the items

Parameters:
i - Item
c - Context
Returns:
List of XMLNodes

mApplication

private java.util.ArrayList<XMLNode> mApplication(TTLApplication a,
                                                  Context c)
mApplication selects the appropriate pattern

Parameters:
a -
c - Context
Returns:
List of XMLNodes

mPattern

private java.util.ArrayList<XMLNode> mPattern(TTLPattern p,
                                              Context c)
Find the matching pattern

Parameters:
p - TTLPattern
c - Context
Returns:
ArrayList of XMLNodes

mNodeRule

private java.util.ArrayList<XMLNode> mNodeRule(TTLNodeRule r,
                                               Context c)
mNodeRule, for the recursion

Parameters:
r - TTLNodeRule
c - Context
Returns:
ArrayList containing XMLNodes

firstmatch

protected TTLNodeRule firstmatch(java.util.ArrayList<TTLNodeRule> rules,
                                 XMLNode currentNode)
Gets the first matching rule.

Parameters:
rules - ArrayList of TTLNodeRules
currentNode - Current Node
Returns:
TTLNodeRule

mSelection

private java.util.ArrayList<XMLNode> mSelection(TTLSelection s,
                                                java.util.ArrayList<XMLNode> nodes)
mSelection applies mStepExpression if !mSelection.EMPTY

Parameters:
s - TTLSelection
nodes -
Returns:
List of XMLNodes

mStepExpr

private java.util.ArrayList<XMLNode> mStepExpr(TTLStepExpr s,
                                               java.util.ArrayList<XMLNode> nodes)
Handles a StepExpression

Parameters:
s - TTLStepExpression
nodes - ArrayList of XMLNodes
Returns:
ArrayList of XMLNode

mCopy

private XMLNode mCopy(TTLCopy x,
                      Context c)
Copy the content

Parameters:
x - TTLCopy-Element
c - context
Returns:
XMLNode

mTextNode

private XMLText mTextNode(TTLTextNode tnode,
                          Context c)
Get the text of a node

Parameters:
tnode - TextNode
c - Context
Returns:
XMLText

mElmtNode

private XMLElement mElmtNode(TTLElmtNode enode,
                             Context c)
Handles the element node.

Parameters:
enode - TTLElementNode
c - Context
Returns:
XMLElement

mAttrNode

private XMLAttribute mAttrNode(TTLAttrNode anode,
                               Context c)
MAttrNode takes an attributeNode and creates an attribute

Parameters:
anode - Attribute Node
c - Context
Returns:
XMLAttribute

mStringExpr

private java.lang.String mStringExpr(TTLStringExpr expr,
                                     Context c)
Get the string value.

Parameters:
expr - TTLStringExpression
c - Context
Returns:
String