introExam.LinkedList
Class LL.LLNode

java.lang.Object
  extended byintroExam.LinkedList.LL.LLNode
Enclosing class:
LL

protected class LL.LLNode
extends java.lang.Object


Field Summary
 LL.LLNode next
           
 java.lang.Comparable value
          Note final access modifier: cannot be changed! As a result, there is no setter for value.
 
Constructor Summary
LL.LLNode(java.lang.Comparable value)
          Constructor builds the LLNode with the supplied parameter; it is followed by an empty list.
LL.LLNode(java.lang.Comparable value, LL.LLNode next)
          Constructor builds the LLNode with the supplied parameters.
 
Method Summary
 LL.LLNode getNext()
          Returns reference to the next LLNode
 java.lang.Comparable getValue()
          Returns reference to the value of the object.
 void setNext(LL.LLNode newNode)
          Sets the next reference of this object to the paramter object
 java.lang.String toString()
          Returns string representation of the object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

value

public final java.lang.Comparable value
Note final access modifier: cannot be changed! As a result, there is no setter for value.


next

public LL.LLNode next
Constructor Detail

LL.LLNode

public LL.LLNode(java.lang.Comparable value)
Constructor builds the LLNode with the supplied parameter; it is followed by an empty list.

Parameters:
value - to store in this node

LL.LLNode

public LL.LLNode(java.lang.Comparable value,
                 LL.LLNode next)
Constructor builds the LLNode with the supplied parameters.

Parameters:
value - to store in this node
next - must refer to the list that follows it
Method Detail

getNext

public LL.LLNode getNext()
Returns reference to the next LLNode

Returns:
next reference

setNext

public void setNext(LL.LLNode newNode)
Sets the next reference of this object to the paramter object

Parameters:
newNode - which is an object of the class LLNode

getValue

public java.lang.Comparable getValue()
Returns reference to the value of the object.

Returns:
reference to the value

toString

public java.lang.String toString()
Returns string representation of the object

Returns:
String reference