Package edu.cmu.tetrad.data
Class KnowledgeEdge
java.lang.Object
edu.cmu.tetrad.data.KnowledgeEdge
- All Implemented Interfaces:
TetradSerializable,Serializable
Implements a knowledge edge X-->Y as a simple ordered pair of strings.
- Version:
- $Id: $Id
- Author:
- josephramsey
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionKnowledgeEdge(String from, String to) Constructs a knowledge edge for from-->to. -
Method Summary
Modifier and TypeMethodDescriptionbooleangetFrom()Getter for the fieldfrom.getTo()Getter for the fieldto.inthashCode()hashCode.static KnowledgeEdgeGenerates a simple exemplar of this class to test serialization.toString()toString.
-
Constructor Details
-
Method Details
-
serializableInstance
Generates a simple exemplar of this class to test serialization.- Returns:
- a
KnowledgeEdgeobject
-
getFrom
Getter for the field
from.- Returns:
- the tail node of the edge.
-
getTo
Getter for the field
to.- Returns:
- the head node of the edge.
-
equals
Reteurns true if (from1, to1) == (from2, to2).
-
hashCode
public int hashCode()hashCode.
-
toString
toString.
-