public class LinkedListNode<I>
extends java.lang.Object
| Constructor and Description |
|---|
LinkedListNode(I data)
Constructor LinkedListNode class.
|
LinkedListNode(I data,
LinkedListNode<I> next)
Constructor that for the Node class
|
| Modifier and Type | Method and Description |
|---|---|
I |
getData()
Getter method to obtain a reference to the Object held by the LinkedListNode.
|
LinkedListNode<I> |
getNext()
Getter method to obtain a reference to the next LinkedListNode in the Linked List.
|
void |
setData(I data)
Setter method to set the reference to the Object held by the LinkedListNode.
|
void |
setNext(LinkedListNode<I> next)
Setter method to set the reference to the next LinkedListNode in the Linked List.
|
public LinkedListNode(I data)
null.data - This is the data Object held by the LinkedListNode.public LinkedListNode(I data, LinkedListNode<I> next)
data - This is the data Object held by the Node.next - This is the pointer to the next LinkedListNode in the Linked List.public I getData()
public void setData(I data)
data - The reference to the Object to be held by the LinkedListNode.public LinkedListNode<I> getNext()
public void setNext(LinkedListNode<I> next)
next - The reference to the next LinkedListNode in the Linked List.