JavaDoc


JbListElement

org.dbreplicator.graph
Class JbListElement

java.lang.Object
  extended by org.dbreplicator.graph.JbListElement

public class JbListElement
extends java.lang.Object

Instances of this class act as elements of a linked list. It is used for keeping JbVertex-instances and JbEdge-instances in order.

  • The collision management strategy of the hash table,
  • the general vertex list of the graph,
  • and the edges of a single vertex
are all kept in a linked list of of JbListElement instances.


Field Summary
 java.lang.Object hangingVertexOrEdge
          A link to the actual object represented by this "hanger" instance.
 JbListElement next
          A link to the next element in the linked list.
 
Constructor Summary
JbListElement()
          The null constructor gets called when we initialize the hash table.
JbListElement(java.lang.Object objToHang)
          The list element is a general linked list element.
 
Method Summary
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

next

public JbListElement next
A link to the next element in the linked list.


hangingVertexOrEdge

public java.lang.Object hangingVertexOrEdge
A link to the actual object represented by this "hanger" instance. Usually an instance of JbVertex or JbEdge.

Constructor Detail

JbListElement

public JbListElement()
The null constructor gets called when we initialize the hash table. We attach null- containing-list elements to each hash index, for ease of coding. (If you want to understand why this is important, try to visualize the return value of the method findVertex without guarantee that each index in the hash table will have at least one JbListElement...)


JbListElement

public JbListElement(java.lang.Object objToHang)
The list element is a general linked list element. It contains a link to the next element, and a hanger for the vertex or the edge that it represents.

Parameters:
objToHang - The object that we wish to "hang" in this list element, usually an instance of JbVertex or JbEdge
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object



Powered by Drupal - Theme by Danger4k