public abstract class SyntaxGraph extends java.lang.Object implements LabeledStructure, java.util.Observer
Modifier and Type | Field and Description |
---|---|
protected ObjectPoolList<LabelSet> |
labelSetPool |
protected int |
numberOfComponents |
protected SymbolTableHandler |
symbolTables |
Constructor and Description |
---|
SyntaxGraph(SymbolTableHandler symbolTables) |
Modifier and Type | Method and Description |
---|---|
void |
addLabel(Element element,
java.lang.String labelFunction,
java.lang.String label)
Adds a label label to the graph element element
|
void |
checkInLabelSet(LabelSet labelSet)
Checks in a label set.
|
LabelSet |
checkOutNewLabelSet()
Checks out a new label set from the structure.
|
void |
clear()
Resets the structure.
|
SymbolTableHandler |
getSymbolTables()
Returns the symbol table handler.
|
void |
setSymbolTables(SymbolTableHandler symbolTables)
Sets the symbol table handler.
|
protected SymbolTableHandler symbolTables
protected final ObjectPoolList<LabelSet> labelSetPool
protected int numberOfComponents
public SyntaxGraph(SymbolTableHandler symbolTables) throws MaltChainedException
MaltChainedException
public SymbolTableHandler getSymbolTables()
LabeledStructure
getSymbolTables
in interface LabeledStructure
public void setSymbolTables(SymbolTableHandler symbolTables)
LabeledStructure
setSymbolTables
in interface LabeledStructure
symbolTables
- a symbol table handler.public void addLabel(Element element, java.lang.String labelFunction, java.lang.String label) throws MaltChainedException
LabeledStructure
addLabel
in interface LabeledStructure
element
- a graph element element (a node or a edge).labelFunction
- the name of the symbol table.label
- the string value of the label.MaltChainedException
public LabelSet checkOutNewLabelSet() throws MaltChainedException
LabeledStructure
checkOutNewLabelSet
in interface LabeledStructure
MaltChainedException
public void checkInLabelSet(LabelSet labelSet) throws MaltChainedException
LabeledStructure
checkInLabelSet
in interface LabeledStructure
labelSet
- a label set.MaltChainedException
public void clear() throws MaltChainedException
LabeledStructure
clear
in interface LabeledStructure
MaltChainedException
Copyright 2007-2017 Johan Hall, Jens Nilsson and Joakim Nivre.