agg.parser
Class SimpleExcludeParser

java.lang.Object
  extended by agg.parser.AbstractParser
      extended by agg.parser.ExcludeParser
          extended by agg.parser.SimpleExcludeParser
All Implemented Interfaces:
Parser, java.lang.Runnable

public class SimpleExcludeParser
extends ExcludeParser

This class provides a parser which needs critical pairs. The critical pair must be ExcludePair. So objects has to be instanciated with ExcludePairContainer. To be independent of a grammar it is necessary to instanciate an object with a host graph and stop graph seperately.


Field Summary
 
Fields inherited from class agg.parser.ExcludeParser
correct, stack, stop
 
Fields inherited from class agg.parser.AbstractParser
delay, grammar, graph, listener, pairContainer, stopGraph
 
Constructor Summary
SimpleExcludeParser(GraGra grammar, Graph hostGraph, Graph stopGraph, ExcludePairContainer excludeContainer)
          Creates a new parser that is a little bit simpler than a ExcludeParser.
 
Method Summary
 boolean parse()
          Starts the parser.
 
Methods inherited from class agg.parser.ExcludeParser
finalize, findInclusions, isMatchCritic, makeLightContainer, run, stop, wasStopped
 
Methods inherited from class agg.parser.AbstractParser
addParserEventListener, applyRule, findMatch, findMatch, fireParserEvent, getGraph, getHostGraph, getStopGraph, parseString, printGraph, printImageGraph, removeParserEventListener, setCriticalPairs, setDelayAfterApplyRule, setGrammar, setHostGraph, setStopGraph
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SimpleExcludeParser

public SimpleExcludeParser(GraGra grammar,
                           Graph hostGraph,
                           Graph stopGraph,
                           ExcludePairContainer excludeContainer)
Creates a new parser that is a little bit simpler than a ExcludeParser.

Parameters:
grammar - The graph grammar.
hostGraph - The host graph.
stopGraph - The stop graph.
excludeContainer - The critical pairs.
Method Detail

parse

public boolean parse()
Starts the parser.

Specified by:
parse in interface Parser
Overrides:
parse in class ExcludeParser
Returns:
true if the graph can be parsed.