standup.joke
Class JokeGraphEdge

java.lang.Object
  extended by standup.joke.JokeGraphEdge
All Implemented Interfaces:
XMLizable

public class JokeGraphEdge
extends Object
implements XMLizable

An edge in a JokeGraph. These edges represent lexical precondition predicates defined in Schemas or output specification function Clauses.

Author:
Ruli Manurung

Field Summary
private  String fromNodeId
           
private  String label
           
private  String sourceLabel
           
private  SourceProcess sourceProcess
           
private  String toNodeId
           
 
Constructor Summary
JokeGraphEdge(String _l, String _f, String _t, SourceProcess _sp, String _sl)
           
 
Method Summary
 boolean equals(Object obj)
           
 String getFromNodeLabel()
           
 String getLabel()
           
 String getSourceLabel()
           
 SourceProcess getSourceProcess()
           
 String getToNodeLabel()
           
 int hashCode()
           
static JokeGraphEdge readXML(Element e)
           
 String toString()
           
 void writeXML(Writer out, String indent)
          This method writes the necessary information contained within an instance to an XML file.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

label

private final String label

sourceLabel

private final String sourceLabel

sourceProcess

private final SourceProcess sourceProcess

fromNodeId

private final String fromNodeId

toNodeId

private final String toNodeId
Constructor Detail

JokeGraphEdge

public JokeGraphEdge(String _l,
                     String _f,
                     String _t,
                     SourceProcess _sp,
                     String _sl)
Method Detail

getLabel

public String getLabel()

getFromNodeLabel

public String getFromNodeLabel()

getToNodeLabel

public String getToNodeLabel()

getSourceLabel

public String getSourceLabel()

getSourceProcess

public SourceProcess getSourceProcess()

writeXML

public void writeXML(Writer out,
                     String indent)
              throws IOException
Description copied from interface: XMLizable
This method writes the necessary information contained within an instance to an XML file.

Specified by:
writeXML in interface XMLizable
Parameters:
out - The output stream for the XML file, which is assumed to be already opened and writable.
indent - A string to be prepended before every line written by this method. If passed appropriate white space, e.g. XMLUtils.xmlIndent, it can be used to control indentation.
Throws:
IOException

readXML

public static JokeGraphEdge readXML(Element e)

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

toString

public String toString()
Overrides:
toString in class Object