/* * Node code provided for P6 * Same as code shown in class, except * that Account instances are the items to be stored. * July 29, 2015 */ public class Node { private Account item; private Node next; public Node(Account item) { this.item = item; this.next = null; } public Node(Account item, Node next) { this.item = item; this.next = next; } public void setNext(Node nextNode) { next = nextNode; } public Node getNext() { return next; } public Account getItem() { return item; } public void setItem(Account item){ this.item = item; } public String toString(){ return item.toString(); } }