Code example for ListIterator

Methods: addprevious

        // method call re-enables remove and add 
        if (validForUpdate == false) {
            throw new IllegalStateException("Cannot add to list until next() or previous() called");
        validForUpdate = false;
     * Resets the iterator back to the start (which is the 
     * end of the list as this is a reversed iterator) 
    public void reset() { 
        iterator = list.listIterator(list.size());
Connect your IDE to all the code out there  Get Codota for Java