|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.ksu.cis.bnj.bbn.converter.spo.SPOParser
This format is courtesy of Dr. Alexander Dekhtyar, Zhao Wenzhong, and Judy Goldsmith of University of Kentucky
Current version: We assume that ALL probability distributions and ALL values are explicitly mentioned. The only exception is that we may omit the nodes with no parents. In this case, we assume uniform distribution across the values assuming that ALL values are mentioned.
Field Summary | |
protected java.util.Hashtable |
cptCache
|
protected BBNGraph |
graph
|
protected static java.lang.String |
ln
|
protected java.util.Hashtable |
nodeCache
|
protected TableSet |
parentsCache
|
protected TableSet |
parentValuesCache
|
protected static java.lang.String |
SPODTD
|
protected TableSet |
valueCache
|
Constructor Summary | |
SPOParser()
|
Method Summary | |
protected BBNNode |
createNode(java.lang.String name)
Create a node with the specified name if the node hasn't been created before. |
protected java.lang.String |
getElementValue(org.w3c.dom.Node parent)
|
void |
initialize()
|
BBNGraph |
load(java.io.InputStream stream)
|
static void |
main(java.lang.String[] args)
Driver for testing this parser |
protected java.lang.String |
processNode(BBNNode node,
java.util.Hashtable parentValues,
int counter)
|
protected void |
processNode(BBNNode node,
java.util.LinkedList parents,
java.util.Hashtable curParentValues,
java.lang.StringBuffer buf)
|
protected java.lang.String |
processNode(BBNNode node,
java.util.List parents)
|
void |
save(java.io.OutputStream stream,
BBNGraph graph)
This routine is supposed to save the BBN Graph into SPO format. |
protected java.util.List |
visitConditional(org.w3c.dom.Node parent,
java.util.Hashtable condTable)
|
protected void |
visitDocument(org.w3c.dom.Node parent)
|
protected void |
visitDynamicPropertyXML(org.w3c.dom.Node parent,
java.util.Hashtable prop,
java.lang.String prefix)
|
protected void |
visitElem(org.w3c.dom.Node parent,
java.util.Hashtable elemTable)
|
protected void |
visitRows(org.w3c.dom.Node parent,
java.lang.String var,
java.util.Hashtable probTable)
|
protected void |
visitSPO(org.w3c.dom.Node parent)
|
protected void |
visitTable(org.w3c.dom.Node parent,
java.util.List parentNodes,
java.util.Hashtable parentTable)
|
protected java.util.List |
visitVariables(org.w3c.dom.Node parent)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected BBNGraph graph
protected java.util.Hashtable nodeCache
protected TableSet valueCache
protected TableSet parentsCache
protected TableSet parentValuesCache
protected java.util.Hashtable cptCache
protected static java.lang.String ln
protected static java.lang.String SPODTD
Constructor Detail |
public SPOParser()
Method Detail |
public void initialize()
initialize
in interface Converter
Converter.initialize()
public void save(java.io.OutputStream stream, BBNGraph graph)
save
in interface Converter
edu.ksu.cis.bnj.bbn.converter.Converter#save(java.io.Writer, edu.ksu.cis.bnj.bbn.BBNGraph)
protected java.lang.String processNode(BBNNode node, java.util.Hashtable parentValues, int counter)
protected java.lang.String processNode(BBNNode node, java.util.List parents)
protected void processNode(BBNNode node, java.util.LinkedList parents, java.util.Hashtable curParentValues, java.lang.StringBuffer buf)
public BBNGraph load(java.io.InputStream stream)
load
in interface Converter
edu.ksu.cis.bnj.bbn.converter.Converter#load(java.io.Reader)
protected void visitDocument(org.w3c.dom.Node parent)
protected void visitSPO(org.w3c.dom.Node parent)
protected void visitTable(org.w3c.dom.Node parent, java.util.List parentNodes, java.util.Hashtable parentTable)
protected java.util.List visitConditional(org.w3c.dom.Node parent, java.util.Hashtable condTable)
protected void visitElem(org.w3c.dom.Node parent, java.util.Hashtable elemTable)
protected java.util.List visitVariables(org.w3c.dom.Node parent)
protected void visitRows(org.w3c.dom.Node parent, java.lang.String var, java.util.Hashtable probTable)
protected BBNNode createNode(java.lang.String name)
name
- protected java.lang.String getElementValue(org.w3c.dom.Node parent)
protected void visitDynamicPropertyXML(org.w3c.dom.Node parent, java.util.Hashtable prop, java.lang.String prefix)
public static void main(java.lang.String[] args)
args
-
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |