/** * This method allows an element that is sent in to be added to the queue. * * @param element The element to be added */ public void enqueue(T element) { LinearNode<T> node = new LinearNode<T>(element); if (isEmpty()) { head = node; } else { tail.setNext(node); } tail = node; count++; }