|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectRBNinference.BNNode
public class BNNode
Field Summary | |
---|---|
java.util.LinkedList |
children
|
protected int |
depth
|
int |
instantiated
|
java.lang.String |
name
|
java.util.LinkedList |
parents
|
Constructor Summary | |
---|---|
BNNode()
Creates new BNNode |
|
BNNode(java.lang.String n)
|
|
BNNode(java.lang.String n,
int val)
|
|
BNNode(java.lang.String n,
java.util.LinkedList par,
java.util.LinkedList chil)
|
Method Summary | |
---|---|
void |
addToChildren(BNNode newchild)
Adds newchild to children if not in children list already |
void |
addToParents(BNNode newpar)
|
java.util.Vector |
buildNodeStack()
|
int |
depth()
|
double |
familyXcenter()
Computes the mean of the (current) xcoords of parents and children. |
void |
instantiate(int truthval)
|
int |
instantiatedTo()
|
boolean |
parentsSubset(BNNode bnn)
returns true if this.parents is subset of bnn.parents |
void |
replaceInChildrenList(BNNode oldchil,
BNNode newchil)
|
void |
replaceInParentList(BNNode oldpar,
BNNode newpar)
|
void |
resetParents()
|
void |
resetVisited(int ind)
|
void |
resetVisitedUpDownstream(int ind)
|
void |
resetVisitedUpstream(int ind)
|
void |
setDepth(int d)
|
void |
showAllReachable()
Prints names of all nodes connected to this one |
int |
sizeFamily()
|
static double |
xSum(java.util.Collection<BNNode> bnnodes)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public java.lang.String name
public java.util.LinkedList parents
public java.util.LinkedList children
public int instantiated
protected int depth
Constructor Detail |
---|
public BNNode()
public BNNode(java.lang.String n)
public BNNode(java.lang.String n, int val)
public BNNode(java.lang.String n, java.util.LinkedList par, java.util.LinkedList chil)
Method Detail |
---|
public void addToChildren(BNNode newchild)
public void addToParents(BNNode newpar)
public java.util.Vector buildNodeStack()
public int depth()
public void instantiate(int truthval)
public int instantiatedTo()
public void resetParents()
public void replaceInParentList(BNNode oldpar, BNNode newpar)
public void replaceInChildrenList(BNNode oldchil, BNNode newchil)
public void resetVisited(int ind)
public void resetVisitedUpstream(int ind)
public void resetVisitedUpDownstream(int ind)
public void setDepth(int d)
public void showAllReachable()
public boolean parentsSubset(BNNode bnn)
public int sizeFamily()
public double familyXcenter()
public static double xSum(java.util.Collection<BNNode> bnnodes)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |