JML

org.jmlspecs.samples.digraph
Class SearchableNode

java.lang.Object
  extended byorg.jmlspecs.samples.digraph.ValueNode
      extended byorg.jmlspecs.samples.digraph.SearchableNode
All Implemented Interfaces:
Cloneable, JMLType, NodeType, Serializable

public class SearchableNode
extends ValueNode

Nodes for searchable graphs.

Author:
Katie Becker, Gary T. Leavens

Field Summary
private  Color color
           
private  int discoverTime
           
private  int finishTime
           
private  SearchableNode predecessor
           
 
Fields inherited from class org.jmlspecs.samples.digraph.ValueNode
value
 
Constructor Summary
  SearchableNode(Object v)
           
protected SearchableNode(Object v, int dT, int fT, SearchableNode pred, Color c)
           
 
Method Summary
protected  String className()
           
 Object clone()
          Return a clone of this object.
 boolean equals(Object o)
          Test whether this object's value is equal to the given argument.
 Color getColor()
           
 int getDiscoverTime()
           
 int getFinishTime()
           
 SearchableNode getPredecessor()
           
 int hashCode()
          Return a hash code for this object.
protected  void setColor(Color c)
           
protected  void setDiscoverTime(int dTime)
           
protected  void setFinishTime(int fTime)
           
protected  void setPredecessor(SearchableNode p)
           
 String toString()
           
 
Methods inherited from class org.jmlspecs.samples.digraph.ValueNode
getValue, setValue
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

discoverTime

private int discoverTime

finishTime

private int finishTime

predecessor

private SearchableNode predecessor

color

private Color color
Constructor Detail

SearchableNode

public SearchableNode(Object v)

SearchableNode

protected SearchableNode(Object v,
                         int dT,
                         int fT,
                         SearchableNode pred,
                         Color c)
Method Detail

equals

public boolean equals(Object o)
Description copied from interface: JMLType
Test whether this object's value is equal to the given argument.

Specified by:
equals in interface NodeType
Overrides:
equals in class ValueNode

hashCode

public int hashCode()
Description copied from interface: JMLType
Return a hash code for this object.

Specified by:
hashCode in interface NodeType
Overrides:
hashCode in class ValueNode

clone

public Object clone()
Description copied from interface: JMLType
Return a clone of this object.

Specified by:
clone in interface NodeType
Overrides:
clone in class ValueNode

setColor

protected void setColor(Color c)

getColor

public Color getColor()

setPredecessor

protected void setPredecessor(SearchableNode p)

getPredecessor

public SearchableNode getPredecessor()

setFinishTime

protected void setFinishTime(int fTime)

getFinishTime

public int getFinishTime()

setDiscoverTime

protected void setDiscoverTime(int dTime)

getDiscoverTime

public int getDiscoverTime()

className

protected String className()

toString

public String toString()
Overrides:
toString in class ValueNode

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.