com.cra.bnet.error
Class CycleError

java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--java.lang.RuntimeException
                    |
                    +--com.cra.bnet.error.BnetError
                          |
                          +--com.cra.bnet.error.CycleError
All Implemented Interfaces:
Serializable

public class CycleError
extends BnetError

An error that occurs when a cycle-creating edge was added to a Bayesian network.

See Also:
Serialized Form

Constructor Summary
CycleError(BayesianNetwork network, Node source, Node target)
          Creates a new CycleError using the specified network model, source node, and target node.
 
Method Summary
 Node getSource()
          Returns the source node of the cycle-creating edge.
 Node getTarget()
          Returns the target node of the cycle-creating edge.
 
Methods inherited from class com.cra.bnet.error.BnetError
getNetwork
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CycleError

public CycleError(BayesianNetwork network,
                  Node source,
                  Node target)
Creates a new CycleError using the specified network model, source node, and target node.

Parameters:
network - Bayesian network the error occurred in.
source - source node of the cycle-creating edge.
target - target node of the cycle-creating edge.
Method Detail

getSource

public Node getSource()
Returns the source node of the cycle-creating edge.

Returns:
the source node of the cycle-creating edge.

getTarget

public Node getTarget()
Returns the target node of the cycle-creating edge.

Returns:
the target node of the cycle-creating edge.