INRIA & FluxMedia

fr.fluxmedia.transmorpher.parser
Class ProcessParser

java.lang.Object
  |
  +--org.xml.sax.helpers.DefaultHandler
        |
        +--fr.fluxmedia.transmorpher.parser.FMParser
              |
              +--fr.fluxmedia.transmorpher.parser.ProcessParser
All Implemented Interfaces:
org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler

public class ProcessParser
extends FMParser


Field Summary
protected  Call currentCall
           
protected  Iterator currentIterator
           
protected  java.lang.String currentParam
           
protected  Parameters currentParams
           
protected  fr.fluxmedia.transmorpher.graph.Rules.ModTag currentRule
           
protected  Transformation currentTransformation
           
protected  Transmorpher currentTransmorpher
           
protected  java.lang.String currentWParam
           
protected  java.util.Hashtable imports
           
(package private)  boolean inLitteralXSLT
          Are we copying some XSLT
(package private)  boolean inQuery
           
(package private)  boolean inRuleSet
           
protected  java.lang.Object[] observers
           
(package private)  QueryParser queryParser
           
protected  fr.fluxmedia.transmorpher.graph.Rules.Rule rule
           
(package private)  RuleSetParser ruleSetParser
           
protected  java.lang.String tmp
           
protected  java.util.Stack tStack
           
protected  java.lang.String uri
           
 
Fields inherited from class fr.fluxmedia.transmorpher.parser.FMParser
debugMode, iContext, iParser, output
 
Constructor Summary
ProcessParser(int debug_mode)
          The constructor, build the XML PArser but do not parse the document
ProcessParser(int debug_mode, java.lang.Object[] observers)
           
 
Method Summary
static java.lang.String[] AnalysePortNames(java.lang.String pListe)
          Analyze the port Name attributes
 void characters(char[] ch, int start, int length)
           
 void checkChannels(Process t)
           
protected  void cleanStack()
          Reset the parameters as they were after taking care of a Call
 void endElement(java.lang.String namespaceURI, java.lang.String pName, java.lang.String qName)
          Call by the XML parser at the end of an element
protected  void fixBuf(Transformation t, PortList bufList, PortList inList, java.lang.String[] portNames, int expected)
           
protected  void fixInPorts(Call c, PortList list, java.lang.String[] portNames, int expected, java.lang.String type)
           
protected  void fixInPorts(Transformation t, PortList list, java.lang.String[] portNames)
           
protected  void fixOutBuf(Repeat r, PortList list, java.lang.String[] portNames, int expected)
           
protected  void fixOutPorts(Call c, PortList list, java.lang.String[] portNames, int expected, java.lang.String type)
           
protected  void fixOutPorts(Transformation t, PortList list, java.lang.String[] portNames)
           
 java.lang.String listAttribute(org.xml.sax.Attributes atts)
          Returns a XML-attribute string from the result of such a string
 Transmorpher Newparse(java.lang.String u)
          Parse the document given in parameter: Same this as FMParser but with Transmorpher
 void registerChannelIn(PortList list, boolean Callp)
          Register a channel with its input
 void registerChannelOut(PortList list, boolean Callp)
          Register a channel with its output
 void setEndQuery()
           
 void setEndRuleSet()
           
 void startElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qname, org.xml.sax.Attributes atts)
          Call by the XML parser at the begining of an element
 
Methods inherited from class fr.fluxmedia.transmorpher.parser.FMParser
error, fatalError, warning
 
Methods inherited from class org.xml.sax.helpers.DefaultHandler
endDocument, endPrefixMapping, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

uri

protected java.lang.String uri

tmp

protected java.lang.String tmp

currentTransmorpher

protected Transmorpher currentTransmorpher

currentTransformation

protected Transformation currentTransformation

currentCall

protected Call currentCall

currentRule

protected fr.fluxmedia.transmorpher.graph.Rules.ModTag currentRule

rule

protected fr.fluxmedia.transmorpher.graph.Rules.Rule rule

currentParam

protected java.lang.String currentParam

currentWParam

protected java.lang.String currentWParam

currentIterator

protected Iterator currentIterator

currentParams

protected Parameters currentParams

imports

protected java.util.Hashtable imports

tStack

protected java.util.Stack tStack

observers

protected java.lang.Object[] observers

ruleSetParser

RuleSetParser ruleSetParser

queryParser

QueryParser queryParser

inLitteralXSLT

boolean inLitteralXSLT
Are we copying some XSLT

inRuleSet

boolean inRuleSet

inQuery

boolean inQuery
Constructor Detail

ProcessParser

public ProcessParser(int debug_mode)
              throws javax.xml.parsers.ParserConfigurationException,
                     org.xml.sax.SAXException
The constructor, build the XML PArser but do not parse the document

ProcessParser

public ProcessParser(int debug_mode,
                     java.lang.Object[] observers)
              throws javax.xml.parsers.ParserConfigurationException,
                     org.xml.sax.SAXException
Method Detail

Newparse

public Transmorpher Newparse(java.lang.String u)
                      throws org.xml.sax.SAXException,
                             java.io.IOException
Parse the document given in parameter: Same this as FMParser but with Transmorpher
Overrides:
Newparse in class FMParser

startElement

public void startElement(java.lang.String namespaceURI,
                         java.lang.String localName,
                         java.lang.String qname,
                         org.xml.sax.Attributes atts)
Call by the XML parser at the begining of an element
Overrides:
startElement in class org.xml.sax.helpers.DefaultHandler

characters

public void characters(char[] ch,
                       int start,
                       int length)
Overrides:
characters in class org.xml.sax.helpers.DefaultHandler

setEndRuleSet

public void setEndRuleSet()

setEndQuery

public void setEndQuery()

endElement

public void endElement(java.lang.String namespaceURI,
                       java.lang.String pName,
                       java.lang.String qName)
Call by the XML parser at the end of an element
Overrides:
endElement in class org.xml.sax.helpers.DefaultHandler

fixInPorts

protected void fixInPorts(Transformation t,
                          PortList list,
                          java.lang.String[] portNames)

fixOutPorts

protected void fixOutPorts(Transformation t,
                           PortList list,
                           java.lang.String[] portNames)

fixBuf

protected void fixBuf(Transformation t,
                      PortList bufList,
                      PortList inList,
                      java.lang.String[] portNames,
                      int expected)

fixOutBuf

protected void fixOutBuf(Repeat r,
                         PortList list,
                         java.lang.String[] portNames,
                         int expected)

fixInPorts

protected void fixInPorts(Call c,
                          PortList list,
                          java.lang.String[] portNames,
                          int expected,
                          java.lang.String type)

fixOutPorts

protected void fixOutPorts(Call c,
                           PortList list,
                           java.lang.String[] portNames,
                           int expected,
                           java.lang.String type)

checkChannels

public void checkChannels(Process t)

registerChannelIn

public void registerChannelIn(PortList list,
                              boolean Callp)
Register a channel with its input

registerChannelOut

public void registerChannelOut(PortList list,
                               boolean Callp)
Register a channel with its output

AnalysePortNames

public static java.lang.String[] AnalysePortNames(java.lang.String pListe)
Analyze the port Name attributes

cleanStack

protected void cleanStack()
Reset the parameters as they were after taking care of a Call

listAttribute

public java.lang.String listAttribute(org.xml.sax.Attributes atts)
Returns a XML-attribute string from the result of such a string

INRIA & FluxMedia

..no bottom yet...