Class LinkConstraint
- java.lang.Object
-
- com.bayesserver.learning.structure.LinkConstraint
-
public final class LinkConstraint extends Object
Defines a constraint on a link between two nodes during structural learning.
-
-
Constructor Summary
Constructors Constructor Description LinkConstraint(Node a, Node b, LinkConstraintMethod method, LinkConstraintFailureMode failureMode)
Initializes a new instance of theLinkConstraint
class.LinkConstraint(Node a, Node b, Integer temporalOrder, LinkConstraintMethod method, LinkConstraintFailureMode failureMode)
Initializes a new instance of theLinkConstraint
class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Node
getA()
Gets the first node involved in the constraint.Node
getB()
Gets the second node involved in the constraint.LinkConstraintFailureMode
getFailureMode()
Gets the action to take when this link constraint is violated.LinkConstraintMethod
getMethod()
Integer
getTemporalOrder()
Gets the temporal order of the constraint.
-
-
-
Constructor Detail
-
LinkConstraint
public LinkConstraint(Node a, Node b, LinkConstraintMethod method, LinkConstraintFailureMode failureMode)
Initializes a new instance of theLinkConstraint
class.- Parameters:
a
- The first node in the link constraint.b
- The second node in the link constraint.method
- The constraint method.failureMode
- The action taken if the link constraint is violated.- Throws:
NullPointerException
- Raised if either [a] or [b] is null.
-
LinkConstraint
public LinkConstraint(Node a, Node b, Integer temporalOrder, LinkConstraintMethod method, LinkConstraintFailureMode failureMode)
Initializes a new instance of theLinkConstraint
class.- Parameters:
a
- The first node in the link constraint.b
- The second node in the link constraint.temporalOrder
- The order of the temporal link constraint (temporal nodes only).method
- The constraint method.failureMode
- The action taken if the link constraint is violated.- Throws:
NullPointerException
- Raised if either [a] or [b] is null.
-
-
Method Detail
-
getA
public Node getA()
Gets the first node involved in the constraint. The type of constraint is defined using thegetMethod()
.- See Also:
getMethod()
-
getB
public Node getB()
Gets the second node involved in the constraint. The type of constraint is defined using thegetMethod()
.- See Also:
getMethod()
-
getTemporalOrder
public Integer getTemporalOrder()
Gets the temporal order of the constraint. Used for temporal links such as those found in time series and sequence networks (Dynamic Bayesian networks).
-
getMethod
public LinkConstraintMethod getMethod()
-
getFailureMode
public LinkConstraintFailureMode getFailureMode()
Gets the action to take when this link constraint is violated.
-
-