15.95/5.25 YES 16.25/5.28 proof of /export/starexec/sandbox/benchmark/theBenchmark.jar 16.25/5.28 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 16.25/5.28 16.25/5.28 16.25/5.28 termination of the given Bare JBC problem could be proven: 16.25/5.28 16.25/5.28 (0) Bare JBC problem 16.25/5.28 (1) BareJBCToJBCProof [EQUIVALENT, 96 ms] 16.25/5.28 (2) JBC problem 16.25/5.28 (3) JBCToGraph [EQUIVALENT, 2257 ms] 16.25/5.28 (4) JBCTerminationGraph 16.25/5.28 (5) TerminationGraphToSCCProof [SOUND, 0 ms] 16.25/5.28 (6) JBCTerminationSCC 16.25/5.28 (7) SCCToIRSProof [SOUND, 399 ms] 16.25/5.28 (8) IRSwT 16.25/5.28 (9) IRSFormatTransformerProof [EQUIVALENT, 0 ms] 16.25/5.28 (10) IRSwT 16.25/5.28 (11) IRSwTTerminationDigraphProof [EQUIVALENT, 125 ms] 16.25/5.28 (12) IRSwT 16.25/5.28 (13) IntTRSCompressionProof [EQUIVALENT, 0 ms] 16.25/5.28 (14) IRSwT 16.25/5.28 (15) TempFilterProof [SOUND, 105 ms] 16.25/5.28 (16) IntTRS 16.25/5.28 (17) PolynomialOrderProcessor [EQUIVALENT, 20 ms] 16.25/5.28 (18) IntTRS 16.25/5.28 (19) PolynomialOrderProcessor [EQUIVALENT, 0 ms] 16.25/5.28 (20) YES 16.25/5.28 16.25/5.28 16.25/5.28 ---------------------------------------- 16.25/5.28 16.25/5.28 (0) 16.25/5.28 Obligation: 16.25/5.28 need to prove termination of the following program: 16.25/5.28 /* 16.25/5.28 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.28 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.28 * 16.25/5.28 * This code is free software; you can redistribute it and/or modify it 16.25/5.28 * under the terms of the GNU General Public License version 2 only, as 16.25/5.28 * published by the Free Software Foundation. Sun designates this 16.25/5.28 * particular file as subject to the "Classpath" exception as provided 16.25/5.28 * by Sun in the LICENSE file that accompanied this code. 16.25/5.28 * 16.25/5.28 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.28 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.28 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.28 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.28 * accompanied this code). 16.25/5.28 * 16.25/5.28 * You should have received a copy of the GNU General Public License version 16.25/5.28 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.28 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.28 * 16.25/5.28 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.28 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.28 * have any questions. 16.25/5.28 */ 16.25/5.28 16.25/5.28 package javaUtilEx; 16.25/5.28 16.25/5.28 /** 16.25/5.28 * This class provides a skeletal implementation of the Collection 16.25/5.28 * interface, to minimize the effort required to implement this interface.

16.25/5.28 * 16.25/5.28 * To implement an unmodifiable collection, the programmer needs only to 16.25/5.28 * extend this class and provide implementations for the iterator and 16.25/5.28 * size methods. (The iterator returned by the iterator 16.25/5.28 * method must implement hasNext and next.)

16.25/5.28 * 16.25/5.28 * To implement a modifiable collection, the programmer must additionally 16.25/5.28 * override this class's add method (which otherwise throws an 16.25/5.28 * UnsupportedOperationException), and the iterator returned by the 16.25/5.28 * iterator method must additionally implement its remove 16.25/5.28 * method.

16.25/5.28 * 16.25/5.28 * The programmer should generally provide a void (no argument) and 16.25/5.28 * Collection constructor, as per the recommendation in the 16.25/5.28 * Collection interface specification.

16.25/5.28 * 16.25/5.28 * The documentation for each non-abstract method in this class describes its 16.25/5.28 * implementation in detail. Each of these methods may be overridden if 16.25/5.28 * the collection being implemented admits a more efficient implementation.

16.25/5.28 * 16.25/5.28 * This class is a member of the 16.25/5.28 * 16.25/5.28 * Java Collections Framework. 16.25/5.28 * 16.25/5.28 * @author Josh Bloch 16.25/5.28 * @author Neal Gafter 16.25/5.28 * @see Collection 16.25/5.28 * @since 1.2 16.25/5.28 */ 16.25/5.28 16.25/5.28 public abstract class AbstractCollection implements Collection { 16.25/5.28 /** 16.25/5.28 * Sole constructor. (For invocation by subclass constructors, typically 16.25/5.28 * implicit.) 16.25/5.28 */ 16.25/5.28 protected AbstractCollection() { 16.25/5.28 } 16.25/5.28 16.25/5.28 // Query Operations 16.25/5.28 16.25/5.28 /** 16.25/5.28 * Returns an iterator over the elements contained in this collection. 16.25/5.28 * 16.25/5.28 * @return an iterator over the elements contained in this collection 16.25/5.28 */ 16.25/5.28 public abstract Iterator iterator(); 16.25/5.28 16.25/5.28 public abstract int size(); 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation returns size() == 0. 16.25/5.28 */ 16.25/5.28 public boolean isEmpty() { 16.25/5.28 return size() == 0; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over the elements in the collection, 16.25/5.28 * checking each element in turn for equality with the specified element. 16.25/5.28 * 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public boolean contains(Object o) { 16.25/5.28 Iterator e = iterator(); 16.25/5.28 if (o==null) { 16.25/5.28 while (e.hasNext()) 16.25/5.28 if (e.next()==null) 16.25/5.28 return true; 16.25/5.28 } else { 16.25/5.28 while (e.hasNext()) 16.25/5.28 if (o.equals(e.next())) 16.25/5.28 return true; 16.25/5.28 } 16.25/5.28 return false; 16.25/5.28 } 16.25/5.28 16.25/5.28 // Modification Operations 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation always throws an 16.25/5.28 * UnsupportedOperationException. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.28 * @throws IllegalStateException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public boolean add(E e) { 16.25/5.28 throw new UnsupportedOperationException(); 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over the collection looking for the 16.25/5.28 * specified element. If it finds the element, it removes the element 16.25/5.28 * from the collection using the iterator's remove method. 16.25/5.28 * 16.25/5.28 *

Note that this implementation throws an 16.25/5.28 * UnsupportedOperationException if the iterator returned by this 16.25/5.28 * collection's iterator method does not implement the remove 16.25/5.28 * method and this collection contains the specified object. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public boolean remove(Object o) { 16.25/5.28 Iterator e = iterator(); 16.25/5.28 if (o==null) { 16.25/5.28 while (e.hasNext()) { 16.25/5.28 if (e.next()==null) { 16.25/5.28 e.remove(); 16.25/5.28 return true; 16.25/5.28 } 16.25/5.28 } 16.25/5.28 } else { 16.25/5.28 while (e.hasNext()) { 16.25/5.28 if (o.equals(e.next())) { 16.25/5.28 e.remove(); 16.25/5.28 return true; 16.25/5.28 } 16.25/5.28 } 16.25/5.28 } 16.25/5.28 return false; 16.25/5.28 } 16.25/5.28 16.25/5.28 16.25/5.28 // Bulk Operations 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over the specified collection, 16.25/5.28 * checking each element returned by the iterator in turn to see 16.25/5.28 * if it's contained in this collection. If all elements are so 16.25/5.28 * contained true is returned, otherwise false. 16.25/5.28 * 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * @see #contains(Object) 16.25/5.28 */ 16.25/5.28 public boolean containsAll(Collection c) { 16.25/5.28 Iterator e = c.iterator(); 16.25/5.28 while (e.hasNext()) 16.25/5.28 if (!contains(e.next())) 16.25/5.28 return false; 16.25/5.28 return true; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over the specified collection, and adds 16.25/5.28 * each object returned by the iterator to this collection, in turn. 16.25/5.28 * 16.25/5.28 *

Note that this implementation will throw an 16.25/5.28 * UnsupportedOperationException unless add is 16.25/5.28 * overridden (assuming the specified collection is non-empty). 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.28 * @throws IllegalStateException {@inheritDoc} 16.25/5.28 * 16.25/5.28 * @see #add(Object) 16.25/5.28 */ 16.25/5.28 public boolean addAll(Collection c) { 16.25/5.28 boolean modified = false; 16.25/5.28 Iterator e = c.iterator(); 16.25/5.28 while (e.hasNext()) { 16.25/5.28 if (add(e.next())) 16.25/5.28 modified = true; 16.25/5.28 } 16.25/5.28 return modified; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over this collection, checking each 16.25/5.28 * element returned by the iterator in turn to see if it's contained 16.25/5.28 * in the specified collection. If it's so contained, it's removed from 16.25/5.28 * this collection with the iterator's remove method. 16.25/5.28 * 16.25/5.28 *

Note that this implementation will throw an 16.25/5.28 * UnsupportedOperationException if the iterator returned by the 16.25/5.28 * iterator method does not implement the remove method 16.25/5.28 * and this collection contains one or more elements in common with the 16.25/5.28 * specified collection. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * 16.25/5.28 * @see #remove(Object) 16.25/5.28 * @see #contains(Object) 16.25/5.28 */ 16.25/5.28 public boolean removeAll(Collection c) { 16.25/5.28 boolean modified = false; 16.25/5.28 Iterator e = iterator(); 16.25/5.28 while (e.hasNext()) { 16.25/5.28 if (c.contains(e.next())) { 16.25/5.28 e.remove(); 16.25/5.28 modified = true; 16.25/5.28 } 16.25/5.28 } 16.25/5.28 return modified; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over this collection, checking each 16.25/5.28 * element returned by the iterator in turn to see if it's contained 16.25/5.28 * in the specified collection. If it's not so contained, it's removed 16.25/5.28 * from this collection with the iterator's remove method. 16.25/5.28 * 16.25/5.28 *

Note that this implementation will throw an 16.25/5.28 * UnsupportedOperationException if the iterator returned by the 16.25/5.28 * iterator method does not implement the remove method 16.25/5.28 * and this collection contains one or more elements not present in the 16.25/5.28 * specified collection. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * 16.25/5.28 * @see #remove(Object) 16.25/5.28 * @see #contains(Object) 16.25/5.28 */ 16.25/5.28 public boolean retainAll(Collection c) { 16.25/5.28 boolean modified = false; 16.25/5.28 Iterator e = iterator(); 16.25/5.28 while (e.hasNext()) { 16.25/5.28 if (!c.contains(e.next())) { 16.25/5.28 e.remove(); 16.25/5.28 modified = true; 16.25/5.28 } 16.25/5.28 } 16.25/5.28 return modified; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation iterates over this collection, removing each 16.25/5.28 * element using the Iterator.remove operation. Most 16.25/5.28 * implementations will probably choose to override this method for 16.25/5.28 * efficiency. 16.25/5.28 * 16.25/5.28 *

Note that this implementation will throw an 16.25/5.28 * UnsupportedOperationException if the iterator returned by this 16.25/5.28 * collection's iterator method does not implement the 16.25/5.28 * remove method and this collection is non-empty. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public void clear() { 16.25/5.28 Iterator e = iterator(); 16.25/5.28 while (e.hasNext()) { 16.25/5.28 e.next(); 16.25/5.28 e.remove(); 16.25/5.28 } 16.25/5.28 } 16.25/5.28 16.25/5.28 16.25/5.28 // String conversion 16.25/5.28 16.25/5.28 /** 16.25/5.28 * Returns a string representation of this collection. The string 16.25/5.28 * representation consists of a list of the collection's elements in the 16.25/5.28 * order they are returned by its iterator, enclosed in square brackets 16.25/5.28 * ("[]"). Adjacent elements are separated by the characters 16.25/5.28 * ", " (comma and space). Elements are converted to strings as 16.25/5.28 * by {@link String#valueOf(Object)}. 16.25/5.28 * 16.25/5.28 * @return a string representation of this collection 16.25/5.28 */ 16.25/5.28 public String toString() { 16.25/5.28 Iterator i = iterator(); 16.25/5.28 if (! i.hasNext()) 16.25/5.28 return "[]"; 16.25/5.28 16.25/5.28 String sb = ""; 16.25/5.28 sb = sb + "["; 16.25/5.28 for (;;) { 16.25/5.28 E e = i.next(); 16.25/5.28 sb = sb + (e == this ? "(this Collection)" : e); 16.25/5.28 if (! i.hasNext()) { 16.25/5.28 sb = sb + "]"; 16.25/5.28 return sb; 16.25/5.28 } 16.25/5.28 sb = sb + ", "; 16.25/5.28 } 16.25/5.28 } 16.25/5.28 16.25/5.28 } 16.25/5.28 16.25/5.28 16.25/5.28 /* 16.25/5.28 * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.28 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.28 * 16.25/5.28 * This code is free software; you can redistribute it and/or modify it 16.25/5.28 * under the terms of the GNU General Public License version 2 only, as 16.25/5.28 * published by the Free Software Foundation. Sun designates this 16.25/5.28 * particular file as subject to the "Classpath" exception as provided 16.25/5.28 * by Sun in the LICENSE file that accompanied this code. 16.25/5.28 * 16.25/5.28 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.28 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.28 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.28 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.28 * accompanied this code). 16.25/5.28 * 16.25/5.28 * You should have received a copy of the GNU General Public License version 16.25/5.28 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.28 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.28 * 16.25/5.28 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.28 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.28 * have any questions. 16.25/5.28 */ 16.25/5.28 16.25/5.28 package javaUtilEx; 16.25/5.28 16.25/5.28 /** 16.25/5.28 * This class provides a skeletal implementation of the {@link List} 16.25/5.28 * interface to minimize the effort required to implement this interface 16.25/5.28 * backed by a "random access" data store (such as an array). For sequential 16.25/5.28 * access data (such as a linked list), {@link AbstractSequentialList} should 16.25/5.28 * be used in preference to this class. 16.25/5.28 * 16.25/5.28 *

To implement an unmodifiable list, the programmer needs only to extend 16.25/5.28 * this class and provide implementations for the {@link #get(int)} and 16.25/5.28 * {@link List#size() size()} methods. 16.25/5.28 * 16.25/5.28 *

To implement a modifiable list, the programmer must additionally 16.25/5.28 * override the {@link #set(int, Object) set(int, E)} method (which otherwise 16.25/5.28 * throws an {@code UnsupportedOperationException}). If the list is 16.25/5.28 * variable-size the programmer must additionally override the 16.25/5.28 * {@link #add(int, Object) add(int, E)} and {@link #remove(int)} methods. 16.25/5.28 * 16.25/5.28 *

The programmer should generally provide a void (no argument) and collection 16.25/5.28 * constructor, as per the recommendation in the {@link Collection} interface 16.25/5.28 * specification. 16.25/5.28 * 16.25/5.28 *

Unlike the other abstract collection implementations, the programmer does 16.25/5.28 * not have to provide an iterator implementation; the iterator and 16.25/5.28 * list iterator are implemented by this class, on top of the "random access" 16.25/5.28 * methods: 16.25/5.28 * {@link #get(int)}, 16.25/5.28 * {@link #set(int, Object) set(int, E)}, 16.25/5.28 * {@link #add(int, Object) add(int, E)} and 16.25/5.28 * {@link #remove(int)}. 16.25/5.28 * 16.25/5.28 *

The documentation for each non-abstract method in this class describes its 16.25/5.28 * implementation in detail. Each of these methods may be overridden if the 16.25/5.28 * collection being implemented admits a more efficient implementation. 16.25/5.28 * 16.25/5.28 *

This class is a member of the 16.25/5.28 * 16.25/5.28 * Java Collections Framework. 16.25/5.28 * 16.25/5.28 * @author Josh Bloch 16.25/5.28 * @author Neal Gafter 16.25/5.28 * @since 1.2 16.25/5.28 */ 16.25/5.28 16.25/5.28 public abstract class AbstractList extends AbstractCollection implements List { 16.25/5.28 /** 16.25/5.28 * Sole constructor. (For invocation by subclass constructors, typically 16.25/5.28 * implicit.) 16.25/5.28 */ 16.25/5.28 protected AbstractList() { 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * Appends the specified element to the end of this list (optional 16.25/5.28 * operation). 16.25/5.28 * 16.25/5.28 *

Lists that support this operation may place limitations on what 16.25/5.28 * elements may be added to this list. In particular, some 16.25/5.28 * lists will refuse to add null elements, and others will impose 16.25/5.28 * restrictions on the type of elements that may be added. List 16.25/5.28 * classes should clearly specify in their documentation any restrictions 16.25/5.28 * on what elements may be added. 16.25/5.28 * 16.25/5.28 *

This implementation calls {@code add(size(), e)}. 16.25/5.28 * 16.25/5.28 *

Note that this implementation throws an 16.25/5.28 * {@code UnsupportedOperationException} unless 16.25/5.28 * {@link #add(int, Object) add(int, E)} is overridden. 16.25/5.28 * 16.25/5.28 * @param e element to be appended to this list 16.25/5.28 * @return {@code true} (as specified by {@link Collection#add}) 16.25/5.28 * @throws UnsupportedOperationException if the {@code add} operation 16.25/5.28 * is not supported by this list 16.25/5.28 * @throws ClassCastException if the class of the specified element 16.25/5.28 * prevents it from being added to this list 16.25/5.28 * @throws NullPointerException if the specified element is null and this 16.25/5.28 * list does not permit null elements 16.25/5.28 * @throws IllegalArgumentException if some property of this element 16.25/5.28 * prevents it from being added to this list 16.25/5.28 */ 16.25/5.28 public boolean add(E e) { 16.25/5.28 add(size(), e); 16.25/5.28 return true; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 abstract public E get(int index); 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation always throws an 16.25/5.28 * {@code UnsupportedOperationException}. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.28 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public E set(int index, E element) { 16.25/5.28 throw new UnsupportedOperationException(); 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation always throws an 16.25/5.28 * {@code UnsupportedOperationException}. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.28 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public void add(int index, E element) { 16.25/5.28 throw new UnsupportedOperationException(); 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation always throws an 16.25/5.28 * {@code UnsupportedOperationException}. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public E remove(int index) { 16.25/5.28 throw new UnsupportedOperationException(); 16.25/5.28 } 16.25/5.28 16.25/5.28 16.25/5.28 // Search Operations 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation first gets a list iterator (with 16.25/5.28 * {@code listIterator()}). Then, it iterates over the list until the 16.25/5.28 * specified element is found or the end of the list is reached. 16.25/5.28 * 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public int indexOf(Object o) { 16.25/5.28 ListIterator e = listIterator(); 16.25/5.28 if (o==null) { 16.25/5.28 while (e.hasNext()) 16.25/5.28 if (e.next()==null) 16.25/5.28 return e.previousIndex(); 16.25/5.28 } else { 16.25/5.28 while (e.hasNext()) 16.25/5.28 if (o.equals(e.next())) 16.25/5.28 return e.previousIndex(); 16.25/5.28 } 16.25/5.28 return -1; 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation first gets a list iterator that points to the end 16.25/5.28 * of the list (with {@code listIterator(size())}). Then, it iterates 16.25/5.28 * backwards over the list until the specified element is found, or the 16.25/5.28 * beginning of the list is reached. 16.25/5.28 * 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public int lastIndexOf(Object o) { 16.25/5.28 ListIterator e = listIterator(size()); 16.25/5.28 if (o==null) { 16.25/5.28 while (e.hasPrevious()) 16.25/5.28 if (e.previous()==null) 16.25/5.28 return e.nextIndex(); 16.25/5.28 } else { 16.25/5.28 while (e.hasPrevious()) 16.25/5.28 if (o.equals(e.previous())) 16.25/5.28 return e.nextIndex(); 16.25/5.28 } 16.25/5.28 return -1; 16.25/5.28 } 16.25/5.28 16.25/5.28 16.25/5.28 // Bulk Operations 16.25/5.28 16.25/5.28 /** 16.25/5.28 * Removes all of the elements from this list (optional operation). 16.25/5.28 * The list will be empty after this call returns. 16.25/5.28 * 16.25/5.28 *

This implementation calls {@code removeRange(0, size())}. 16.25/5.28 * 16.25/5.28 *

Note that this implementation throws an 16.25/5.28 * {@code UnsupportedOperationException} unless {@code remove(int 16.25/5.28 * index)} or {@code removeRange(int fromIndex, int toIndex)} is 16.25/5.28 * overridden. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException if the {@code clear} operation 16.25/5.28 * is not supported by this list 16.25/5.28 */ 16.25/5.28 public void clear() { 16.25/5.28 removeRange(0, size()); 16.25/5.28 } 16.25/5.28 16.25/5.28 /** 16.25/5.28 * {@inheritDoc} 16.25/5.28 * 16.25/5.28 *

This implementation gets an iterator over the specified collection 16.25/5.28 * and iterates over it, inserting the elements obtained from the 16.25/5.28 * iterator into this list at the appropriate position, one at a time, 16.25/5.28 * using {@code add(int, E)}. 16.25/5.28 * Many implementations will override this method for efficiency. 16.25/5.28 * 16.25/5.28 *

Note that this implementation throws an 16.25/5.28 * {@code UnsupportedOperationException} unless 16.25/5.28 * {@link #add(int, Object) add(int, E)} is overridden. 16.25/5.28 * 16.25/5.28 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.28 * @throws ClassCastException {@inheritDoc} 16.25/5.28 * @throws NullPointerException {@inheritDoc} 16.25/5.28 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.28 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.28 */ 16.25/5.28 public boolean addAll(int index, Collection c) { 16.25/5.28 rangeCheckForAdd(index); 16.25/5.28 boolean modified = false; 16.25/5.28 Iterator e = c.iterator(); 16.25/5.28 while (e.hasNext()) { 16.25/5.28 add(index++, e.next()); 16.25/5.28 modified = true; 16.25/5.28 } 16.25/5.28 return modified; 16.25/5.28 } 16.25/5.28 16.25/5.28 16.25/5.28 // Iterators 16.25/5.28 16.25/5.28 /** 16.25/5.28 * Returns an iterator over the elements in this list in proper sequence. 16.25/5.28 * 16.25/5.28 *

This implementation returns a straightforward implementation of the 16.25/5.29 * iterator interface, relying on the backing list's {@code size()}, 16.25/5.29 * {@code get(int)}, and {@code remove(int)} methods. 16.25/5.29 * 16.25/5.29 *

Note that the iterator returned by this method will throw an 16.25/5.29 * {@link UnsupportedOperationException} in response to its 16.25/5.29 * {@code remove} method unless the list's {@code remove(int)} method is 16.25/5.29 * overridden. 16.25/5.29 * 16.25/5.29 *

This implementation can be made to throw runtime exceptions in the 16.25/5.29 * face of concurrent modification, as described in the specification 16.25/5.29 * for the (protected) {@link #modCount} field. 16.25/5.29 * 16.25/5.29 * @return an iterator over the elements in this list in proper sequence 16.25/5.29 */ 16.25/5.29 public Iterator iterator() { 16.25/5.29 return new Itr(); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * {@inheritDoc} 16.25/5.29 * 16.25/5.29 *

This implementation returns {@code listIterator(0)}. 16.25/5.29 * 16.25/5.29 * @see #listIterator(int) 16.25/5.29 */ 16.25/5.29 public ListIterator listIterator() { 16.25/5.29 return listIterator(0); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * {@inheritDoc} 16.25/5.29 * 16.25/5.29 *

This implementation returns a straightforward implementation of the 16.25/5.29 * {@code ListIterator} interface that extends the implementation of the 16.25/5.29 * {@code Iterator} interface returned by the {@code iterator()} method. 16.25/5.29 * The {@code ListIterator} implementation relies on the backing list's 16.25/5.29 * {@code get(int)}, {@code set(int, E)}, {@code add(int, E)} 16.25/5.29 * and {@code remove(int)} methods. 16.25/5.29 * 16.25/5.29 *

Note that the list iterator returned by this implementation will 16.25/5.29 * throw an {@link UnsupportedOperationException} in response to its 16.25/5.29 * {@code remove}, {@code set} and {@code add} methods unless the 16.25/5.29 * list's {@code remove(int)}, {@code set(int, E)}, and 16.25/5.29 * {@code add(int, E)} methods are overridden. 16.25/5.29 * 16.25/5.29 *

This implementation can be made to throw runtime exceptions in the 16.25/5.29 * face of concurrent modification, as described in the specification for 16.25/5.29 * the (protected) {@link #modCount} field. 16.25/5.29 * 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public ListIterator listIterator(final int index) { 16.25/5.29 rangeCheckForAdd(index); 16.25/5.29 16.25/5.29 return new ListItr(index); 16.25/5.29 } 16.25/5.29 16.25/5.29 private class Itr implements Iterator { 16.25/5.29 /** 16.25/5.29 * Index of element to be returned by subsequent call to next. 16.25/5.29 */ 16.25/5.29 int cursor = 0; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Index of element returned by most recent call to next or 16.25/5.29 * previous. Reset to -1 if this element is deleted by a call 16.25/5.29 * to remove. 16.25/5.29 */ 16.25/5.29 int lastRet = -1; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * The modCount value that the iterator believes that the backing 16.25/5.29 * List should have. If this expectation is violated, the iterator 16.25/5.29 * has detected concurrent modification. 16.25/5.29 */ 16.25/5.29 int expectedModCount = modCount; 16.25/5.29 16.25/5.29 public boolean hasNext() { 16.25/5.29 return cursor != size(); 16.25/5.29 } 16.25/5.29 16.25/5.29 public E next() { 16.25/5.29 checkForComodification(); 16.25/5.29 try { 16.25/5.29 int i = cursor; 16.25/5.29 E next = get(i); 16.25/5.29 lastRet = i; 16.25/5.29 cursor = i + 1; 16.25/5.29 return next; 16.25/5.29 } catch (IndexOutOfBoundsException e) { 16.25/5.29 checkForComodification(); 16.25/5.29 throw new NoSuchElementException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 public void remove() { 16.25/5.29 if (lastRet < 0) 16.25/5.29 throw new IllegalStateException(); 16.25/5.29 checkForComodification(); 16.25/5.29 16.25/5.29 try { 16.25/5.29 AbstractList.this.remove(lastRet); 16.25/5.29 if (lastRet < cursor) 16.25/5.29 cursor--; 16.25/5.29 lastRet = -1; 16.25/5.29 expectedModCount = modCount; 16.25/5.29 } catch (IndexOutOfBoundsException e) { 16.25/5.29 throw new ConcurrentModificationException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 final void checkForComodification() { 16.25/5.29 if (modCount != expectedModCount) 16.25/5.29 throw new ConcurrentModificationException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 private class ListItr extends Itr implements ListIterator { 16.25/5.29 ListItr(int index) { 16.25/5.29 cursor = index; 16.25/5.29 } 16.25/5.29 16.25/5.29 public boolean hasPrevious() { 16.25/5.29 return cursor != 0; 16.25/5.29 } 16.25/5.29 16.25/5.29 public E previous() { 16.25/5.29 checkForComodification(); 16.25/5.29 try { 16.25/5.29 int i = cursor - 1; 16.25/5.29 E previous = get(i); 16.25/5.29 lastRet = cursor = i; 16.25/5.29 return previous; 16.25/5.29 } catch (IndexOutOfBoundsException e) { 16.25/5.29 checkForComodification(); 16.25/5.29 throw new NoSuchElementException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 public int nextIndex() { 16.25/5.29 return cursor; 16.25/5.29 } 16.25/5.29 16.25/5.29 public int previousIndex() { 16.25/5.29 return cursor-1; 16.25/5.29 } 16.25/5.29 16.25/5.29 public void set(E e) { 16.25/5.29 if (lastRet < 0) 16.25/5.29 throw new IllegalStateException(); 16.25/5.29 checkForComodification(); 16.25/5.29 16.25/5.29 try { 16.25/5.29 AbstractList.this.set(lastRet, e); 16.25/5.29 expectedModCount = modCount; 16.25/5.29 } catch (IndexOutOfBoundsException ex) { 16.25/5.29 throw new ConcurrentModificationException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 public void add(E e) { 16.25/5.29 checkForComodification(); 16.25/5.29 16.25/5.29 try { 16.25/5.29 int i = cursor; 16.25/5.29 AbstractList.this.add(i, e); 16.25/5.29 lastRet = -1; 16.25/5.29 cursor = i + 1; 16.25/5.29 expectedModCount = modCount; 16.25/5.29 } catch (IndexOutOfBoundsException ex) { 16.25/5.29 throw new ConcurrentModificationException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * {@inheritDoc} 16.25/5.29 * 16.25/5.29 *

This implementation returns a list that subclasses 16.25/5.29 * {@code AbstractList}. The subclass stores, in private fields, the 16.25/5.29 * offset of the subList within the backing list, the size of the subList 16.25/5.29 * (which can change over its lifetime), and the expected 16.25/5.29 * {@code modCount} value of the backing list. There are two variants 16.25/5.29 * of the subclass, one of which implements {@code RandomAccess}. 16.25/5.29 * If this list implements {@code RandomAccess} the returned list will 16.25/5.29 * be an instance of the subclass that implements {@code RandomAccess}. 16.25/5.29 * 16.25/5.29 *

The subclass's {@code set(int, E)}, {@code get(int)}, 16.25/5.29 * {@code add(int, E)}, {@code remove(int)}, {@code addAll(int, 16.25/5.29 * Collection)} and {@code removeRange(int, int)} methods all 16.25/5.29 * delegate to the corresponding methods on the backing abstract list, 16.25/5.29 * after bounds-checking the index and adjusting for the offset. The 16.25/5.29 * {@code addAll(Collection c)} method merely returns {@code addAll(size, 16.25/5.29 * c)}. 16.25/5.29 * 16.25/5.29 *

The {@code listIterator(int)} method returns a "wrapper object" 16.25/5.29 * over a list iterator on the backing list, which is created with the 16.25/5.29 * corresponding method on the backing list. The {@code iterator} method 16.25/5.29 * merely returns {@code listIterator()}, and the {@code size} method 16.25/5.29 * merely returns the subclass's {@code size} field. 16.25/5.29 * 16.25/5.29 *

All methods first check to see if the actual {@code modCount} of 16.25/5.29 * the backing list is equal to its expected value, and throw a 16.25/5.29 * {@code ConcurrentModificationException} if it is not. 16.25/5.29 * 16.25/5.29 * @throws IndexOutOfBoundsException if an endpoint index value is out of range 16.25/5.29 * {@code (fromIndex < 0 || toIndex > size)} 16.25/5.29 * @throws IllegalArgumentException if the endpoint indices are out of order 16.25/5.29 * {@code (fromIndex > toIndex)} 16.25/5.29 */ 16.25/5.29 public List subList(int fromIndex, int toIndex) { 16.25/5.29 return (this instanceof RandomAccess ? 16.25/5.29 new RandomAccessSubList(this, fromIndex, toIndex) : 16.25/5.29 new SubList(this, fromIndex, toIndex)); 16.25/5.29 } 16.25/5.29 16.25/5.29 // Comparison and hashing 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Compares the specified object with this list for equality. Returns 16.25/5.29 * {@code true} if and only if the specified object is also a list, both 16.25/5.29 * lists have the same size, and all corresponding pairs of elements in 16.25/5.29 * the two lists are equal. (Two elements {@code e1} and 16.25/5.29 * {@code e2} are equal if {@code (e1==null ? e2==null : 16.25/5.29 * e1.equals(e2))}.) In other words, two lists are defined to be 16.25/5.29 * equal if they contain the same elements in the same order.

16.25/5.29 * 16.25/5.29 * This implementation first checks if the specified object is this 16.25/5.29 * list. If so, it returns {@code true}; if not, it checks if the 16.25/5.29 * specified object is a list. If not, it returns {@code false}; if so, 16.25/5.29 * it iterates over both lists, comparing corresponding pairs of elements. 16.25/5.29 * If any comparison returns {@code false}, this method returns 16.25/5.29 * {@code false}. If either iterator runs out of elements before the 16.25/5.29 * other it returns {@code false} (as the lists are of unequal length); 16.25/5.29 * otherwise it returns {@code true} when the iterations complete. 16.25/5.29 * 16.25/5.29 * @param o the object to be compared for equality with this list 16.25/5.29 * @return {@code true} if the specified object is equal to this list 16.25/5.29 */ 16.25/5.29 public boolean equals(Object o) { 16.25/5.29 if (o == this) 16.25/5.29 return true; 16.25/5.29 if (!(o instanceof List)) 16.25/5.29 return false; 16.25/5.29 16.25/5.29 ListIterator e1 = listIterator(); 16.25/5.29 ListIterator e2 = ((List) o).listIterator(); 16.25/5.29 while(e1.hasNext() && e2.hasNext()) { 16.25/5.29 E o1 = e1.next(); 16.25/5.29 Object o2 = e2.next(); 16.25/5.29 if (!(o1==null ? o2==null : o1.equals(o2))) 16.25/5.29 return false; 16.25/5.29 } 16.25/5.29 return !(e1.hasNext() || e2.hasNext()); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns the hash code value for this list. 16.25/5.29 * 16.25/5.29 *

This implementation uses exactly the code that is used to define the 16.25/5.29 * list hash function in the documentation for the {@link List#hashCode} 16.25/5.29 * method. 16.25/5.29 * 16.25/5.29 * @return the hash code value for this list 16.25/5.29 */ 16.25/5.29 public int hashCode() { 16.25/5.29 int hashCode = 1; 16.25/5.29 Iterator it = this.iterator(); 16.25/5.29 while (it.hasNext()) { 16.25/5.29 E e = it.next(); 16.25/5.29 hashCode = 31*hashCode + (e==null ? 0 : e.hashCode()); 16.25/5.29 } 16.25/5.29 return hashCode; 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes from this list all of the elements whose index is between 16.25/5.29 * {@code fromIndex}, inclusive, and {@code toIndex}, exclusive. 16.25/5.29 * Shifts any succeeding elements to the left (reduces their index). 16.25/5.29 * This call shortens the list by {@code (toIndex - fromIndex)} elements. 16.25/5.29 * (If {@code toIndex==fromIndex}, this operation has no effect.) 16.25/5.29 * 16.25/5.29 *

This method is called by the {@code clear} operation on this list 16.25/5.29 * and its subLists. Overriding this method to take advantage of 16.25/5.29 * the internals of the list implementation can substantially 16.25/5.29 * improve the performance of the {@code clear} operation on this list 16.25/5.29 * and its subLists. 16.25/5.29 * 16.25/5.29 *

This implementation gets a list iterator positioned before 16.25/5.29 * {@code fromIndex}, and repeatedly calls {@code ListIterator.next} 16.25/5.29 * followed by {@code ListIterator.remove} until the entire range has 16.25/5.29 * been removed. Note: if {@code ListIterator.remove} requires linear 16.25/5.29 * time, this implementation requires quadratic time. 16.25/5.29 * 16.25/5.29 * @param fromIndex index of first element to be removed 16.25/5.29 * @param toIndex index after last element to be removed 16.25/5.29 */ 16.25/5.29 protected void removeRange(int fromIndex, int toIndex) { 16.25/5.29 ListIterator it = listIterator(fromIndex); 16.25/5.29 for (int i=0, n=toIndex-fromIndex; istructurally modified. 16.25/5.29 * Structural modifications are those that change the size of the 16.25/5.29 * list, or otherwise perturb it in such a fashion that iterations in 16.25/5.29 * progress may yield incorrect results. 16.25/5.29 * 16.25/5.29 *

This field is used by the iterator and list iterator implementation 16.25/5.29 * returned by the {@code iterator} and {@code listIterator} methods. 16.25/5.29 * If the value of this field changes unexpectedly, the iterator (or list 16.25/5.29 * iterator) will throw a {@code ConcurrentModificationException} in 16.25/5.29 * response to the {@code next}, {@code remove}, {@code previous}, 16.25/5.29 * {@code set} or {@code add} operations. This provides 16.25/5.29 * fail-fast behavior, rather than non-deterministic behavior in 16.25/5.29 * the face of concurrent modification during iteration. 16.25/5.29 * 16.25/5.29 *

Use of this field by subclasses is optional. If a subclass 16.25/5.29 * wishes to provide fail-fast iterators (and list iterators), then it 16.25/5.29 * merely has to increment this field in its {@code add(int, E)} and 16.25/5.29 * {@code remove(int)} methods (and any other methods that it overrides 16.25/5.29 * that result in structural modifications to the list). A single call to 16.25/5.29 * {@code add(int, E)} or {@code remove(int)} must add no more than 16.25/5.29 * one to this field, or the iterators (and list iterators) will throw 16.25/5.29 * bogus {@code ConcurrentModificationExceptions}. If an implementation 16.25/5.29 * does not wish to provide fail-fast iterators, this field may be 16.25/5.29 * ignored. 16.25/5.29 */ 16.25/5.29 protected transient int modCount = 0; 16.25/5.29 16.25/5.29 private void rangeCheckForAdd(int index) { 16.25/5.29 if (index < 0 || index > size()) 16.25/5.29 throw new IndexOutOfBoundsException(outOfBoundsMsg(index)); 16.25/5.29 } 16.25/5.29 16.25/5.29 private String outOfBoundsMsg(int index) { 16.25/5.29 return ""; 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 class SubList extends AbstractList { 16.25/5.29 private final AbstractList l; 16.25/5.29 private final int offset; 16.25/5.29 private int size; 16.25/5.29 16.25/5.29 SubList(AbstractList list, int fromIndex, int toIndex) { 16.25/5.29 if (fromIndex < 0) 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 if (toIndex > list.size()) 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 if (fromIndex > toIndex) 16.25/5.29 throw new IllegalArgumentException(); 16.25/5.29 l = list; 16.25/5.29 offset = fromIndex; 16.25/5.29 size = toIndex - fromIndex; 16.25/5.29 this.modCount = l.modCount; 16.25/5.29 } 16.25/5.29 16.25/5.29 public E set(int index, E element) { 16.25/5.29 rangeCheck(index); 16.25/5.29 checkForComodification(); 16.25/5.29 return l.set(index+offset, element); 16.25/5.29 } 16.25/5.29 16.25/5.29 public E get(int index) { 16.25/5.29 rangeCheck(index); 16.25/5.29 checkForComodification(); 16.25/5.29 return l.get(index+offset); 16.25/5.29 } 16.25/5.29 16.25/5.29 public int size() { 16.25/5.29 checkForComodification(); 16.25/5.29 return size; 16.25/5.29 } 16.25/5.29 16.25/5.29 public void add(int index, E element) { 16.25/5.29 rangeCheckForAdd(index); 16.25/5.29 checkForComodification(); 16.25/5.29 l.add(index+offset, element); 16.25/5.29 this.modCount = l.modCount; 16.25/5.29 size++; 16.25/5.29 } 16.25/5.29 16.25/5.29 public E remove(int index) { 16.25/5.29 rangeCheck(index); 16.25/5.29 checkForComodification(); 16.25/5.29 E result = l.remove(index+offset); 16.25/5.29 this.modCount = l.modCount; 16.25/5.29 size--; 16.25/5.29 return result; 16.25/5.29 } 16.25/5.29 16.25/5.29 protected void removeRange(int fromIndex, int toIndex) { 16.25/5.29 checkForComodification(); 16.25/5.29 l.removeRange(fromIndex+offset, toIndex+offset); 16.25/5.29 this.modCount = l.modCount; 16.25/5.29 size -= (toIndex-fromIndex); 16.25/5.29 } 16.25/5.29 16.25/5.29 public boolean addAll(Collection c) { 16.25/5.29 return addAll(size, c); 16.25/5.29 } 16.25/5.29 16.25/5.29 public boolean addAll(int index, Collection c) { 16.25/5.29 rangeCheckForAdd(index); 16.25/5.29 int cSize = c.size(); 16.25/5.29 if (cSize==0) 16.25/5.29 return false; 16.25/5.29 16.25/5.29 checkForComodification(); 16.25/5.29 l.addAll(offset+index, c); 16.25/5.29 this.modCount = l.modCount; 16.25/5.29 size += cSize; 16.25/5.29 return true; 16.25/5.29 } 16.25/5.29 16.25/5.29 public Iterator iterator() { 16.25/5.29 return listIterator(); 16.25/5.29 } 16.25/5.29 16.25/5.29 public ListIterator listIterator(final int index) { 16.25/5.29 checkForComodification(); 16.25/5.29 rangeCheckForAdd(index); 16.25/5.29 16.25/5.29 return new ListIterator() { 16.25/5.29 private final ListIterator i = l.listIterator(index+offset); 16.25/5.29 16.25/5.29 public boolean hasNext() { 16.25/5.29 return nextIndex() < size; 16.25/5.29 } 16.25/5.29 16.25/5.29 public E next() { 16.25/5.29 if (hasNext()) 16.25/5.29 return i.next(); 16.25/5.29 else 16.25/5.29 throw new NoSuchElementException(); 16.25/5.29 } 16.25/5.29 16.25/5.29 public boolean hasPrevious() { 16.25/5.29 return previousIndex() >= 0; 16.25/5.29 } 16.25/5.29 16.25/5.29 public E previous() { 16.25/5.29 if (hasPrevious()) 16.25/5.29 return i.previous(); 16.25/5.29 else 16.25/5.29 throw new NoSuchElementException(); 16.25/5.29 } 16.25/5.29 16.25/5.29 public int nextIndex() { 16.25/5.29 return i.nextIndex() - offset; 16.25/5.29 } 16.25/5.29 16.25/5.29 public int previousIndex() { 16.25/5.29 return i.previousIndex() - offset; 16.25/5.29 } 16.25/5.29 16.25/5.29 public void remove() { 16.25/5.29 i.remove(); 16.25/5.29 SubList.this.modCount = l.modCount; 16.25/5.29 size--; 16.25/5.29 } 16.25/5.29 16.25/5.29 public void set(E e) { 16.25/5.29 i.set(e); 16.25/5.29 } 16.25/5.29 16.25/5.29 public void add(E e) { 16.25/5.29 i.add(e); 16.25/5.29 SubList.this.modCount = l.modCount; 16.25/5.29 size++; 16.25/5.29 } 16.25/5.29 }; 16.25/5.29 } 16.25/5.29 16.25/5.29 public List subList(int fromIndex, int toIndex) { 16.25/5.29 return new SubList(this, fromIndex, toIndex); 16.25/5.29 } 16.25/5.29 16.25/5.29 private void rangeCheck(int index) { 16.25/5.29 if (index < 0 || index >= size) 16.25/5.29 throw new IndexOutOfBoundsException(outOfBoundsMsg(index)); 16.25/5.29 } 16.25/5.29 16.25/5.29 private void rangeCheckForAdd(int index) { 16.25/5.29 if (index < 0 || index > size) 16.25/5.29 throw new IndexOutOfBoundsException(outOfBoundsMsg(index)); 16.25/5.29 } 16.25/5.29 16.25/5.29 private String outOfBoundsMsg(int index) { 16.25/5.29 return ""; 16.25/5.29 } 16.25/5.29 16.25/5.29 private void checkForComodification() { 16.25/5.29 if (this.modCount != l.modCount) 16.25/5.29 throw new ConcurrentModificationException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 class RandomAccessSubList extends SubList implements RandomAccess { 16.25/5.29 RandomAccessSubList(AbstractList list, int fromIndex, int toIndex) { 16.25/5.29 super(list, fromIndex, toIndex); 16.25/5.29 } 16.25/5.29 16.25/5.29 public List subList(int fromIndex, int toIndex) { 16.25/5.29 return new RandomAccessSubList(this, fromIndex, toIndex); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * This class provides a skeletal implementation of the List 16.25/5.29 * interface to minimize the effort required to implement this interface 16.25/5.29 * backed by a "sequential access" data store (such as a linked list). For 16.25/5.29 * random access data (such as an array), AbstractList should be used 16.25/5.29 * in preference to this class.

16.25/5.29 * 16.25/5.29 * This class is the opposite of the AbstractList class in the sense 16.25/5.29 * that it implements the "random access" methods (get(int index), 16.25/5.29 * set(int index, E element), add(int index, E element) and 16.25/5.29 * remove(int index)) on top of the list's list iterator, instead of 16.25/5.29 * the other way around.

16.25/5.29 * 16.25/5.29 * To implement a list the programmer needs only to extend this class and 16.25/5.29 * provide implementations for the listIterator and size 16.25/5.29 * methods. For an unmodifiable list, the programmer need only implement the 16.25/5.29 * list iterator's hasNext, next, hasPrevious, 16.25/5.29 * previous and index methods.

16.25/5.29 * 16.25/5.29 * For a modifiable list the programmer should additionally implement the list 16.25/5.29 * iterator's set method. For a variable-size list the programmer 16.25/5.29 * should additionally implement the list iterator's remove and 16.25/5.29 * add methods.

16.25/5.29 * 16.25/5.29 * The programmer should generally provide a void (no argument) and collection 16.25/5.29 * constructor, as per the recommendation in the Collection interface 16.25/5.29 * specification.

16.25/5.29 * 16.25/5.29 * This class is a member of the 16.25/5.29 * 16.25/5.29 * Java Collections Framework. 16.25/5.29 * 16.25/5.29 * @author Josh Bloch 16.25/5.29 * @author Neal Gafter 16.25/5.29 * @see Collection 16.25/5.29 * @see List 16.25/5.29 * @see AbstractList 16.25/5.29 * @see AbstractCollection 16.25/5.29 * @since 1.2 16.25/5.29 */ 16.25/5.29 16.25/5.29 public abstract class AbstractSequentialList extends AbstractList { 16.25/5.29 /** 16.25/5.29 * Sole constructor. (For invocation by subclass constructors, typically 16.25/5.29 * implicit.) 16.25/5.29 */ 16.25/5.29 protected AbstractSequentialList() { 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns the element at the specified position in this list. 16.25/5.29 * 16.25/5.29 *

This implementation first gets a list iterator pointing to the 16.25/5.29 * indexed element (with listIterator(index)). Then, it gets 16.25/5.29 * the element using ListIterator.next and returns it. 16.25/5.29 * 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public E get(int index) { 16.25/5.29 try { 16.25/5.29 return listIterator(index).next(); 16.25/5.29 } catch (NoSuchElementException exc) { 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Replaces the element at the specified position in this list with the 16.25/5.29 * specified element (optional operation). 16.25/5.29 * 16.25/5.29 *

This implementation first gets a list iterator pointing to the 16.25/5.29 * indexed element (with listIterator(index)). Then, it gets 16.25/5.29 * the current element using ListIterator.next and replaces it 16.25/5.29 * with ListIterator.set. 16.25/5.29 * 16.25/5.29 *

Note that this implementation will throw an 16.25/5.29 * UnsupportedOperationException if the list iterator does not 16.25/5.29 * implement the set operation. 16.25/5.29 * 16.25/5.29 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.29 * @throws ClassCastException {@inheritDoc} 16.25/5.29 * @throws NullPointerException {@inheritDoc} 16.25/5.29 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public E set(int index, E element) { 16.25/5.29 try { 16.25/5.29 ListIterator e = listIterator(index); 16.25/5.29 E oldVal = e.next(); 16.25/5.29 e.set(element); 16.25/5.29 return oldVal; 16.25/5.29 } catch (NoSuchElementException exc) { 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts the specified element at the specified position in this list 16.25/5.29 * (optional operation). Shifts the element currently at that position 16.25/5.29 * (if any) and any subsequent elements to the right (adds one to their 16.25/5.29 * indices). 16.25/5.29 * 16.25/5.29 *

This implementation first gets a list iterator pointing to the 16.25/5.29 * indexed element (with listIterator(index)). Then, it 16.25/5.29 * inserts the specified element with ListIterator.add. 16.25/5.29 * 16.25/5.29 *

Note that this implementation will throw an 16.25/5.29 * UnsupportedOperationException if the list iterator does not 16.25/5.29 * implement the add operation. 16.25/5.29 * 16.25/5.29 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.29 * @throws ClassCastException {@inheritDoc} 16.25/5.29 * @throws NullPointerException {@inheritDoc} 16.25/5.29 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public void add(int index, E element) { 16.25/5.29 try { 16.25/5.29 listIterator(index).add(element); 16.25/5.29 } catch (NoSuchElementException exc) { 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes the element at the specified position in this list (optional 16.25/5.29 * operation). Shifts any subsequent elements to the left (subtracts one 16.25/5.29 * from their indices). Returns the element that was removed from the 16.25/5.29 * list. 16.25/5.29 * 16.25/5.29 *

This implementation first gets a list iterator pointing to the 16.25/5.29 * indexed element (with listIterator(index)). Then, it removes 16.25/5.29 * the element with ListIterator.remove. 16.25/5.29 * 16.25/5.29 *

Note that this implementation will throw an 16.25/5.29 * UnsupportedOperationException if the list iterator does not 16.25/5.29 * implement the remove operation. 16.25/5.29 * 16.25/5.29 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public E remove(int index) { 16.25/5.29 try { 16.25/5.29 ListIterator e = listIterator(index); 16.25/5.29 E outCast = e.next(); 16.25/5.29 e.remove(); 16.25/5.29 return outCast; 16.25/5.29 } catch (NoSuchElementException exc) { 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 // Bulk Operations 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts all of the elements in the specified collection into this 16.25/5.29 * list at the specified position (optional operation). Shifts the 16.25/5.29 * element currently at that position (if any) and any subsequent 16.25/5.29 * elements to the right (increases their indices). The new elements 16.25/5.29 * will appear in this list in the order that they are returned by the 16.25/5.29 * specified collection's iterator. The behavior of this operation is 16.25/5.29 * undefined if the specified collection is modified while the 16.25/5.29 * operation is in progress. (Note that this will occur if the specified 16.25/5.29 * collection is this list, and it's nonempty.) 16.25/5.29 * 16.25/5.29 *

This implementation gets an iterator over the specified collection and 16.25/5.29 * a list iterator over this list pointing to the indexed element (with 16.25/5.29 * listIterator(index)). Then, it iterates over the specified 16.25/5.29 * collection, inserting the elements obtained from the iterator into this 16.25/5.29 * list, one at a time, using ListIterator.add followed by 16.25/5.29 * ListIterator.next (to skip over the added element). 16.25/5.29 * 16.25/5.29 *

Note that this implementation will throw an 16.25/5.29 * UnsupportedOperationException if the list iterator returned by 16.25/5.29 * the listIterator method does not implement the add 16.25/5.29 * operation. 16.25/5.29 * 16.25/5.29 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.29 * @throws ClassCastException {@inheritDoc} 16.25/5.29 * @throws NullPointerException {@inheritDoc} 16.25/5.29 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public boolean addAll(int index, Collection c) { 16.25/5.29 try { 16.25/5.29 boolean modified = false; 16.25/5.29 ListIterator e1 = listIterator(index); 16.25/5.29 Iterator e2 = c.iterator(); 16.25/5.29 while (e2.hasNext()) { 16.25/5.29 e1.add(e2.next()); 16.25/5.29 modified = true; 16.25/5.29 } 16.25/5.29 return modified; 16.25/5.29 } catch (NoSuchElementException exc) { 16.25/5.29 throw new IndexOutOfBoundsException(); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 // Iterators 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns an iterator over the elements in this list (in proper 16.25/5.29 * sequence).

16.25/5.29 * 16.25/5.29 * This implementation merely returns a list iterator over the list. 16.25/5.29 * 16.25/5.29 * @return an iterator over the elements in this list (in proper sequence) 16.25/5.29 */ 16.25/5.29 public Iterator iterator() { 16.25/5.29 return listIterator(); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns a list iterator over the elements in this list (in proper 16.25/5.29 * sequence). 16.25/5.29 * 16.25/5.29 * @param index index of first element to be returned from the list 16.25/5.29 * iterator (by a call to the next method) 16.25/5.29 * @return a list iterator over the elements in this list (in proper 16.25/5.29 * sequence) 16.25/5.29 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.29 */ 16.25/5.29 public abstract ListIterator listIterator(int index); 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * The root interface in the collection hierarchy. A collection 16.25/5.29 * represents a group of objects, known as its elements. Some 16.25/5.29 * collections allow duplicate elements and others do not. Some are ordered 16.25/5.29 * and others unordered. The JDK does not provide any direct 16.25/5.29 * implementations of this interface: it provides implementations of more 16.25/5.29 * specific subinterfaces like Set and List. This interface 16.25/5.29 * is typically used to pass collections around and manipulate them where 16.25/5.29 * maximum generality is desired. 16.25/5.29 * 16.25/5.29 *

Bags or multisets (unordered collections that may contain 16.25/5.29 * duplicate elements) should implement this interface directly. 16.25/5.29 * 16.25/5.29 *

All general-purpose Collection implementation classes (which 16.25/5.29 * typically implement Collection indirectly through one of its 16.25/5.29 * subinterfaces) should provide two "standard" constructors: a void (no 16.25/5.29 * arguments) constructor, which creates an empty collection, and a 16.25/5.29 * constructor with a single argument of type Collection, which 16.25/5.29 * creates a new collection with the same elements as its argument. In 16.25/5.29 * effect, the latter constructor allows the user to copy any collection, 16.25/5.29 * producing an equivalent collection of the desired implementation type. 16.25/5.29 * There is no way to enforce this convention (as interfaces cannot contain 16.25/5.29 * constructors) but all of the general-purpose Collection 16.25/5.29 * implementations in the Java platform libraries comply. 16.25/5.29 * 16.25/5.29 *

The "destructive" methods contained in this interface, that is, the 16.25/5.29 * methods that modify the collection on which they operate, are specified to 16.25/5.29 * throw UnsupportedOperationException if this collection does not 16.25/5.29 * support the operation. If this is the case, these methods may, but are not 16.25/5.29 * required to, throw an UnsupportedOperationException if the 16.25/5.29 * invocation would have no effect on the collection. For example, invoking 16.25/5.29 * the {@link #addAll(Collection)} method on an unmodifiable collection may, 16.25/5.29 * but is not required to, throw the exception if the collection to be added 16.25/5.29 * is empty. 16.25/5.29 * 16.25/5.29 *

Some collection implementations have restrictions on the elements that 16.25/5.29 * they may contain. For example, some implementations prohibit null elements, 16.25/5.29 * and some have restrictions on the types of their elements. Attempting to 16.25/5.29 * add an ineligible element throws an unchecked exception, typically 16.25/5.29 * NullPointerException or ClassCastException. Attempting 16.25/5.29 * to query the presence of an ineligible element may throw an exception, 16.25/5.29 * or it may simply return false; some implementations will exhibit the former 16.25/5.29 * behavior and some will exhibit the latter. More generally, attempting an 16.25/5.29 * operation on an ineligible element whose completion would not result in 16.25/5.29 * the insertion of an ineligible element into the collection may throw an 16.25/5.29 * exception or it may succeed, at the option of the implementation. 16.25/5.29 * Such exceptions are marked as "optional" in the specification for this 16.25/5.29 * interface. 16.25/5.29 * 16.25/5.29 *

It is up to each collection to determine its own synchronization 16.25/5.29 * policy. In the absence of a stronger guarantee by the 16.25/5.29 * implementation, undefined behavior may result from the invocation 16.25/5.29 * of any method on a collection that is being mutated by another 16.25/5.29 * thread; this includes direct invocations, passing the collection to 16.25/5.29 * a method that might perform invocations, and using an existing 16.25/5.29 * iterator to examine the collection. 16.25/5.29 * 16.25/5.29 *

Many methods in Collections Framework interfaces are defined in 16.25/5.29 * terms of the {@link Object#equals(Object) equals} method. For example, 16.25/5.29 * the specification for the {@link #contains(Object) contains(Object o)} 16.25/5.29 * method says: "returns true if and only if this collection 16.25/5.29 * contains at least one element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e))." This specification should 16.25/5.29 * not be construed to imply that invoking Collection.contains 16.25/5.29 * with a non-null argument o will cause o.equals(e) to be 16.25/5.29 * invoked for any element e. Implementations are free to implement 16.25/5.29 * optimizations whereby the equals invocation is avoided, for 16.25/5.29 * example, by first comparing the hash codes of the two elements. (The 16.25/5.29 * {@link Object#hashCode()} specification guarantees that two objects with 16.25/5.29 * unequal hash codes cannot be equal.) More generally, implementations of 16.25/5.29 * the various Collections Framework interfaces are free to take advantage of 16.25/5.29 * the specified behavior of underlying {@link Object} methods wherever the 16.25/5.29 * implementor deems it appropriate. 16.25/5.29 * 16.25/5.29 *

This interface is a member of the 16.25/5.29 * 16.25/5.29 * Java Collections Framework. 16.25/5.29 * 16.25/5.29 * @author Josh Bloch 16.25/5.29 * @author Neal Gafter 16.25/5.29 * @see Set 16.25/5.29 * @see List 16.25/5.29 * @see Map 16.25/5.29 * @see SortedSet 16.25/5.29 * @see SortedMap 16.25/5.29 * @see HashSet 16.25/5.29 * @see TreeSet 16.25/5.29 * @see ArrayList 16.25/5.29 * @see LinkedList 16.25/5.29 * @see Vector 16.25/5.29 * @see Collections 16.25/5.29 * @see Arrays 16.25/5.29 * @see AbstractCollection 16.25/5.29 * @since 1.2 16.25/5.29 */ 16.25/5.29 16.25/5.29 public interface Collection { 16.25/5.29 // Query Operations 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns the number of elements in this collection. If this collection 16.25/5.29 * contains more than Integer.MAX_VALUE elements, returns 16.25/5.29 * Integer.MAX_VALUE. 16.25/5.29 * 16.25/5.29 * @return the number of elements in this collection 16.25/5.29 */ 16.25/5.29 int size(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns true if this collection contains no elements. 16.25/5.29 * 16.25/5.29 * @return true if this collection contains no elements 16.25/5.29 */ 16.25/5.29 boolean isEmpty(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns true if this collection contains the specified element. 16.25/5.29 * More formally, returns true if and only if this collection 16.25/5.29 * contains at least one element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e)). 16.25/5.29 * 16.25/5.29 * @param o element whose presence in this collection is to be tested 16.25/5.29 * @return true if this collection contains the specified 16.25/5.29 * element 16.25/5.29 * @throws ClassCastException if the type of the specified element 16.25/5.29 * is incompatible with this collection (optional) 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * collection does not permit null elements (optional) 16.25/5.29 */ 16.25/5.29 boolean contains(Object o); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns an iterator over the elements in this collection. There are no 16.25/5.29 * guarantees concerning the order in which the elements are returned 16.25/5.29 * (unless this collection is an instance of some class that provides a 16.25/5.29 * guarantee). 16.25/5.29 * 16.25/5.29 * @return an Iterator over the elements in this collection 16.25/5.29 */ 16.25/5.29 Iterator iterator(); 16.25/5.29 16.25/5.29 // Modification Operations 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Ensures that this collection contains the specified element (optional 16.25/5.29 * operation). Returns true if this collection changed as a 16.25/5.29 * result of the call. (Returns false if this collection does 16.25/5.29 * not permit duplicates and already contains the specified element.)

16.25/5.29 * 16.25/5.29 * Collections that support this operation may place limitations on what 16.25/5.29 * elements may be added to this collection. In particular, some 16.25/5.29 * collections will refuse to add null elements, and others will 16.25/5.29 * impose restrictions on the type of elements that may be added. 16.25/5.29 * Collection classes should clearly specify in their documentation any 16.25/5.29 * restrictions on what elements may be added.

16.25/5.29 * 16.25/5.29 * If a collection refuses to add a particular element for any reason 16.25/5.29 * other than that it already contains the element, it must throw 16.25/5.29 * an exception (rather than returning false). This preserves 16.25/5.29 * the invariant that a collection always contains the specified element 16.25/5.29 * after this call returns. 16.25/5.29 * 16.25/5.29 * @param e element whose presence in this collection is to be ensured 16.25/5.29 * @return true if this collection changed as a result of the 16.25/5.29 * call 16.25/5.29 * @throws UnsupportedOperationException if the add operation 16.25/5.29 * is not supported by this collection 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this collection 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * collection does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the element 16.25/5.29 * prevents it from being added to this collection 16.25/5.29 * @throws IllegalStateException if the element cannot be added at this 16.25/5.29 * time due to insertion restrictions 16.25/5.29 */ 16.25/5.29 boolean add(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes a single instance of the specified element from this 16.25/5.29 * collection, if it is present (optional operation). More formally, 16.25/5.29 * removes an element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e)), if 16.25/5.29 * this collection contains one or more such elements. Returns 16.25/5.29 * true if this collection contained the specified element (or 16.25/5.29 * equivalently, if this collection changed as a result of the call). 16.25/5.29 * 16.25/5.29 * @param o element to be removed from this collection, if present 16.25/5.29 * @return true if an element was removed as a result of this call 16.25/5.29 * @throws ClassCastException if the type of the specified element 16.25/5.29 * is incompatible with this collection (optional) 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * collection does not permit null elements (optional) 16.25/5.29 * @throws UnsupportedOperationException if the remove operation 16.25/5.29 * is not supported by this collection 16.25/5.29 */ 16.25/5.29 boolean remove(Object o); 16.25/5.29 16.25/5.29 16.25/5.29 // Bulk Operations 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns true if this collection contains all of the elements 16.25/5.29 * in the specified collection. 16.25/5.29 * 16.25/5.29 * @param c collection to be checked for containment in this collection 16.25/5.29 * @return true if this collection contains all of the elements 16.25/5.29 * in the specified collection 16.25/5.29 * @throws ClassCastException if the types of one or more elements 16.25/5.29 * in the specified collection are incompatible with this 16.25/5.29 * collection (optional) 16.25/5.29 * @throws NullPointerException if the specified collection contains one 16.25/5.29 * or more null elements and this collection does not permit null 16.25/5.29 * elements (optional), or if the specified collection is null 16.25/5.29 * @see #contains(Object) 16.25/5.29 */ 16.25/5.29 boolean containsAll(Collection c); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Adds all of the elements in the specified collection to this collection 16.25/5.29 * (optional operation). The behavior of this operation is undefined if 16.25/5.29 * the specified collection is modified while the operation is in progress. 16.25/5.29 * (This implies that the behavior of this call is undefined if the 16.25/5.29 * specified collection is this collection, and this collection is 16.25/5.29 * nonempty.) 16.25/5.29 * 16.25/5.29 * @param c collection containing elements to be added to this collection 16.25/5.29 * @return true if this collection changed as a result of the call 16.25/5.29 * @throws UnsupportedOperationException if the addAll operation 16.25/5.29 * is not supported by this collection 16.25/5.29 * @throws ClassCastException if the class of an element of the specified 16.25/5.29 * collection prevents it from being added to this collection 16.25/5.29 * @throws NullPointerException if the specified collection contains a 16.25/5.29 * null element and this collection does not permit null elements, 16.25/5.29 * or if the specified collection is null 16.25/5.29 * @throws IllegalArgumentException if some property of an element of the 16.25/5.29 * specified collection prevents it from being added to this 16.25/5.29 * collection 16.25/5.29 * @throws IllegalStateException if not all the elements can be added at 16.25/5.29 * this time due to insertion restrictions 16.25/5.29 * @see #add(Object) 16.25/5.29 */ 16.25/5.29 boolean addAll(Collection c); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes all of this collection's elements that are also contained in the 16.25/5.29 * specified collection (optional operation). After this call returns, 16.25/5.29 * this collection will contain no elements in common with the specified 16.25/5.29 * collection. 16.25/5.29 * 16.25/5.29 * @param c collection containing elements to be removed from this collection 16.25/5.29 * @return true if this collection changed as a result of the 16.25/5.29 * call 16.25/5.29 * @throws UnsupportedOperationException if the removeAll method 16.25/5.29 * is not supported by this collection 16.25/5.29 * @throws ClassCastException if the types of one or more elements 16.25/5.29 * in this collection are incompatible with the specified 16.25/5.29 * collection (optional) 16.25/5.29 * @throws NullPointerException if this collection contains one or more 16.25/5.29 * null elements and the specified collection does not support 16.25/5.29 * null elements (optional), or if the specified collection is null 16.25/5.29 * @see #remove(Object) 16.25/5.29 * @see #contains(Object) 16.25/5.29 */ 16.25/5.29 boolean removeAll(Collection c); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retains only the elements in this collection that are contained in the 16.25/5.29 * specified collection (optional operation). In other words, removes from 16.25/5.29 * this collection all of its elements that are not contained in the 16.25/5.29 * specified collection. 16.25/5.29 * 16.25/5.29 * @param c collection containing elements to be retained in this collection 16.25/5.29 * @return true if this collection changed as a result of the call 16.25/5.29 * @throws UnsupportedOperationException if the retainAll operation 16.25/5.29 * is not supported by this collection 16.25/5.29 * @throws ClassCastException if the types of one or more elements 16.25/5.29 * in this collection are incompatible with the specified 16.25/5.29 * collection (optional) 16.25/5.29 * @throws NullPointerException if this collection contains one or more 16.25/5.29 * null elements and the specified collection does not permit null 16.25/5.29 * elements (optional), or if the specified collection is null 16.25/5.29 * @see #remove(Object) 16.25/5.29 * @see #contains(Object) 16.25/5.29 */ 16.25/5.29 boolean retainAll(Collection c); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes all of the elements from this collection (optional operation). 16.25/5.29 * The collection will be empty after this method returns. 16.25/5.29 * 16.25/5.29 * @throws UnsupportedOperationException if the clear operation 16.25/5.29 * is not supported by this collection 16.25/5.29 */ 16.25/5.29 void clear(); 16.25/5.29 16.25/5.29 16.25/5.29 // Comparison and hashing 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Compares the specified object with this collection for equality.

16.25/5.29 * 16.25/5.29 * While the Collection interface adds no stipulations to the 16.25/5.29 * general contract for the Object.equals, programmers who 16.25/5.29 * implement the Collection interface "directly" (in other words, 16.25/5.29 * create a class that is a Collection but is not a Set 16.25/5.29 * or a List) must exercise care if they choose to override the 16.25/5.29 * Object.equals. It is not necessary to do so, and the simplest 16.25/5.29 * course of action is to rely on Object's implementation, but 16.25/5.29 * the implementor may wish to implement a "value comparison" in place of 16.25/5.29 * the default "reference comparison." (The List and 16.25/5.29 * Set interfaces mandate such value comparisons.)

16.25/5.29 * 16.25/5.29 * The general contract for the Object.equals method states that 16.25/5.29 * equals must be symmetric (in other words, a.equals(b) if and 16.25/5.29 * only if b.equals(a)). The contracts for List.equals 16.25/5.29 * and Set.equals state that lists are only equal to other lists, 16.25/5.29 * and sets to other sets. Thus, a custom equals method for a 16.25/5.29 * collection class that implements neither the List nor 16.25/5.29 * Set interface must return false when this collection 16.25/5.29 * is compared to any list or set. (By the same logic, it is not possible 16.25/5.29 * to write a class that correctly implements both the Set and 16.25/5.29 * List interfaces.) 16.25/5.29 * 16.25/5.29 * @param o object to be compared for equality with this collection 16.25/5.29 * @return true if the specified object is equal to this 16.25/5.29 * collection 16.25/5.29 * 16.25/5.29 * @see Object#equals(Object) 16.25/5.29 * @see Set#equals(Object) 16.25/5.29 * @see List#equals(Object) 16.25/5.29 */ 16.25/5.29 boolean equals(Object o); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns the hash code value for this collection. While the 16.25/5.29 * Collection interface adds no stipulations to the general 16.25/5.29 * contract for the Object.hashCode method, programmers should 16.25/5.29 * take note that any class that overrides the Object.equals 16.25/5.29 * method must also override the Object.hashCode method in order 16.25/5.29 * to satisfy the general contract for the Object.hashCodemethod. 16.25/5.29 * In particular, c1.equals(c2) implies that 16.25/5.29 * c1.hashCode()==c2.hashCode(). 16.25/5.29 * 16.25/5.29 * @return the hash code value for this collection 16.25/5.29 * 16.25/5.29 * @see Object#hashCode() 16.25/5.29 * @see Object#equals(Object) 16.25/5.29 */ 16.25/5.29 int hashCode(); 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * This exception may be thrown by methods that have detected concurrent 16.25/5.29 * modification of an object when such modification is not permissible. 16.25/5.29 *

16.25/5.29 * For example, it is not generally permissible for one thread to modify a Collection 16.25/5.29 * while another thread is iterating over it. In general, the results of the 16.25/5.29 * iteration are undefined under these circumstances. Some Iterator 16.25/5.29 * implementations (including those of all the general purpose collection implementations 16.25/5.29 * provided by the JRE) may choose to throw this exception if this behavior is 16.25/5.29 * detected. Iterators that do this are known as fail-fast iterators, 16.25/5.29 * as they fail quickly and cleanly, rather that risking arbitrary, 16.25/5.29 * non-deterministic behavior at an undetermined time in the future. 16.25/5.29 *

16.25/5.29 * Note that this exception does not always indicate that an object has 16.25/5.29 * been concurrently modified by a different thread. If a single 16.25/5.29 * thread issues a sequence of method invocations that violates the 16.25/5.29 * contract of an object, the object may throw this exception. For 16.25/5.29 * example, if a thread modifies a collection directly while it is 16.25/5.29 * iterating over the collection with a fail-fast iterator, the iterator 16.25/5.29 * will throw this exception. 16.25/5.29 * 16.25/5.29 *

Note that fail-fast behavior cannot be guaranteed as it is, generally 16.25/5.29 * speaking, impossible to make any hard guarantees in the presence of 16.25/5.29 * unsynchronized concurrent modification. Fail-fast operations 16.25/5.29 * throw ConcurrentModificationException on a best-effort basis. 16.25/5.29 * Therefore, it would be wrong to write a program that depended on this 16.25/5.29 * exception for its correctness: ConcurrentModificationException 16.25/5.29 * should be used only to detect bugs. 16.25/5.29 * 16.25/5.29 * @author Josh Bloch 16.25/5.29 * @see Collection 16.25/5.29 * @see Iterator 16.25/5.29 * @see ListIterator 16.25/5.29 * @see Vector 16.25/5.29 * @see LinkedList 16.25/5.29 * @see HashSet 16.25/5.29 * @see Hashtable 16.25/5.29 * @see TreeMap 16.25/5.29 * @see AbstractList 16.25/5.29 * @since 1.2 16.25/5.29 */ 16.25/5.29 public class ConcurrentModificationException extends RuntimeException { 16.25/5.29 /** 16.25/5.29 * Constructs a ConcurrentModificationException with no 16.25/5.29 * detail message. 16.25/5.29 */ 16.25/5.29 public ConcurrentModificationException() { 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs a ConcurrentModificationException with the 16.25/5.29 * specified detail message. 16.25/5.29 * 16.25/5.29 * @param message the detail message pertaining to this exception. 16.25/5.29 */ 16.25/5.29 public ConcurrentModificationException(String message) { 16.25/5.29 super(message); 16.25/5.29 } 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 /* 16.25/5.29 * This file is available under and governed by the GNU General Public 16.25/5.29 * License version 2 only, as published by the Free Software Foundation. 16.25/5.29 * However, the following notice accompanied the original version of this 16.25/5.29 * file: 16.25/5.29 * 16.25/5.29 * Written by Doug Lea and Josh Bloch with assistance from members of 16.25/5.29 * JCP JSR-166 Expert Group and released to the public domain, as explained 16.25/5.29 * at http://creativecommons.org/licenses/publicdomain 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * A linear collection that supports element insertion and removal at 16.25/5.29 * both ends. The name deque is short for "double ended queue" 16.25/5.29 * and is usually pronounced "deck". Most Deque 16.25/5.29 * implementations place no fixed limits on the number of elements 16.25/5.29 * they may contain, but this interface supports capacity-restricted 16.25/5.29 * deques as well as those with no fixed size limit. 16.25/5.29 * 16.25/5.29 *

This interface defines methods to access the elements at both 16.25/5.29 * ends of the deque. Methods are provided to insert, remove, and 16.25/5.29 * examine the element. Each of these methods exists in two forms: 16.25/5.29 * one throws an exception if the operation fails, the other returns a 16.25/5.29 * special value (either null or false, depending on 16.25/5.29 * the operation). The latter form of the insert operation is 16.25/5.29 * designed specifically for use with capacity-restricted 16.25/5.29 * Deque implementations; in most implementations, insert 16.25/5.29 * operations cannot fail. 16.25/5.29 * 16.25/5.29 *

The twelve methods described above are summarized in the 16.25/5.29 * following table: 16.25/5.29 * 16.25/5.29 *

16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 *
First Element (Head) Last Element (Tail)
Throws exceptionSpecial valueThrows exceptionSpecial value
Insert{@link #addFirst addFirst(e)}{@link #offerFirst offerFirst(e)}{@link #addLast addLast(e)}{@link #offerLast offerLast(e)}
Remove{@link #removeFirst removeFirst()}{@link #pollFirst pollFirst()}{@link #removeLast removeLast()}{@link #pollLast pollLast()}
Examine{@link #getFirst getFirst()}{@link #peekFirst peekFirst()}{@link #getLast getLast()}{@link #peekLast peekLast()}
16.25/5.29 * 16.25/5.29 *

This interface extends the {@link Queue} interface. When a deque is 16.25/5.29 * used as a queue, FIFO (First-In-First-Out) behavior results. Elements are 16.25/5.29 * added at the end of the deque and removed from the beginning. The methods 16.25/5.29 * inherited from the Queue interface are precisely equivalent to 16.25/5.29 * Deque methods as indicated in the following table: 16.25/5.29 * 16.25/5.29 *

16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 *
Queue Method Equivalent Deque Method
{@link java.util.Queue#add add(e)}{@link #addLast addLast(e)}
{@link java.util.Queue#offer offer(e)}{@link #offerLast offerLast(e)}
{@link java.util.Queue#remove remove()}{@link #removeFirst removeFirst()}
{@link java.util.Queue#poll poll()}{@link #pollFirst pollFirst()}
{@link java.util.Queue#element element()}{@link #getFirst getFirst()}
{@link java.util.Queue#peek peek()}{@link #peek peekFirst()}
16.25/5.29 * 16.25/5.29 *

Deques can also be used as LIFO (Last-In-First-Out) stacks. This 16.25/5.29 * interface should be used in preference to the legacy {@link Stack} class. 16.25/5.29 * When a deque is used as a stack, elements are pushed and popped from the 16.25/5.29 * beginning of the deque. Stack methods are precisely equivalent to 16.25/5.29 * Deque methods as indicated in the table below: 16.25/5.29 * 16.25/5.29 *

16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 * 16.25/5.29 *
Stack Method Equivalent Deque Method
{@link #push push(e)}{@link #addFirst addFirst(e)}
{@link #pop pop()}{@link #removeFirst removeFirst()}
{@link #peek peek()}{@link #peekFirst peekFirst()}
16.25/5.29 * 16.25/5.29 *

Note that the {@link #peek peek} method works equally well when 16.25/5.29 * a deque is used as a queue or a stack; in either case, elements are 16.25/5.29 * drawn from the beginning of the deque. 16.25/5.29 * 16.25/5.29 *

This interface provides two methods to remove interior 16.25/5.29 * elements, {@link #removeFirstOccurrence removeFirstOccurrence} and 16.25/5.29 * {@link #removeLastOccurrence removeLastOccurrence}. 16.25/5.29 * 16.25/5.29 *

Unlike the {@link List} interface, this interface does not 16.25/5.29 * provide support for indexed access to elements. 16.25/5.29 * 16.25/5.29 *

While Deque implementations are not strictly required 16.25/5.29 * to prohibit the insertion of null elements, they are strongly 16.25/5.29 * encouraged to do so. Users of any Deque implementations 16.25/5.29 * that do allow null elements are strongly encouraged not to 16.25/5.29 * take advantage of the ability to insert nulls. This is so because 16.25/5.29 * null is used as a special return value by various methods 16.25/5.29 * to indicated that the deque is empty. 16.25/5.29 * 16.25/5.29 *

Deque implementations generally do not define 16.25/5.29 * element-based versions of the equals and hashCode 16.25/5.29 * methods, but instead inherit the identity-based versions from class 16.25/5.29 * Object. 16.25/5.29 * 16.25/5.29 *

This interface is a member of the Java Collections 16.25/5.29 * Framework. 16.25/5.29 * 16.25/5.29 * @author Doug Lea 16.25/5.29 * @author Josh Bloch 16.25/5.29 * @since 1.6 16.25/5.29 * @param the type of elements held in this collection 16.25/5.29 */ 16.25/5.29 16.25/5.29 public interface Deque extends Queue { 16.25/5.29 /** 16.25/5.29 * Inserts the specified element at the front of this deque if it is 16.25/5.29 * possible to do so immediately without violating capacity restrictions. 16.25/5.29 * When using a capacity-restricted deque, it is generally preferable to 16.25/5.29 * use method {@link #offerFirst}. 16.25/5.29 * 16.25/5.29 * @param e the element to add 16.25/5.29 * @throws IllegalStateException if the element cannot be added at this 16.25/5.29 * time due to capacity restrictions 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 void addFirst(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts the specified element at the end of this deque if it is 16.25/5.29 * possible to do so immediately without violating capacity restrictions. 16.25/5.29 * When using a capacity-restricted deque, it is generally preferable to 16.25/5.29 * use method {@link #offerLast}. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #add}. 16.25/5.29 * 16.25/5.29 * @param e the element to add 16.25/5.29 * @throws IllegalStateException if the element cannot be added at this 16.25/5.29 * time due to capacity restrictions 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 void addLast(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts the specified element at the front of this deque unless it would 16.25/5.29 * violate capacity restrictions. When using a capacity-restricted deque, 16.25/5.29 * this method is generally preferable to the {@link #addFirst} method, 16.25/5.29 * which can fail to insert an element only by throwing an exception. 16.25/5.29 * 16.25/5.29 * @param e the element to add 16.25/5.29 * @return true if the element was added to this deque, else 16.25/5.29 * false 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 boolean offerFirst(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts the specified element at the end of this deque unless it would 16.25/5.29 * violate capacity restrictions. When using a capacity-restricted deque, 16.25/5.29 * this method is generally preferable to the {@link #addLast} method, 16.25/5.29 * which can fail to insert an element only by throwing an exception. 16.25/5.29 * 16.25/5.29 * @param e the element to add 16.25/5.29 * @return true if the element was added to this deque, else 16.25/5.29 * false 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 boolean offerLast(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves and removes the first element of this deque. This method 16.25/5.29 * differs from {@link #pollFirst pollFirst} only in that it throws an 16.25/5.29 * exception if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the head of this deque 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E removeFirst(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves and removes the last element of this deque. This method 16.25/5.29 * differs from {@link #pollLast pollLast} only in that it throws an 16.25/5.29 * exception if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the tail of this deque 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E removeLast(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves and removes the first element of this deque, 16.25/5.29 * or returns null if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the head of this deque, or null if this deque is empty 16.25/5.29 */ 16.25/5.29 E pollFirst(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves and removes the last element of this deque, 16.25/5.29 * or returns null if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the tail of this deque, or null if this deque is empty 16.25/5.29 */ 16.25/5.29 E pollLast(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves, but does not remove, the first element of this deque. 16.25/5.29 * 16.25/5.29 * This method differs from {@link #peekFirst peekFirst} only in that it 16.25/5.29 * throws an exception if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the head of this deque 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E getFirst(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves, but does not remove, the last element of this deque. 16.25/5.29 * This method differs from {@link #peekLast peekLast} only in that it 16.25/5.29 * throws an exception if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the tail of this deque 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E getLast(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves, but does not remove, the first element of this deque, 16.25/5.29 * or returns null if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the head of this deque, or null if this deque is empty 16.25/5.29 */ 16.25/5.29 E peekFirst(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves, but does not remove, the last element of this deque, 16.25/5.29 * or returns null if this deque is empty. 16.25/5.29 * 16.25/5.29 * @return the tail of this deque, or null if this deque is empty 16.25/5.29 */ 16.25/5.29 E peekLast(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes the first occurrence of the specified element from this deque. 16.25/5.29 * If the deque does not contain the element, it is unchanged. 16.25/5.29 * More formally, removes the first element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e)) 16.25/5.29 * (if such an element exists). 16.25/5.29 * Returns true if this deque contained the specified element 16.25/5.29 * (or equivalently, if this deque changed as a result of the call). 16.25/5.29 * 16.25/5.29 * @param o element to be removed from this deque, if present 16.25/5.29 * @return true if an element was removed as a result of this call 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * is incompatible with this deque (optional) 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements (optional) 16.25/5.29 */ 16.25/5.29 boolean removeFirstOccurrence(Object o); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes the last occurrence of the specified element from this deque. 16.25/5.29 * If the deque does not contain the element, it is unchanged. 16.25/5.29 * More formally, removes the last element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e)) 16.25/5.29 * (if such an element exists). 16.25/5.29 * Returns true if this deque contained the specified element 16.25/5.29 * (or equivalently, if this deque changed as a result of the call). 16.25/5.29 * 16.25/5.29 * @param o element to be removed from this deque, if present 16.25/5.29 * @return true if an element was removed as a result of this call 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * is incompatible with this deque (optional) 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements (optional) 16.25/5.29 */ 16.25/5.29 boolean removeLastOccurrence(Object o); 16.25/5.29 16.25/5.29 // *** Queue methods *** 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts the specified element into the queue represented by this deque 16.25/5.29 * (in other words, at the tail of this deque) if it is possible to do so 16.25/5.29 * immediately without violating capacity restrictions, returning 16.25/5.29 * true upon success and throwing an 16.25/5.29 * IllegalStateException if no space is currently available. 16.25/5.29 * When using a capacity-restricted deque, it is generally preferable to 16.25/5.29 * use {@link #offer(Object) offer}. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #addLast}. 16.25/5.29 * 16.25/5.29 * @param e the element to add 16.25/5.29 * @return true (as specified by {@link Collection#add}) 16.25/5.29 * @throws IllegalStateException if the element cannot be added at this 16.25/5.29 * time due to capacity restrictions 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 boolean add(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Inserts the specified element into the queue represented by this deque 16.25/5.29 * (in other words, at the tail of this deque) if it is possible to do so 16.25/5.29 * immediately without violating capacity restrictions, returning 16.25/5.29 * true upon success and false if no space is currently 16.25/5.29 * available. When using a capacity-restricted deque, this method is 16.25/5.29 * generally preferable to the {@link #add} method, which can fail to 16.25/5.29 * insert an element only by throwing an exception. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #offerLast}. 16.25/5.29 * 16.25/5.29 * @param e the element to add 16.25/5.29 * @return true if the element was added to this deque, else 16.25/5.29 * false 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 boolean offer(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves and removes the head of the queue represented by this deque 16.25/5.29 * (in other words, the first element of this deque). 16.25/5.29 * This method differs from {@link #poll poll} only in that it throws an 16.25/5.29 * exception if this deque is empty. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #removeFirst()}. 16.25/5.29 * 16.25/5.29 * @return the head of the queue represented by this deque 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E remove(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves and removes the head of the queue represented by this deque 16.25/5.29 * (in other words, the first element of this deque), or returns 16.25/5.29 * null if this deque is empty. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #pollFirst()}. 16.25/5.29 * 16.25/5.29 * @return the first element of this deque, or null if 16.25/5.29 * this deque is empty 16.25/5.29 */ 16.25/5.29 E poll(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves, but does not remove, the head of the queue represented by 16.25/5.29 * this deque (in other words, the first element of this deque). 16.25/5.29 * This method differs from {@link #peek peek} only in that it throws an 16.25/5.29 * exception if this deque is empty. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #getFirst()}. 16.25/5.29 * 16.25/5.29 * @return the head of the queue represented by this deque 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E element(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Retrieves, but does not remove, the head of the queue represented by 16.25/5.29 * this deque (in other words, the first element of this deque), or 16.25/5.29 * returns null if this deque is empty. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #peekFirst()}. 16.25/5.29 * 16.25/5.29 * @return the head of the queue represented by this deque, or 16.25/5.29 * null if this deque is empty 16.25/5.29 */ 16.25/5.29 E peek(); 16.25/5.29 16.25/5.29 16.25/5.29 // *** Stack methods *** 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Pushes an element onto the stack represented by this deque (in other 16.25/5.29 * words, at the head of this deque) if it is possible to do so 16.25/5.29 * immediately without violating capacity restrictions, returning 16.25/5.29 * true upon success and throwing an 16.25/5.29 * IllegalStateException if no space is currently available. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #addFirst}. 16.25/5.29 * 16.25/5.29 * @param e the element to push 16.25/5.29 * @throws IllegalStateException if the element cannot be added at this 16.25/5.29 * time due to capacity restrictions 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * prevents it from being added to this deque 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements 16.25/5.29 * @throws IllegalArgumentException if some property of the specified 16.25/5.29 * element prevents it from being added to this deque 16.25/5.29 */ 16.25/5.29 void push(E e); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Pops an element from the stack represented by this deque. In other 16.25/5.29 * words, removes and returns the first element of this deque. 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #removeFirst()}. 16.25/5.29 * 16.25/5.29 * @return the element at the front of this deque (which is the top 16.25/5.29 * of the stack represented by this deque) 16.25/5.29 * @throws NoSuchElementException if this deque is empty 16.25/5.29 */ 16.25/5.29 E pop(); 16.25/5.29 16.25/5.29 16.25/5.29 // *** Collection methods *** 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes the first occurrence of the specified element from this deque. 16.25/5.29 * If the deque does not contain the element, it is unchanged. 16.25/5.29 * More formally, removes the first element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e)) 16.25/5.29 * (if such an element exists). 16.25/5.29 * Returns true if this deque contained the specified element 16.25/5.29 * (or equivalently, if this deque changed as a result of the call). 16.25/5.29 * 16.25/5.29 *

This method is equivalent to {@link #removeFirstOccurrence}. 16.25/5.29 * 16.25/5.29 * @param o element to be removed from this deque, if present 16.25/5.29 * @return true if an element was removed as a result of this call 16.25/5.29 * @throws ClassCastException if the class of the specified element 16.25/5.29 * is incompatible with this deque (optional) 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements (optional) 16.25/5.29 */ 16.25/5.29 boolean remove(Object o); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns true if this deque contains the specified element. 16.25/5.29 * More formally, returns true if and only if this deque contains 16.25/5.29 * at least one element e such that 16.25/5.29 * (o==null ? e==null : o.equals(e)). 16.25/5.29 * 16.25/5.29 * @param o element whose presence in this deque is to be tested 16.25/5.29 * @return true if this deque contains the specified element 16.25/5.29 * @throws ClassCastException if the type of the specified element 16.25/5.29 * is incompatible with this deque (optional) 16.25/5.29 * @throws NullPointerException if the specified element is null and this 16.25/5.29 * deque does not permit null elements (optional) 16.25/5.29 */ 16.25/5.29 boolean contains(Object o); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns the number of elements in this deque. 16.25/5.29 * 16.25/5.29 * @return the number of elements in this deque 16.25/5.29 */ 16.25/5.29 public int size(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns an iterator over the elements in this deque in proper sequence. 16.25/5.29 * The elements will be returned in order from first (head) to last (tail). 16.25/5.29 * 16.25/5.29 * @return an iterator over the elements in this deque in proper sequence 16.25/5.29 */ 16.25/5.29 Iterator iterator(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns an iterator over the elements in this deque in reverse 16.25/5.29 * sequential order. The elements will be returned in order from 16.25/5.29 * last (tail) to first (head). 16.25/5.29 * 16.25/5.29 * @return an iterator over the elements in this deque in reverse 16.25/5.29 * sequence 16.25/5.29 */ 16.25/5.29 Iterator descendingIterator(); 16.25/5.29 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * Copyright 1994-2003 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Thrown to indicate that a method has been passed an illegal or 16.25/5.29 * inappropriate argument. 16.25/5.29 * 16.25/5.29 * @author unascribed 16.25/5.29 * @see java.lang.Thread#setPriority(int) 16.25/5.29 * @since JDK1.0 16.25/5.29 */ 16.25/5.29 public 16.25/5.29 class IllegalArgumentException extends RuntimeException { 16.25/5.29 /** 16.25/5.29 * Constructs an IllegalArgumentException with no 16.25/5.29 * detail message. 16.25/5.29 */ 16.25/5.29 public IllegalArgumentException() { 16.25/5.29 super(); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs an IllegalArgumentException with the 16.25/5.29 * specified detail message. 16.25/5.29 * 16.25/5.29 * @param s the detail message. 16.25/5.29 */ 16.25/5.29 public IllegalArgumentException(String s) { 16.25/5.29 super(s); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs a new exception with the specified detail message and 16.25/5.29 * cause. 16.25/5.29 * 16.25/5.29 *

Note that the detail message associated with cause is 16.25/5.29 * not automatically incorporated in this exception's detail 16.25/5.29 * message. 16.25/5.29 * 16.25/5.29 * @param message the detail message (which is saved for later retrieval 16.25/5.29 * by the {@link Throwable#getMessage()} method). 16.25/5.29 * @param cause the cause (which is saved for later retrieval by the 16.25/5.29 * {@link Throwable#getCause()} method). (A null value 16.25/5.29 * is permitted, and indicates that the cause is nonexistent or 16.25/5.29 * unknown.) 16.25/5.29 * @since 1.5 16.25/5.29 */ 16.25/5.29 public IllegalArgumentException(String message, Throwable cause) { 16.25/5.29 super(message, cause); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs a new exception with the specified cause and a detail 16.25/5.29 * message of (cause==null ? null : cause.toString()) (which 16.25/5.29 * typically contains the class and detail message of cause). 16.25/5.29 * This constructor is useful for exceptions that are little more than 16.25/5.29 * wrappers for other throwables (for example, {@link 16.25/5.29 * java.security.PrivilegedActionException}). 16.25/5.29 * 16.25/5.29 * @param cause the cause (which is saved for later retrieval by the 16.25/5.29 * {@link Throwable#getCause()} method). (A null value is 16.25/5.29 * permitted, and indicates that the cause is nonexistent or 16.25/5.29 * unknown.) 16.25/5.29 * @since 1.5 16.25/5.29 */ 16.25/5.29 public IllegalArgumentException(Throwable cause) { 16.25/5.29 super(cause); 16.25/5.29 } 16.25/5.29 16.25/5.29 private static final long serialVersionUID = -5365630128856068164L; 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * Copyright 1996-2003 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Signals that a method has been invoked at an illegal or 16.25/5.29 * inappropriate time. In other words, the Java environment or 16.25/5.29 * Java application is not in an appropriate state for the requested 16.25/5.29 * operation. 16.25/5.29 * 16.25/5.29 * @author Jonni Kanerva 16.25/5.29 * @since JDK1.1 16.25/5.29 */ 16.25/5.29 public 16.25/5.29 class IllegalStateException extends RuntimeException { 16.25/5.29 /** 16.25/5.29 * Constructs an IllegalStateException with no detail message. 16.25/5.29 * A detail message is a String that describes this particular exception. 16.25/5.29 */ 16.25/5.29 public IllegalStateException() { 16.25/5.29 super(); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs an IllegalStateException with the specified detail 16.25/5.29 * message. A detail message is a String that describes this particular 16.25/5.29 * exception. 16.25/5.29 * 16.25/5.29 * @param s the String that contains a detailed message 16.25/5.29 */ 16.25/5.29 public IllegalStateException(String s) { 16.25/5.29 super(s); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs a new exception with the specified detail message and 16.25/5.29 * cause. 16.25/5.29 * 16.25/5.29 *

Note that the detail message associated with cause is 16.25/5.29 * not automatically incorporated in this exception's detail 16.25/5.29 * message. 16.25/5.29 * 16.25/5.29 * @param message the detail message (which is saved for later retrieval 16.25/5.29 * by the {@link Throwable#getMessage()} method). 16.25/5.29 * @param cause the cause (which is saved for later retrieval by the 16.25/5.29 * {@link Throwable#getCause()} method). (A null value 16.25/5.29 * is permitted, and indicates that the cause is nonexistent or 16.25/5.29 * unknown.) 16.25/5.29 * @since 1.5 16.25/5.29 */ 16.25/5.29 public IllegalStateException(String message, Throwable cause) { 16.25/5.29 super(message, cause); 16.25/5.29 } 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Constructs a new exception with the specified cause and a detail 16.25/5.29 * message of (cause==null ? null : cause.toString()) (which 16.25/5.29 * typically contains the class and detail message of cause). 16.25/5.29 * This constructor is useful for exceptions that are little more than 16.25/5.29 * wrappers for other throwables (for example, {@link 16.25/5.29 * java.security.PrivilegedActionException}). 16.25/5.29 * 16.25/5.29 * @param cause the cause (which is saved for later retrieval by the 16.25/5.29 * {@link Throwable#getCause()} method). (A null value is 16.25/5.29 * permitted, and indicates that the cause is nonexistent or 16.25/5.29 * unknown.) 16.25/5.29 * @since 1.5 16.25/5.29 */ 16.25/5.29 public IllegalStateException(Throwable cause) { 16.25/5.29 super(cause); 16.25/5.29 } 16.25/5.29 16.25/5.29 static final long serialVersionUID = -1848914673093119416L; 16.25/5.29 } 16.25/5.29 16.25/5.29 16.25/5.29 /* 16.25/5.29 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.29 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.29 * 16.25/5.29 * This code is free software; you can redistribute it and/or modify it 16.25/5.29 * under the terms of the GNU General Public License version 2 only, as 16.25/5.29 * published by the Free Software Foundation. Sun designates this 16.25/5.29 * particular file as subject to the "Classpath" exception as provided 16.25/5.29 * by Sun in the LICENSE file that accompanied this code. 16.25/5.29 * 16.25/5.29 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.29 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.29 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.29 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.29 * accompanied this code). 16.25/5.29 * 16.25/5.29 * You should have received a copy of the GNU General Public License version 16.25/5.29 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.29 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.29 * 16.25/5.29 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.29 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.29 * have any questions. 16.25/5.29 */ 16.25/5.29 16.25/5.29 package javaUtilEx; 16.25/5.29 16.25/5.29 /** 16.25/5.29 * An iterator over a collection. {@code Iterator} takes the place of 16.25/5.29 * {@link Enumeration} in the Java Collections Framework. Iterators 16.25/5.29 * differ from enumerations in two ways: 16.25/5.29 * 16.25/5.29 *

16.25/5.29 * 16.25/5.29 *

This interface is a member of the 16.25/5.29 * 16.25/5.29 * Java Collections Framework. 16.25/5.29 * 16.25/5.29 * @author Josh Bloch 16.25/5.29 * @see Collection 16.25/5.29 * @see ListIterator 16.25/5.29 * @see Iterable 16.25/5.29 * @since 1.2 16.25/5.29 */ 16.25/5.29 public interface Iterator { 16.25/5.29 /** 16.25/5.29 * Returns {@code true} if the iteration has more elements. 16.25/5.29 * (In other words, returns {@code true} if {@link #next} would 16.25/5.29 * return an element rather than throwing an exception.) 16.25/5.29 * 16.25/5.29 * @return {@code true} if the iteration has more elements 16.25/5.29 */ 16.25/5.29 boolean hasNext(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Returns the next element in the iteration. 16.25/5.29 * 16.25/5.29 * @return the next element in the iteration 16.25/5.29 * @throws NoSuchElementException if the iteration has no more elements 16.25/5.29 */ 16.25/5.29 E next(); 16.25/5.29 16.25/5.29 /** 16.25/5.29 * Removes from the underlying collection the last element returned 16.25/5.29 * by this iterator (optional operation). This method can be called 16.25/5.29 * only once per call to {@link #next}. The behavior of an iterator 16.25/5.29 * is unspecified if the underlying collection is modified while the 16.25/5.29 * iteration is in progress in any way other than by calling this 16.25/5.30 * method. 16.25/5.30 * 16.25/5.30 * @throws UnsupportedOperationException if the {@code remove} 16.25/5.30 * operation is not supported by this iterator 16.25/5.30 * 16.25/5.30 * @throws IllegalStateException if the {@code next} method has not 16.25/5.30 * yet been called, or the {@code remove} method has already 16.25/5.30 * been called after the last call to the {@code next} 16.25/5.30 * method 16.25/5.30 */ 16.25/5.30 void remove(); 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 public class juLinkedListCreateAddLast { 16.25/5.30 public static void main(String[] args) { 16.25/5.30 Random.args = args; 16.25/5.30 16.25/5.30 LinkedList l = createList(Random.random()); 16.25/5.30 l.addLast(new Content(Random.random())); 16.25/5.30 } 16.25/5.30 16.25/5.30 public static LinkedList createList(int n) { 16.25/5.30 LinkedList l = new LinkedList(); 16.25/5.30 while (n > 0) { 16.25/5.30 l.addLast(new Content(Random.random())); 16.25/5.30 n--; 16.25/5.30 } 16.25/5.30 return l; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 final class Content { 16.25/5.30 int val; 16.25/5.30 16.25/5.30 public Content(int v) { 16.25/5.30 this.val = v; 16.25/5.30 } 16.25/5.30 16.25/5.30 public int hashCode() { 16.25/5.30 return val^31; 16.25/5.30 } 16.25/5.30 16.25/5.30 public boolean equals(Object o) { 16.25/5.30 if (o instanceof Content) { 16.25/5.30 return this.val == ((Content) o).val; 16.25/5.30 } 16.25/5.30 return false; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Linked list implementation of the List interface. Implements all 16.25/5.30 * optional list operations, and permits all elements (including 16.25/5.30 * null). In addition to implementing the List interface, 16.25/5.30 * the LinkedList class provides uniformly named methods to 16.25/5.30 * get, remove and insert an element at the 16.25/5.30 * beginning and end of the list. These operations allow linked lists to be 16.25/5.30 * used as a stack, {@linkplain Queue queue}, or {@linkplain Deque 16.25/5.30 * double-ended queue}.

16.25/5.30 * 16.25/5.30 * The class implements the Deque interface, providing 16.25/5.30 * first-in-first-out queue operations for add, 16.25/5.30 * poll, along with other stack and deque operations.

16.25/5.30 * 16.25/5.30 * All of the operations perform as could be expected for a doubly-linked 16.25/5.30 * list. Operations that index into the list will traverse the list from 16.25/5.30 * the beginning or the end, whichever is closer to the specified index.

16.25/5.30 * 16.25/5.30 *

Note that this implementation is not synchronized. 16.25/5.30 * If multiple threads access a linked list concurrently, and at least 16.25/5.30 * one of the threads modifies the list structurally, it must be 16.25/5.30 * synchronized externally. (A structural modification is any operation 16.25/5.30 * that adds or deletes one or more elements; merely setting the value of 16.25/5.30 * an element is not a structural modification.) This is typically 16.25/5.30 * accomplished by synchronizing on some object that naturally 16.25/5.30 * encapsulates the list. 16.25/5.30 * 16.25/5.30 * If no such object exists, the list should be "wrapped" using the 16.25/5.30 * {@link Collections#synchronizedList Collections.synchronizedList} 16.25/5.30 * method. This is best done at creation time, to prevent accidental 16.25/5.30 * unsynchronized access to the list:

16.25/5.30	 *   List list = Collections.synchronizedList(new LinkedList(...));
16.25/5.30 * 16.25/5.30 *

The iterators returned by this class's iterator and 16.25/5.30 * listIterator methods are fail-fast: if the list is 16.25/5.30 * structurally modified at any time after the iterator is created, in 16.25/5.30 * any way except through the Iterator's own remove or 16.25/5.30 * add methods, the iterator will throw a {@link 16.25/5.30 * ConcurrentModificationException}. Thus, in the face of concurrent 16.25/5.30 * modification, the iterator fails quickly and cleanly, rather than 16.25/5.30 * risking arbitrary, non-deterministic behavior at an undetermined 16.25/5.30 * time in the future. 16.25/5.30 * 16.25/5.30 *

Note that the fail-fast behavior of an iterator cannot be guaranteed 16.25/5.30 * as it is, generally speaking, impossible to make any hard guarantees in the 16.25/5.30 * presence of unsynchronized concurrent modification. Fail-fast iterators 16.25/5.30 * throw ConcurrentModificationException on a best-effort basis. 16.25/5.30 * Therefore, it would be wrong to write a program that depended on this 16.25/5.30 * exception for its correctness: the fail-fast behavior of iterators 16.25/5.30 * should be used only to detect bugs. 16.25/5.30 * 16.25/5.30 *

This class is a member of the 16.25/5.30 * 16.25/5.30 * Java Collections Framework. 16.25/5.30 * 16.25/5.30 * @author Josh Bloch 16.25/5.30 * @see List 16.25/5.30 * @see ArrayList 16.25/5.30 * @see Vector 16.25/5.30 * @since 1.2 16.25/5.30 * @param the type of elements held in this collection 16.25/5.30 */ 16.25/5.30 16.25/5.30 public class LinkedList 16.25/5.30 extends AbstractSequentialList 16.25/5.30 implements List, Deque 16.25/5.30 { 16.25/5.30 private transient Entry header = new Entry(null, null, null); 16.25/5.30 private transient int size = 0; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Constructs an empty list. 16.25/5.30 */ 16.25/5.30 public LinkedList() { 16.25/5.30 header.next = header.previous = header; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Constructs a list containing the elements of the specified 16.25/5.30 * collection, in the order they are returned by the collection's 16.25/5.30 * iterator. 16.25/5.30 * 16.25/5.30 * @param c the collection whose elements are to be placed into this list 16.25/5.30 * @throws NullPointerException if the specified collection is null 16.25/5.30 */ 16.25/5.30 public LinkedList(Collection c) { 16.25/5.30 this(); 16.25/5.30 addAll(c); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the first element in this list. 16.25/5.30 * 16.25/5.30 * @return the first element in this list 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 */ 16.25/5.30 public E getFirst() { 16.25/5.30 if (size==0) 16.25/5.30 throw new NoSuchElementException(); 16.25/5.30 16.25/5.30 return header.next.element; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the last element in this list. 16.25/5.30 * 16.25/5.30 * @return the last element in this list 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 */ 16.25/5.30 public E getLast() { 16.25/5.30 if (size==0) 16.25/5.30 throw new NoSuchElementException(); 16.25/5.30 16.25/5.30 return header.previous.element; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes and returns the first element from this list. 16.25/5.30 * 16.25/5.30 * @return the first element from this list 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 */ 16.25/5.30 public E removeFirst() { 16.25/5.30 return remove(header.next); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes and returns the last element from this list. 16.25/5.30 * 16.25/5.30 * @return the last element from this list 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 */ 16.25/5.30 public E removeLast() { 16.25/5.30 return remove(header.previous); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts the specified element at the beginning of this list. 16.25/5.30 * 16.25/5.30 * @param e the element to add 16.25/5.30 */ 16.25/5.30 public void addFirst(E e) { 16.25/5.30 addBefore(e, header.next); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Appends the specified element to the end of this list. 16.25/5.30 * 16.25/5.30 *

This method is equivalent to {@link #add}. 16.25/5.30 * 16.25/5.30 * @param e the element to add 16.25/5.30 */ 16.25/5.30 public void addLast(E e) { 16.25/5.30 addBefore(e, header); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns true if this list contains the specified element. 16.25/5.30 * More formally, returns true if and only if this list contains 16.25/5.30 * at least one element e such that 16.25/5.30 * (o==null ? e==null : o.equals(e)). 16.25/5.30 * 16.25/5.30 * @param o element whose presence in this list is to be tested 16.25/5.30 * @return true if this list contains the specified element 16.25/5.30 */ 16.25/5.30 public boolean contains(Object o) { 16.25/5.30 return indexOf(o) != -1; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the number of elements in this list. 16.25/5.30 * 16.25/5.30 * @return the number of elements in this list 16.25/5.30 */ 16.25/5.30 public int size() { 16.25/5.30 return size; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Appends the specified element to the end of this list. 16.25/5.30 * 16.25/5.30 *

This method is equivalent to {@link #addLast}. 16.25/5.30 * 16.25/5.30 * @param e element to be appended to this list 16.25/5.30 * @return true (as specified by {@link Collection#add}) 16.25/5.30 */ 16.25/5.30 public boolean add(E e) { 16.25/5.30 addBefore(e, header); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes the first occurrence of the specified element from this list, 16.25/5.30 * if it is present. If this list does not contain the element, it is 16.25/5.30 * unchanged. More formally, removes the element with the lowest index 16.25/5.30 * i such that 16.25/5.30 * (o==null ? get(i)==null : o.equals(get(i))) 16.25/5.30 * (if such an element exists). Returns true if this list 16.25/5.30 * contained the specified element (or equivalently, if this list 16.25/5.30 * changed as a result of the call). 16.25/5.30 * 16.25/5.30 * @param o element to be removed from this list, if present 16.25/5.30 * @return true if this list contained the specified element 16.25/5.30 */ 16.25/5.30 public boolean remove(Object o) { 16.25/5.30 if (o==null) { 16.25/5.30 for (Entry e = header.next; e != header; e = e.next) { 16.25/5.30 if (e.element==null) { 16.25/5.30 remove(e); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 } else { 16.25/5.30 for (Entry e = header.next; e != header; e = e.next) { 16.25/5.30 if (o.equals(e.element)) { 16.25/5.30 remove(e); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 } 16.25/5.30 return false; 16.25/5.30 } 16.25/5.30 /** 16.25/5.30 * Removes all of the elements from this list. 16.25/5.30 */ 16.25/5.30 public void clear() { 16.25/5.30 Entry e = header.next; 16.25/5.30 while (e != header) { 16.25/5.30 Entry next = e.next; 16.25/5.30 e.next = e.previous = null; 16.25/5.30 e.element = null; 16.25/5.30 e = next; 16.25/5.30 } 16.25/5.30 header.next = header.previous = header; 16.25/5.30 size = 0; 16.25/5.30 modCount++; 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 // Positional Access Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the element at the specified position in this list. 16.25/5.30 * 16.25/5.30 * @param index index of the element to return 16.25/5.30 * @return the element at the specified position in this list 16.25/5.30 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.30 */ 16.25/5.30 public E get(int index) { 16.25/5.30 return entry(index).element; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Replaces the element at the specified position in this list with the 16.25/5.30 * specified element. 16.25/5.30 * 16.25/5.30 * @param index index of the element to replace 16.25/5.30 * @param element element to be stored at the specified position 16.25/5.30 * @return the element previously at the specified position 16.25/5.30 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.30 */ 16.25/5.30 public E set(int index, E element) { 16.25/5.30 Entry e = entry(index); 16.25/5.30 E oldVal = e.element; 16.25/5.30 e.element = element; 16.25/5.30 return oldVal; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts the specified element at the specified position in this list. 16.25/5.30 * Shifts the element currently at that position (if any) and any 16.25/5.30 * subsequent elements to the right (adds one to their indices). 16.25/5.30 * 16.25/5.30 * @param index index at which the specified element is to be inserted 16.25/5.30 * @param element element to be inserted 16.25/5.30 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.30 */ 16.25/5.30 public void add(int index, E element) { 16.25/5.30 addBefore(element, (index==size ? header : entry(index))); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes the element at the specified position in this list. Shifts any 16.25/5.30 * subsequent elements to the left (subtracts one from their indices). 16.25/5.30 * Returns the element that was removed from the list. 16.25/5.30 * 16.25/5.30 * @param index the index of the element to be removed 16.25/5.30 * @return the element previously at the specified position 16.25/5.30 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.30 */ 16.25/5.30 public E remove(int index) { 16.25/5.30 return remove(entry(index)); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the indexed entry. 16.25/5.30 */ 16.25/5.30 private Entry entry(int index) { 16.25/5.30 if (index < 0 || index >= size) 16.25/5.30 throw new IndexOutOfBoundsException(); 16.25/5.30 Entry e = header; 16.25/5.30 if (index < (size >> 1)) { 16.25/5.30 for (int i = 0; i <= index; i++) 16.25/5.30 e = e.next; 16.25/5.30 } else { 16.25/5.30 for (int i = size; i > index; i--) 16.25/5.30 e = e.previous; 16.25/5.30 } 16.25/5.30 return e; 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 // Search Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the index of the first occurrence of the specified element 16.25/5.30 * in this list, or -1 if this list does not contain the element. 16.25/5.30 * More formally, returns the lowest index i such that 16.25/5.30 * (o==null ? get(i)==null : o.equals(get(i))), 16.25/5.30 * or -1 if there is no such index. 16.25/5.30 * 16.25/5.30 * @param o element to search for 16.25/5.30 * @return the index of the first occurrence of the specified element in 16.25/5.30 * this list, or -1 if this list does not contain the element 16.25/5.30 */ 16.25/5.30 public int indexOf(Object o) { 16.25/5.30 int index = 0; 16.25/5.30 if (o==null) { 16.25/5.30 for (Entry e = header.next; e != header; e = e.next) { 16.25/5.30 if (e.element==null) 16.25/5.30 return index; 16.25/5.30 index++; 16.25/5.30 } 16.25/5.30 } else { 16.25/5.30 for (Entry e = header.next; e != header; e = e.next) { 16.25/5.30 if (o.equals(e.element)) 16.25/5.30 return index; 16.25/5.30 index++; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 return -1; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the index of the last occurrence of the specified element 16.25/5.30 * in this list, or -1 if this list does not contain the element. 16.25/5.30 * More formally, returns the highest index i such that 16.25/5.30 * (o==null ? get(i)==null : o.equals(get(i))), 16.25/5.30 * or -1 if there is no such index. 16.25/5.30 * 16.25/5.30 * @param o element to search for 16.25/5.30 * @return the index of the last occurrence of the specified element in 16.25/5.30 * this list, or -1 if this list does not contain the element 16.25/5.30 */ 16.25/5.30 public int lastIndexOf(Object o) { 16.25/5.30 int index = size; 16.25/5.30 if (o==null) { 16.25/5.30 for (Entry e = header.previous; e != header; e = e.previous) { 16.25/5.30 index--; 16.25/5.30 if (e.element==null) 16.25/5.30 return index; 16.25/5.30 } 16.25/5.30 } else { 16.25/5.30 for (Entry e = header.previous; e != header; e = e.previous) { 16.25/5.30 index--; 16.25/5.30 if (o.equals(e.element)) 16.25/5.30 return index; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 return -1; 16.25/5.30 } 16.25/5.30 16.25/5.30 // Queue operations. 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves, but does not remove, the head (first element) of this list. 16.25/5.30 * @return the head of this list, or null if this list is empty 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public E peek() { 16.25/5.30 if (size==0) 16.25/5.30 return null; 16.25/5.30 return getFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves, but does not remove, the head (first element) of this list. 16.25/5.30 * @return the head of this list 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public E element() { 16.25/5.30 return getFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves and removes the head (first element) of this list 16.25/5.30 * @return the head of this list, or null if this list is empty 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public E poll() { 16.25/5.30 if (size==0) 16.25/5.30 return null; 16.25/5.30 return removeFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves and removes the head (first element) of this list. 16.25/5.30 * 16.25/5.30 * @return the head of this list 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public E remove() { 16.25/5.30 return removeFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Adds the specified element as the tail (last element) of this list. 16.25/5.30 * 16.25/5.30 * @param e the element to add 16.25/5.30 * @return true (as specified by {@link Queue#offer}) 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public boolean offer(E e) { 16.25/5.30 return add(e); 16.25/5.30 } 16.25/5.30 16.25/5.30 // Deque operations 16.25/5.30 /** 16.25/5.30 * Inserts the specified element at the front of this list. 16.25/5.30 * 16.25/5.30 * @param e the element to insert 16.25/5.30 * @return true (as specified by {@link Deque#offerFirst}) 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public boolean offerFirst(E e) { 16.25/5.30 addFirst(e); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts the specified element at the end of this list. 16.25/5.30 * 16.25/5.30 * @param e the element to insert 16.25/5.30 * @return true (as specified by {@link Deque#offerLast}) 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public boolean offerLast(E e) { 16.25/5.30 addLast(e); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves, but does not remove, the first element of this list, 16.25/5.30 * or returns null if this list is empty. 16.25/5.30 * 16.25/5.30 * @return the first element of this list, or null 16.25/5.30 * if this list is empty 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public E peekFirst() { 16.25/5.30 if (size==0) 16.25/5.30 return null; 16.25/5.30 return getFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves, but does not remove, the last element of this list, 16.25/5.30 * or returns null if this list is empty. 16.25/5.30 * 16.25/5.30 * @return the last element of this list, or null 16.25/5.30 * if this list is empty 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public E peekLast() { 16.25/5.30 if (size==0) 16.25/5.30 return null; 16.25/5.30 return getLast(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves and removes the first element of this list, 16.25/5.30 * or returns null if this list is empty. 16.25/5.30 * 16.25/5.30 * @return the first element of this list, or null if 16.25/5.30 * this list is empty 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public E pollFirst() { 16.25/5.30 if (size==0) 16.25/5.30 return null; 16.25/5.30 return removeFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves and removes the last element of this list, 16.25/5.30 * or returns null if this list is empty. 16.25/5.30 * 16.25/5.30 * @return the last element of this list, or null if 16.25/5.30 * this list is empty 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public E pollLast() { 16.25/5.30 if (size==0) 16.25/5.30 return null; 16.25/5.30 return removeLast(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Pushes an element onto the stack represented by this list. In other 16.25/5.30 * words, inserts the element at the front of this list. 16.25/5.30 * 16.25/5.30 *

This method is equivalent to {@link #addFirst}. 16.25/5.30 * 16.25/5.30 * @param e the element to push 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public void push(E e) { 16.25/5.30 addFirst(e); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Pops an element from the stack represented by this list. In other 16.25/5.30 * words, removes and returns the first element of this list. 16.25/5.30 * 16.25/5.30 *

This method is equivalent to {@link #removeFirst()}. 16.25/5.30 * 16.25/5.30 * @return the element at the front of this list (which is the top 16.25/5.30 * of the stack represented by this list) 16.25/5.30 * @throws NoSuchElementException if this list is empty 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public E pop() { 16.25/5.30 return removeFirst(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes the first occurrence of the specified element in this 16.25/5.30 * list (when traversing the list from head to tail). If the list 16.25/5.30 * does not contain the element, it is unchanged. 16.25/5.30 * 16.25/5.30 * @param o element to be removed from this list, if present 16.25/5.30 * @return true if the list contained the specified element 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public boolean removeFirstOccurrence(Object o) { 16.25/5.30 return remove(o); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes the last occurrence of the specified element in this 16.25/5.30 * list (when traversing the list from head to tail). If the list 16.25/5.30 * does not contain the element, it is unchanged. 16.25/5.30 * 16.25/5.30 * @param o element to be removed from this list, if present 16.25/5.30 * @return true if the list contained the specified element 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public boolean removeLastOccurrence(Object o) { 16.25/5.30 if (o==null) { 16.25/5.30 for (Entry e = header.previous; e != header; e = e.previous) { 16.25/5.30 if (e.element==null) { 16.25/5.30 remove(e); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 } else { 16.25/5.30 for (Entry e = header.previous; e != header; e = e.previous) { 16.25/5.30 if (o.equals(e.element)) { 16.25/5.30 remove(e); 16.25/5.30 return true; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 } 16.25/5.30 return false; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns a list-iterator of the elements in this list (in proper 16.25/5.30 * sequence), starting at the specified position in the list. 16.25/5.30 * Obeys the general contract of List.listIterator(int).

16.25/5.30 * 16.25/5.30 * The list-iterator is fail-fast: if the list is structurally 16.25/5.30 * modified at any time after the Iterator is created, in any way except 16.25/5.30 * through the list-iterator's own remove or add 16.25/5.30 * methods, the list-iterator will throw a 16.25/5.30 * ConcurrentModificationException. Thus, in the face of 16.25/5.30 * concurrent modification, the iterator fails quickly and cleanly, rather 16.25/5.30 * than risking arbitrary, non-deterministic behavior at an undetermined 16.25/5.30 * time in the future. 16.25/5.30 * 16.25/5.30 * @param index index of the first element to be returned from the 16.25/5.30 * list-iterator (by a call to next) 16.25/5.30 * @return a ListIterator of the elements in this list (in proper 16.25/5.30 * sequence), starting at the specified position in the list 16.25/5.30 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.30 * @see List#listIterator(int) 16.25/5.30 */ 16.25/5.30 public ListIterator listIterator(int index) { 16.25/5.30 return new ListItr(index); 16.25/5.30 } 16.25/5.30 16.25/5.30 private class ListItr implements ListIterator { 16.25/5.30 private Entry lastReturned = header; 16.25/5.30 private Entry next; 16.25/5.30 private int nextIndex; 16.25/5.30 private int expectedModCount = modCount; 16.25/5.30 16.25/5.30 ListItr(int index) { 16.25/5.30 if (index < 0 || index > size) 16.25/5.30 throw new IndexOutOfBoundsException(); 16.25/5.30 if (index < (size >> 1)) { 16.25/5.30 next = header.next; 16.25/5.30 for (nextIndex=0; nextIndexindex; nextIndex--) 16.25/5.30 next = next.previous; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 public boolean hasNext() { 16.25/5.30 return nextIndex != size; 16.25/5.30 } 16.25/5.30 16.25/5.30 public E next() { 16.25/5.30 checkForComodification(); 16.25/5.30 if (nextIndex == size) 16.25/5.30 throw new NoSuchElementException(); 16.25/5.30 16.25/5.30 lastReturned = next; 16.25/5.30 next = next.next; 16.25/5.30 nextIndex++; 16.25/5.30 return lastReturned.element; 16.25/5.30 } 16.25/5.30 16.25/5.30 public boolean hasPrevious() { 16.25/5.30 return nextIndex != 0; 16.25/5.30 } 16.25/5.30 16.25/5.30 public E previous() { 16.25/5.30 if (nextIndex == 0) 16.25/5.30 throw new NoSuchElementException(); 16.25/5.30 16.25/5.30 lastReturned = next = next.previous; 16.25/5.30 nextIndex--; 16.25/5.30 checkForComodification(); 16.25/5.30 return lastReturned.element; 16.25/5.30 } 16.25/5.30 16.25/5.30 public int nextIndex() { 16.25/5.30 return nextIndex; 16.25/5.30 } 16.25/5.30 16.25/5.30 public int previousIndex() { 16.25/5.30 return nextIndex-1; 16.25/5.30 } 16.25/5.30 16.25/5.30 public void remove() { 16.25/5.30 checkForComodification(); 16.25/5.30 Entry lastNext = lastReturned.next; 16.25/5.30 try { 16.25/5.30 LinkedList.this.remove(lastReturned); 16.25/5.30 } catch (NoSuchElementException e) { 16.25/5.30 throw new IllegalStateException(); 16.25/5.30 } 16.25/5.30 if (next==lastReturned) 16.25/5.30 next = lastNext; 16.25/5.30 else 16.25/5.30 nextIndex--; 16.25/5.30 lastReturned = header; 16.25/5.30 expectedModCount++; 16.25/5.30 } 16.25/5.30 16.25/5.30 public void set(E e) { 16.25/5.30 if (lastReturned == header) 16.25/5.30 throw new IllegalStateException(); 16.25/5.30 checkForComodification(); 16.25/5.30 lastReturned.element = e; 16.25/5.30 } 16.25/5.30 16.25/5.30 public void add(E e) { 16.25/5.30 checkForComodification(); 16.25/5.30 lastReturned = header; 16.25/5.30 addBefore(e, next); 16.25/5.30 nextIndex++; 16.25/5.30 expectedModCount++; 16.25/5.30 } 16.25/5.30 16.25/5.30 final void checkForComodification() { 16.25/5.30 if (modCount != expectedModCount) 16.25/5.30 throw new ConcurrentModificationException(); 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 private static class Entry { 16.25/5.30 E element; 16.25/5.30 Entry next; 16.25/5.30 Entry previous; 16.25/5.30 16.25/5.30 Entry(E element, Entry next, Entry previous) { 16.25/5.30 this.element = element; 16.25/5.30 this.next = next; 16.25/5.30 this.previous = previous; 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 private Entry addBefore(E e, Entry entry) { 16.25/5.30 Entry newEntry = new Entry(e, entry, entry.previous); 16.25/5.30 newEntry.previous.next = newEntry; 16.25/5.30 newEntry.next.previous = newEntry; 16.25/5.30 size++; 16.25/5.30 modCount++; 16.25/5.30 return newEntry; 16.25/5.30 } 16.25/5.30 16.25/5.30 private E remove(Entry e) { 16.25/5.30 if (e == header) 16.25/5.30 throw new NoSuchElementException(); 16.25/5.30 16.25/5.30 E result = e.element; 16.25/5.30 e.previous.next = e.next; 16.25/5.30 e.next.previous = e.previous; 16.25/5.30 e.next = e.previous = null; 16.25/5.30 e.element = null; 16.25/5.30 size--; 16.25/5.30 modCount++; 16.25/5.30 return result; 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * @since 1.6 16.25/5.30 */ 16.25/5.30 public Iterator descendingIterator() { 16.25/5.30 return new DescendingIterator(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** Adapter to provide descending iterators via ListItr.previous */ 16.25/5.30 private class DescendingIterator implements Iterator { 16.25/5.30 final ListItr itr = new ListItr(size()); 16.25/5.30 public boolean hasNext() { 16.25/5.30 return itr.hasPrevious(); 16.25/5.30 } 16.25/5.30 public E next() { 16.25/5.30 return itr.previous(); 16.25/5.30 } 16.25/5.30 public void remove() { 16.25/5.30 itr.remove(); 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns an array containing all of the elements in this list 16.25/5.30 * in proper sequence (from first to last element). 16.25/5.30 * 16.25/5.30 *

The returned array will be "safe" in that no references to it are 16.25/5.30 * maintained by this list. (In other words, this method must allocate 16.25/5.30 * a new array). The caller is thus free to modify the returned array. 16.25/5.30 * 16.25/5.30 *

This method acts as bridge between array-based and collection-based 16.25/5.30 * APIs. 16.25/5.30 * 16.25/5.30 * @return an array containing all of the elements in this list 16.25/5.30 * in proper sequence 16.25/5.30 */ 16.25/5.30 public Object[] toArray() { 16.25/5.30 Object[] result = new Object[size]; 16.25/5.30 int i = 0; 16.25/5.30 for (Entry e = header.next; e != header; e = e.next) 16.25/5.30 result[i++] = e.element; 16.25/5.30 return result; 16.25/5.30 } 16.25/5.30 16.25/5.30 private static final long serialVersionUID = 876323262645176354L; 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * An iterator for lists that allows the programmer 16.25/5.30 * to traverse the list in either direction, modify 16.25/5.30 * the list during iteration, and obtain the iterator's 16.25/5.30 * current position in the list. A {@code ListIterator} 16.25/5.30 * has no current element; its cursor position always 16.25/5.30 * lies between the element that would be returned by a call 16.25/5.30 * to {@code previous()} and the element that would be 16.25/5.30 * returned by a call to {@code next()}. 16.25/5.30 * An iterator for a list of length {@code n} has {@code n+1} possible 16.25/5.30 * cursor positions, as illustrated by the carets ({@code ^}) below: 16.25/5.30 *

16.25/5.30	 *                      Element(0)   Element(1)   Element(2)   ... Element(n-1)
16.25/5.30	 * cursor positions:  ^            ^            ^            ^                  ^
16.25/5.30	 * 
16.25/5.30 * Note that the {@link #remove} and {@link #set(Object)} methods are 16.25/5.30 * not defined in terms of the cursor position; they are defined to 16.25/5.30 * operate on the last element returned by a call to {@link #next} or 16.25/5.30 * {@link #previous()}. 16.25/5.30 * 16.25/5.30 *

This interface is a member of the 16.25/5.30 * 16.25/5.30 * Java Collections Framework. 16.25/5.30 * 16.25/5.30 * @author Josh Bloch 16.25/5.30 * @see Collection 16.25/5.30 * @see List 16.25/5.30 * @see Iterator 16.25/5.30 * @see Enumeration 16.25/5.30 * @see List#listIterator() 16.25/5.30 * @since 1.2 16.25/5.30 */ 16.25/5.30 public interface ListIterator extends Iterator { 16.25/5.30 // Query Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns {@code true} if this list iterator has more elements when 16.25/5.30 * traversing the list in the forward direction. (In other words, 16.25/5.30 * returns {@code true} if {@link #next} would return an element rather 16.25/5.30 * than throwing an exception.) 16.25/5.30 * 16.25/5.30 * @return {@code true} if the list iterator has more elements when 16.25/5.30 * traversing the list in the forward direction 16.25/5.30 */ 16.25/5.30 boolean hasNext(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the next element in the list and advances the cursor position. 16.25/5.30 * This method may be called repeatedly to iterate through the list, 16.25/5.30 * or intermixed with calls to {@link #previous} to go back and forth. 16.25/5.30 * (Note that alternating calls to {@code next} and {@code previous} 16.25/5.30 * will return the same element repeatedly.) 16.25/5.30 * 16.25/5.30 * @return the next element in the list 16.25/5.30 * @throws NoSuchElementException if the iteration has no next element 16.25/5.30 */ 16.25/5.30 E next(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns {@code true} if this list iterator has more elements when 16.25/5.30 * traversing the list in the reverse direction. (In other words, 16.25/5.30 * returns {@code true} if {@link #previous} would return an element 16.25/5.30 * rather than throwing an exception.) 16.25/5.30 * 16.25/5.30 * @return {@code true} if the list iterator has more elements when 16.25/5.30 * traversing the list in the reverse direction 16.25/5.30 */ 16.25/5.30 boolean hasPrevious(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the previous element in the list and moves the cursor 16.25/5.30 * position backwards. This method may be called repeatedly to 16.25/5.30 * iterate through the list backwards, or intermixed with calls to 16.25/5.30 * {@link #next} to go back and forth. (Note that alternating calls 16.25/5.30 * to {@code next} and {@code previous} will return the same 16.25/5.30 * element repeatedly.) 16.25/5.30 * 16.25/5.30 * @return the previous element in the list 16.25/5.30 * @throws NoSuchElementException if the iteration has no previous 16.25/5.30 * element 16.25/5.30 */ 16.25/5.30 E previous(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the index of the element that would be returned by a 16.25/5.30 * subsequent call to {@link #next}. (Returns list size if the list 16.25/5.30 * iterator is at the end of the list.) 16.25/5.30 * 16.25/5.30 * @return the index of the element that would be returned by a 16.25/5.30 * subsequent call to {@code next}, or list size if the list 16.25/5.30 * iterator is at the end of the list 16.25/5.30 */ 16.25/5.30 int nextIndex(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the index of the element that would be returned by a 16.25/5.30 * subsequent call to {@link #previous}. (Returns -1 if the list 16.25/5.30 * iterator is at the beginning of the list.) 16.25/5.30 * 16.25/5.30 * @return the index of the element that would be returned by a 16.25/5.30 * subsequent call to {@code previous}, or -1 if the list 16.25/5.30 * iterator is at the beginning of the list 16.25/5.30 */ 16.25/5.30 int previousIndex(); 16.25/5.30 16.25/5.30 16.25/5.30 // Modification Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes from the list the last element that was returned by {@link 16.25/5.30 * #next} or {@link #previous} (optional operation). This call can 16.25/5.30 * only be made once per call to {@code next} or {@code previous}. 16.25/5.30 * It can be made only if {@link #add} has not been 16.25/5.30 * called after the last call to {@code next} or {@code previous}. 16.25/5.30 * 16.25/5.30 * @throws UnsupportedOperationException if the {@code remove} 16.25/5.30 * operation is not supported by this list iterator 16.25/5.30 * @throws IllegalStateException if neither {@code next} nor 16.25/5.30 * {@code previous} have been called, or {@code remove} or 16.25/5.30 * {@code add} have been called after the last call to 16.25/5.30 * {@code next} or {@code previous} 16.25/5.30 */ 16.25/5.30 void remove(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Replaces the last element returned by {@link #next} or 16.25/5.30 * {@link #previous} with the specified element (optional operation). 16.25/5.30 * This call can be made only if neither {@link #remove} nor {@link 16.25/5.30 * #add} have been called after the last call to {@code next} or 16.25/5.30 * {@code previous}. 16.25/5.30 * 16.25/5.30 * @param e the element with which to replace the last element returned by 16.25/5.30 * {@code next} or {@code previous} 16.25/5.30 * @throws UnsupportedOperationException if the {@code set} operation 16.25/5.30 * is not supported by this list iterator 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 * @throws IllegalArgumentException if some aspect of the specified 16.25/5.30 * element prevents it from being added to this list 16.25/5.30 * @throws IllegalStateException if neither {@code next} nor 16.25/5.30 * {@code previous} have been called, or {@code remove} or 16.25/5.30 * {@code add} have been called after the last call to 16.25/5.30 * {@code next} or {@code previous} 16.25/5.30 */ 16.25/5.30 void set(E e); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts the specified element into the list (optional operation). 16.25/5.30 * The element is inserted immediately before the next element that 16.25/5.30 * would be returned by {@link #next}, if any, and after the next 16.25/5.30 * element that would be returned by {@link #previous}, if any. (If the 16.25/5.30 * list contains no elements, the new element becomes the sole element 16.25/5.30 * on the list.) The new element is inserted before the implicit 16.25/5.30 * cursor: a subsequent call to {@code next} would be unaffected, and a 16.25/5.30 * subsequent call to {@code previous} would return the new element. 16.25/5.30 * (This call increases by one the value that would be returned by a 16.25/5.30 * call to {@code nextIndex} or {@code previousIndex}.) 16.25/5.30 * 16.25/5.30 * @param e the element to insert 16.25/5.30 * @throws UnsupportedOperationException if the {@code add} method is 16.25/5.30 * not supported by this list iterator 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 * @throws IllegalArgumentException if some aspect of this element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 */ 16.25/5.30 void add(E e); 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * An ordered collection (also known as a sequence). The user of this 16.25/5.30 * interface has precise control over where in the list each element is 16.25/5.30 * inserted. The user can access elements by their integer index (position in 16.25/5.30 * the list), and search for elements in the list.

16.25/5.30 * 16.25/5.30 * Unlike sets, lists typically allow duplicate elements. More formally, 16.25/5.30 * lists typically allow pairs of elements e1 and e2 16.25/5.30 * such that e1.equals(e2), and they typically allow multiple 16.25/5.30 * null elements if they allow null elements at all. It is not inconceivable 16.25/5.30 * that someone might wish to implement a list that prohibits duplicates, by 16.25/5.30 * throwing runtime exceptions when the user attempts to insert them, but we 16.25/5.30 * expect this usage to be rare.

16.25/5.30 * 16.25/5.30 * The List interface places additional stipulations, beyond those 16.25/5.30 * specified in the Collection interface, on the contracts of the 16.25/5.30 * iterator, add, remove, equals, and 16.25/5.30 * hashCode methods. Declarations for other inherited methods are 16.25/5.30 * also included here for convenience.

16.25/5.30 * 16.25/5.30 * The List interface provides four methods for positional (indexed) 16.25/5.30 * access to list elements. Lists (like Java arrays) are zero based. Note 16.25/5.30 * that these operations may execute in time proportional to the index value 16.25/5.30 * for some implementations (the LinkedList class, for 16.25/5.30 * example). Thus, iterating over the elements in a list is typically 16.25/5.30 * preferable to indexing through it if the caller does not know the 16.25/5.30 * implementation.

16.25/5.30 * 16.25/5.30 * The List interface provides a special iterator, called a 16.25/5.30 * ListIterator, that allows element insertion and replacement, and 16.25/5.30 * bidirectional access in addition to the normal operations that the 16.25/5.30 * Iterator interface provides. A method is provided to obtain a 16.25/5.30 * list iterator that starts at a specified position in the list.

16.25/5.30 * 16.25/5.30 * The List interface provides two methods to search for a specified 16.25/5.30 * object. From a performance standpoint, these methods should be used with 16.25/5.30 * caution. In many implementations they will perform costly linear 16.25/5.30 * searches.

16.25/5.30 * 16.25/5.30 * The List interface provides two methods to efficiently insert and 16.25/5.30 * remove multiple elements at an arbitrary point in the list.

16.25/5.30 * 16.25/5.30 * Note: While it is permissible for lists to contain themselves as elements, 16.25/5.30 * extreme caution is advised: the equals and hashCode 16.25/5.30 * methods are no longer well defined on such a list. 16.25/5.30 * 16.25/5.30 *

Some list implementations have restrictions on the elements that 16.25/5.30 * they may contain. For example, some implementations prohibit null elements, 16.25/5.30 * and some have restrictions on the types of their elements. Attempting to 16.25/5.30 * add an ineligible element throws an unchecked exception, typically 16.25/5.30 * NullPointerException or ClassCastException. Attempting 16.25/5.30 * to query the presence of an ineligible element may throw an exception, 16.25/5.30 * or it may simply return false; some implementations will exhibit the former 16.25/5.30 * behavior and some will exhibit the latter. More generally, attempting an 16.25/5.30 * operation on an ineligible element whose completion would not result in 16.25/5.30 * the insertion of an ineligible element into the list may throw an 16.25/5.30 * exception or it may succeed, at the option of the implementation. 16.25/5.30 * Such exceptions are marked as "optional" in the specification for this 16.25/5.30 * interface. 16.25/5.30 * 16.25/5.30 *

This interface is a member of the 16.25/5.30 * 16.25/5.30 * Java Collections Framework. 16.25/5.30 * 16.25/5.30 * @author Josh Bloch 16.25/5.30 * @author Neal Gafter 16.25/5.30 * @see Collection 16.25/5.30 * @see Set 16.25/5.30 * @see ArrayList 16.25/5.30 * @see LinkedList 16.25/5.30 * @see Vector 16.25/5.30 * @see Arrays#asList(Object[]) 16.25/5.30 * @see Collections#nCopies(int, Object) 16.25/5.30 * @see Collections#EMPTY_LIST 16.25/5.30 * @see AbstractList 16.25/5.30 * @see AbstractSequentialList 16.25/5.30 * @since 1.2 16.25/5.30 */ 16.25/5.30 16.25/5.30 public interface List extends Collection { 16.25/5.30 // Query Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the number of elements in this list. If this list contains 16.25/5.30 * more than Integer.MAX_VALUE elements, returns 16.25/5.30 * Integer.MAX_VALUE. 16.25/5.30 * 16.25/5.30 * @return the number of elements in this list 16.25/5.30 */ 16.25/5.30 int size(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns true if this list contains no elements. 16.25/5.30 * 16.25/5.30 * @return true if this list contains no elements 16.25/5.30 */ 16.25/5.30 boolean isEmpty(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns true if this list contains the specified element. 16.25/5.30 * More formally, returns true if and only if this list contains 16.25/5.30 * at least one element e such that 16.25/5.30 * (o==null ? e==null : o.equals(e)). 16.25/5.30 * 16.25/5.30 * @param o element whose presence in this list is to be tested 16.25/5.30 * @return true if this list contains the specified element 16.25/5.30 * @throws ClassCastException if the type of the specified element 16.25/5.30 * is incompatible with this list (optional) 16.25/5.30 * @throws NullPointerException if the specified element is null and this 16.25/5.30 * list does not permit null elements (optional) 16.25/5.30 */ 16.25/5.30 boolean contains(Object o); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns an iterator over the elements in this list in proper sequence. 16.25/5.30 * 16.25/5.30 * @return an iterator over the elements in this list in proper sequence 16.25/5.30 */ 16.25/5.30 Iterator iterator(); 16.25/5.30 16.25/5.30 // Modification Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Appends the specified element to the end of this list (optional 16.25/5.30 * operation). 16.25/5.30 * 16.25/5.30 *

Lists that support this operation may place limitations on what 16.25/5.30 * elements may be added to this list. In particular, some 16.25/5.30 * lists will refuse to add null elements, and others will impose 16.25/5.30 * restrictions on the type of elements that may be added. List 16.25/5.30 * classes should clearly specify in their documentation any restrictions 16.25/5.30 * on what elements may be added. 16.25/5.30 * 16.25/5.30 * @param e element to be appended to this list 16.25/5.30 * @return true (as specified by {@link Collection#add}) 16.25/5.30 * @throws UnsupportedOperationException if the add operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 * @throws NullPointerException if the specified element is null and this 16.25/5.30 * list does not permit null elements 16.25/5.30 * @throws IllegalArgumentException if some property of this element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 */ 16.25/5.30 boolean add(E e); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes the first occurrence of the specified element from this list, 16.25/5.30 * if it is present (optional operation). If this list does not contain 16.25/5.30 * the element, it is unchanged. More formally, removes the element with 16.25/5.30 * the lowest index i such that 16.25/5.30 * (o==null ? get(i)==null : o.equals(get(i))) 16.25/5.30 * (if such an element exists). Returns true if this list 16.25/5.30 * contained the specified element (or equivalently, if this list changed 16.25/5.30 * as a result of the call). 16.25/5.30 * 16.25/5.30 * @param o element to be removed from this list, if present 16.25/5.30 * @return true if this list contained the specified element 16.25/5.30 * @throws ClassCastException if the type of the specified element 16.25/5.30 * is incompatible with this list (optional) 16.25/5.30 * @throws NullPointerException if the specified element is null and this 16.25/5.30 * list does not permit null elements (optional) 16.25/5.30 * @throws UnsupportedOperationException if the remove operation 16.25/5.30 * is not supported by this list 16.25/5.30 */ 16.25/5.30 boolean remove(Object o); 16.25/5.30 16.25/5.30 16.25/5.30 // Bulk Modification Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns true if this list contains all of the elements of the 16.25/5.30 * specified collection. 16.25/5.30 * 16.25/5.30 * @param c collection to be checked for containment in this list 16.25/5.30 * @return true if this list contains all of the elements of the 16.25/5.30 * specified collection 16.25/5.30 * @throws ClassCastException if the types of one or more elements 16.25/5.30 * in the specified collection are incompatible with this 16.25/5.30 * list (optional) 16.25/5.30 * @throws NullPointerException if the specified collection contains one 16.25/5.30 * or more null elements and this list does not permit null 16.25/5.30 * elements (optional), or if the specified collection is null 16.25/5.30 * @see #contains(Object) 16.25/5.30 */ 16.25/5.30 boolean containsAll(Collection c); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Appends all of the elements in the specified collection to the end of 16.25/5.30 * this list, in the order that they are returned by the specified 16.25/5.30 * collection's iterator (optional operation). The behavior of this 16.25/5.30 * operation is undefined if the specified collection is modified while 16.25/5.30 * the operation is in progress. (Note that this will occur if the 16.25/5.30 * specified collection is this list, and it's nonempty.) 16.25/5.30 * 16.25/5.30 * @param c collection containing elements to be added to this list 16.25/5.30 * @return true if this list changed as a result of the call 16.25/5.30 * @throws UnsupportedOperationException if the addAll operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of an element of the specified 16.25/5.30 * collection prevents it from being added to this list 16.25/5.30 * @throws NullPointerException if the specified collection contains one 16.25/5.30 * or more null elements and this list does not permit null 16.25/5.30 * elements, or if the specified collection is null 16.25/5.30 * @throws IllegalArgumentException if some property of an element of the 16.25/5.30 * specified collection prevents it from being added to this list 16.25/5.30 * @see #add(Object) 16.25/5.30 */ 16.25/5.30 boolean addAll(Collection c); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts all of the elements in the specified collection into this 16.25/5.30 * list at the specified position (optional operation). Shifts the 16.25/5.30 * element currently at that position (if any) and any subsequent 16.25/5.30 * elements to the right (increases their indices). The new elements 16.25/5.30 * will appear in this list in the order that they are returned by the 16.25/5.30 * specified collection's iterator. The behavior of this operation is 16.25/5.30 * undefined if the specified collection is modified while the 16.25/5.30 * operation is in progress. (Note that this will occur if the specified 16.25/5.30 * collection is this list, and it's nonempty.) 16.25/5.30 * 16.25/5.30 * @param index index at which to insert the first element from the 16.25/5.30 * specified collection 16.25/5.30 * @param c collection containing elements to be added to this list 16.25/5.30 * @return true if this list changed as a result of the call 16.25/5.30 * @throws UnsupportedOperationException if the addAll operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of an element of the specified 16.25/5.30 * collection prevents it from being added to this list 16.25/5.30 * @throws NullPointerException if the specified collection contains one 16.25/5.30 * or more null elements and this list does not permit null 16.25/5.30 * elements, or if the specified collection is null 16.25/5.30 * @throws IllegalArgumentException if some property of an element of the 16.25/5.30 * specified collection prevents it from being added to this list 16.25/5.30 * @throws IndexOutOfBoundsException if the index is out of range 16.25/5.30 * (index < 0 || index > size()) 16.25/5.30 */ 16.25/5.30 boolean addAll(int index, Collection c); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes from this list all of its elements that are contained in the 16.25/5.30 * specified collection (optional operation). 16.25/5.30 * 16.25/5.30 * @param c collection containing elements to be removed from this list 16.25/5.30 * @return true if this list changed as a result of the call 16.25/5.30 * @throws UnsupportedOperationException if the removeAll operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of an element of this list 16.25/5.30 * is incompatible with the specified collection (optional) 16.25/5.30 * @throws NullPointerException if this list contains a null element and the 16.25/5.30 * specified collection does not permit null elements (optional), 16.25/5.30 * or if the specified collection is null 16.25/5.30 * @see #remove(Object) 16.25/5.30 * @see #contains(Object) 16.25/5.30 */ 16.25/5.30 boolean removeAll(Collection c); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retains only the elements in this list that are contained in the 16.25/5.30 * specified collection (optional operation). In other words, removes 16.25/5.30 * from this list all of its elements that are not contained in the 16.25/5.30 * specified collection. 16.25/5.30 * 16.25/5.30 * @param c collection containing elements to be retained in this list 16.25/5.30 * @return true if this list changed as a result of the call 16.25/5.30 * @throws UnsupportedOperationException if the retainAll operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of an element of this list 16.25/5.30 * is incompatible with the specified collection (optional) 16.25/5.30 * @throws NullPointerException if this list contains a null element and the 16.25/5.30 * specified collection does not permit null elements (optional), 16.25/5.30 * or if the specified collection is null 16.25/5.30 * @see #remove(Object) 16.25/5.30 * @see #contains(Object) 16.25/5.30 */ 16.25/5.30 boolean retainAll(Collection c); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes all of the elements from this list (optional operation). 16.25/5.30 * The list will be empty after this call returns. 16.25/5.30 * 16.25/5.30 * @throws UnsupportedOperationException if the clear operation 16.25/5.30 * is not supported by this list 16.25/5.30 */ 16.25/5.30 void clear(); 16.25/5.30 16.25/5.30 16.25/5.30 // Comparison and hashing 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Compares the specified object with this list for equality. Returns 16.25/5.30 * true if and only if the specified object is also a list, both 16.25/5.30 * lists have the same size, and all corresponding pairs of elements in 16.25/5.30 * the two lists are equal. (Two elements e1 and 16.25/5.30 * e2 are equal if (e1==null ? e2==null : 16.25/5.30 * e1.equals(e2)).) In other words, two lists are defined to be 16.25/5.30 * equal if they contain the same elements in the same order. This 16.25/5.30 * definition ensures that the equals method works properly across 16.25/5.30 * different implementations of the List interface. 16.25/5.30 * 16.25/5.30 * @param o the object to be compared for equality with this list 16.25/5.30 * @return true if the specified object is equal to this list 16.25/5.30 */ 16.25/5.30 boolean equals(Object o); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the hash code value for this list. The hash code of a list 16.25/5.30 * is defined to be the result of the following calculation: 16.25/5.30 *

16.25/5.30	     *  int hashCode = 1;
16.25/5.30	     *  for (E e : list)
16.25/5.30	     *      hashCode = 31*hashCode + (e==null ? 0 : e.hashCode());
16.25/5.30	     * 
16.25/5.30 * This ensures that list1.equals(list2) implies that 16.25/5.30 * list1.hashCode()==list2.hashCode() for any two lists, 16.25/5.30 * list1 and list2, as required by the general 16.25/5.30 * contract of {@link Object#hashCode}. 16.25/5.30 * 16.25/5.30 * @return the hash code value for this list 16.25/5.30 * @see Object#equals(Object) 16.25/5.30 * @see #equals(Object) 16.25/5.30 */ 16.25/5.30 int hashCode(); 16.25/5.30 16.25/5.30 16.25/5.30 // Positional Access Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the element at the specified position in this list. 16.25/5.30 * 16.25/5.30 * @param index index of the element to return 16.25/5.30 * @return the element at the specified position in this list 16.25/5.30 * @throws IndexOutOfBoundsException if the index is out of range 16.25/5.30 * (index < 0 || index >= size()) 16.25/5.30 */ 16.25/5.30 E get(int index); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Replaces the element at the specified position in this list with the 16.25/5.30 * specified element (optional operation). 16.25/5.30 * 16.25/5.30 * @param index index of the element to replace 16.25/5.30 * @param element element to be stored at the specified position 16.25/5.30 * @return the element previously at the specified position 16.25/5.30 * @throws UnsupportedOperationException if the set operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 * @throws NullPointerException if the specified element is null and 16.25/5.30 * this list does not permit null elements 16.25/5.30 * @throws IllegalArgumentException if some property of the specified 16.25/5.30 * element prevents it from being added to this list 16.25/5.30 * @throws IndexOutOfBoundsException if the index is out of range 16.25/5.30 * (index < 0 || index >= size()) 16.25/5.30 */ 16.25/5.30 E set(int index, E element); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts the specified element at the specified position in this list 16.25/5.30 * (optional operation). Shifts the element currently at that position 16.25/5.30 * (if any) and any subsequent elements to the right (adds one to their 16.25/5.30 * indices). 16.25/5.30 * 16.25/5.30 * @param index index at which the specified element is to be inserted 16.25/5.30 * @param element element to be inserted 16.25/5.30 * @throws UnsupportedOperationException if the add operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this list 16.25/5.30 * @throws NullPointerException if the specified element is null and 16.25/5.30 * this list does not permit null elements 16.25/5.30 * @throws IllegalArgumentException if some property of the specified 16.25/5.30 * element prevents it from being added to this list 16.25/5.30 * @throws IndexOutOfBoundsException if the index is out of range 16.25/5.30 * (index < 0 || index > size()) 16.25/5.30 */ 16.25/5.30 void add(int index, E element); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Removes the element at the specified position in this list (optional 16.25/5.30 * operation). Shifts any subsequent elements to the left (subtracts one 16.25/5.30 * from their indices). Returns the element that was removed from the 16.25/5.30 * list. 16.25/5.30 * 16.25/5.30 * @param index the index of the element to be removed 16.25/5.30 * @return the element previously at the specified position 16.25/5.30 * @throws UnsupportedOperationException if the remove operation 16.25/5.30 * is not supported by this list 16.25/5.30 * @throws IndexOutOfBoundsException if the index is out of range 16.25/5.30 * (index < 0 || index >= size()) 16.25/5.30 */ 16.25/5.30 E remove(int index); 16.25/5.30 16.25/5.30 16.25/5.30 // Search Operations 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the index of the first occurrence of the specified element 16.25/5.30 * in this list, or -1 if this list does not contain the element. 16.25/5.30 * More formally, returns the lowest index i such that 16.25/5.30 * (o==null ? get(i)==null : o.equals(get(i))), 16.25/5.30 * or -1 if there is no such index. 16.25/5.30 * 16.25/5.30 * @param o element to search for 16.25/5.30 * @return the index of the first occurrence of the specified element in 16.25/5.30 * this list, or -1 if this list does not contain the element 16.25/5.30 * @throws ClassCastException if the type of the specified element 16.25/5.30 * is incompatible with this list (optional) 16.25/5.30 * @throws NullPointerException if the specified element is null and this 16.25/5.30 * list does not permit null elements (optional) 16.25/5.30 */ 16.25/5.30 int indexOf(Object o); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns the index of the last occurrence of the specified element 16.25/5.30 * in this list, or -1 if this list does not contain the element. 16.25/5.30 * More formally, returns the highest index i such that 16.25/5.30 * (o==null ? get(i)==null : o.equals(get(i))), 16.25/5.30 * or -1 if there is no such index. 16.25/5.30 * 16.25/5.30 * @param o element to search for 16.25/5.30 * @return the index of the last occurrence of the specified element in 16.25/5.30 * this list, or -1 if this list does not contain the element 16.25/5.30 * @throws ClassCastException if the type of the specified element 16.25/5.30 * is incompatible with this list (optional) 16.25/5.30 * @throws NullPointerException if the specified element is null and this 16.25/5.30 * list does not permit null elements (optional) 16.25/5.30 */ 16.25/5.30 int lastIndexOf(Object o); 16.25/5.30 16.25/5.30 16.25/5.30 // List Iterators 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns a list iterator over the elements in this list (in proper 16.25/5.30 * sequence). 16.25/5.30 * 16.25/5.30 * @return a list iterator over the elements in this list (in proper 16.25/5.30 * sequence) 16.25/5.30 */ 16.25/5.30 ListIterator listIterator(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns a list iterator over the elements in this list (in proper 16.25/5.30 * sequence), starting at the specified position in the list. 16.25/5.30 * The specified index indicates the first element that would be 16.25/5.30 * returned by an initial call to {@link ListIterator#next next}. 16.25/5.30 * An initial call to {@link ListIterator#previous previous} would 16.25/5.30 * return the element with the specified index minus one. 16.25/5.30 * 16.25/5.30 * @param index index of the first element to be returned from the 16.25/5.30 * list iterator (by a call to {@link ListIterator#next next}) 16.25/5.30 * @return a list iterator over the elements in this list (in proper 16.25/5.30 * sequence), starting at the specified position in the list 16.25/5.30 * @throws IndexOutOfBoundsException if the index is out of range 16.25/5.30 * ({@code index < 0 || index > size()}) 16.25/5.30 */ 16.25/5.30 ListIterator listIterator(int index); 16.25/5.30 16.25/5.30 // View 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Returns a view of the portion of this list between the specified 16.25/5.30 * fromIndex, inclusive, and toIndex, exclusive. (If 16.25/5.30 * fromIndex and toIndex are equal, the returned list is 16.25/5.30 * empty.) The returned list is backed by this list, so non-structural 16.25/5.30 * changes in the returned list are reflected in this list, and vice-versa. 16.25/5.30 * The returned list supports all of the optional list operations supported 16.25/5.30 * by this list.

16.25/5.30 * 16.25/5.30 * This method eliminates the need for explicit range operations (of 16.25/5.30 * the sort that commonly exist for arrays). Any operation that expects 16.25/5.30 * a list can be used as a range operation by passing a subList view 16.25/5.30 * instead of a whole list. For example, the following idiom 16.25/5.30 * removes a range of elements from a list: 16.25/5.30 *

16.25/5.30	     *      list.subList(from, to).clear();
16.25/5.30	     * 
16.25/5.30 * Similar idioms may be constructed for indexOf and 16.25/5.30 * lastIndexOf, and all of the algorithms in the 16.25/5.30 * Collections class can be applied to a subList.

16.25/5.30 * 16.25/5.30 * The semantics of the list returned by this method become undefined if 16.25/5.30 * the backing list (i.e., this list) is structurally modified in 16.25/5.30 * any way other than via the returned list. (Structural modifications are 16.25/5.30 * those that change the size of this list, or otherwise perturb it in such 16.25/5.30 * a fashion that iterations in progress may yield incorrect results.) 16.25/5.30 * 16.25/5.30 * @param fromIndex low endpoint (inclusive) of the subList 16.25/5.30 * @param toIndex high endpoint (exclusive) of the subList 16.25/5.30 * @return a view of the specified range within this list 16.25/5.30 * @throws IndexOutOfBoundsException for an illegal endpoint index value 16.25/5.30 * (fromIndex < 0 || toIndex > size || 16.25/5.30 * fromIndex > toIndex) 16.25/5.30 */ 16.25/5.30 List subList(int fromIndex, int toIndex); 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * Copyright 1994-1998 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Thrown by the nextElement method of an 16.25/5.30 * Enumeration to indicate that there are no more 16.25/5.30 * elements in the enumeration. 16.25/5.30 * 16.25/5.30 * @author unascribed 16.25/5.30 * @see java.util.Enumeration 16.25/5.30 * @see java.util.Enumeration#nextElement() 16.25/5.30 * @since JDK1.0 16.25/5.30 */ 16.25/5.30 public 16.25/5.30 class NoSuchElementException extends RuntimeException { 16.25/5.30 /** 16.25/5.30 * Constructs a NoSuchElementException with null 16.25/5.30 * as its error message string. 16.25/5.30 */ 16.25/5.30 public NoSuchElementException() { 16.25/5.30 super(); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Constructs a NoSuchElementException, saving a reference 16.25/5.30 * to the error message string s for later retrieval by the 16.25/5.30 * getMessage method. 16.25/5.30 * 16.25/5.30 * @param s the detail message. 16.25/5.30 */ 16.25/5.30 public NoSuchElementException(String s) { 16.25/5.30 super(s); 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 /* 16.25/5.30 * This file is available under and governed by the GNU General Public 16.25/5.30 * License version 2 only, as published by the Free Software Foundation. 16.25/5.30 * However, the following notice accompanied the original version of this 16.25/5.30 * file: 16.25/5.30 * 16.25/5.30 * Written by Doug Lea with assistance from members of JCP JSR-166 16.25/5.30 * Expert Group and released to the public domain, as explained at 16.25/5.30 * http://creativecommons.org/licenses/publicdomain 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * A collection designed for holding elements prior to processing. 16.25/5.30 * Besides basic {@link java.util.Collection Collection} operations, 16.25/5.30 * queues provide additional insertion, extraction, and inspection 16.25/5.30 * operations. Each of these methods exists in two forms: one throws 16.25/5.30 * an exception if the operation fails, the other returns a special 16.25/5.30 * value (either null or false, depending on the 16.25/5.30 * operation). The latter form of the insert operation is designed 16.25/5.30 * specifically for use with capacity-restricted Queue 16.25/5.30 * implementations; in most implementations, insert operations cannot 16.25/5.30 * fail. 16.25/5.30 * 16.25/5.30 *

16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 * 16.25/5.30 *
Throws exceptionReturns special value
Insert{@link #add add(e)}{@link #offer offer(e)}
Remove{@link #remove remove()}{@link #poll poll()}
Examine{@link #element element()}{@link #peek peek()}
16.25/5.30 * 16.25/5.30 *

Queues typically, but do not necessarily, order elements in a 16.25/5.30 * FIFO (first-in-first-out) manner. Among the exceptions are 16.25/5.30 * priority queues, which order elements according to a supplied 16.25/5.30 * comparator, or the elements' natural ordering, and LIFO queues (or 16.25/5.30 * stacks) which order the elements LIFO (last-in-first-out). 16.25/5.30 * Whatever the ordering used, the head of the queue is that 16.25/5.30 * element which would be removed by a call to {@link #remove() } or 16.25/5.30 * {@link #poll()}. In a FIFO queue, all new elements are inserted at 16.25/5.30 * the tail of the queue. Other kinds of queues may use 16.25/5.30 * different placement rules. Every Queue implementation 16.25/5.30 * must specify its ordering properties. 16.25/5.30 * 16.25/5.30 *

The {@link #offer offer} method inserts an element if possible, 16.25/5.30 * otherwise returning false. This differs from the {@link 16.25/5.30 * java.util.Collection#add Collection.add} method, which can fail to 16.25/5.30 * add an element only by throwing an unchecked exception. The 16.25/5.30 * offer method is designed for use when failure is a normal, 16.25/5.30 * rather than exceptional occurrence, for example, in fixed-capacity 16.25/5.30 * (or "bounded") queues. 16.25/5.30 * 16.25/5.30 *

The {@link #remove()} and {@link #poll()} methods remove and 16.25/5.30 * return the head of the queue. 16.25/5.30 * Exactly which element is removed from the queue is a 16.25/5.30 * function of the queue's ordering policy, which differs from 16.25/5.30 * implementation to implementation. The remove() and 16.25/5.30 * poll() methods differ only in their behavior when the 16.25/5.30 * queue is empty: the remove() method throws an exception, 16.25/5.30 * while the poll() method returns null. 16.25/5.30 * 16.25/5.30 *

The {@link #element()} and {@link #peek()} methods return, but do 16.25/5.30 * not remove, the head of the queue. 16.25/5.30 * 16.25/5.30 *

The Queue interface does not define the blocking queue 16.25/5.30 * methods, which are common in concurrent programming. These methods, 16.25/5.30 * which wait for elements to appear or for space to become available, are 16.25/5.30 * defined in the {@link java.util.concurrent.BlockingQueue} interface, which 16.25/5.30 * extends this interface. 16.25/5.30 * 16.25/5.30 *

Queue implementations generally do not allow insertion 16.25/5.30 * of null elements, although some implementations, such as 16.25/5.30 * {@link LinkedList}, do not prohibit insertion of null. 16.25/5.30 * Even in the implementations that permit it, null should 16.25/5.30 * not be inserted into a Queue, as null is also 16.25/5.30 * used as a special return value by the poll method to 16.25/5.30 * indicate that the queue contains no elements. 16.25/5.30 * 16.25/5.30 *

Queue implementations generally do not define 16.25/5.30 * element-based versions of methods equals and 16.25/5.30 * hashCode but instead inherit the identity based versions 16.25/5.30 * from class Object, because element-based equality is not 16.25/5.30 * always well-defined for queues with the same elements but different 16.25/5.30 * ordering properties. 16.25/5.30 * 16.25/5.30 * 16.25/5.30 *

This interface is a member of the 16.25/5.30 * 16.25/5.30 * Java Collections Framework. 16.25/5.30 * 16.25/5.30 * @see java.util.Collection 16.25/5.30 * @see LinkedList 16.25/5.30 * @see PriorityQueue 16.25/5.30 * @see java.util.concurrent.LinkedBlockingQueue 16.25/5.30 * @see java.util.concurrent.BlockingQueue 16.25/5.30 * @see java.util.concurrent.ArrayBlockingQueue 16.25/5.30 * @see java.util.concurrent.LinkedBlockingQueue 16.25/5.30 * @see java.util.concurrent.PriorityBlockingQueue 16.25/5.30 * @since 1.5 16.25/5.30 * @author Doug Lea 16.25/5.30 * @param the type of elements held in this collection 16.25/5.30 */ 16.25/5.30 public interface Queue extends Collection { 16.25/5.30 /** 16.25/5.30 * Inserts the specified element into this queue if it is possible to do so 16.25/5.30 * immediately without violating capacity restrictions, returning 16.25/5.30 * true upon success and throwing an IllegalStateException 16.25/5.30 * if no space is currently available. 16.25/5.30 * 16.25/5.30 * @param e the element to add 16.25/5.30 * @return true (as specified by {@link Collection#add}) 16.25/5.30 * @throws IllegalStateException if the element cannot be added at this 16.25/5.30 * time due to capacity restrictions 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this queue 16.25/5.30 * @throws NullPointerException if the specified element is null and 16.25/5.30 * this queue does not permit null elements 16.25/5.30 * @throws IllegalArgumentException if some property of this element 16.25/5.30 * prevents it from being added to this queue 16.25/5.30 */ 16.25/5.30 boolean add(E e); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Inserts the specified element into this queue if it is possible to do 16.25/5.30 * so immediately without violating capacity restrictions. 16.25/5.30 * When using a capacity-restricted queue, this method is generally 16.25/5.30 * preferable to {@link #add}, which can fail to insert an element only 16.25/5.30 * by throwing an exception. 16.25/5.30 * 16.25/5.30 * @param e the element to add 16.25/5.30 * @return true if the element was added to this queue, else 16.25/5.30 * false 16.25/5.30 * @throws ClassCastException if the class of the specified element 16.25/5.30 * prevents it from being added to this queue 16.25/5.30 * @throws NullPointerException if the specified element is null and 16.25/5.30 * this queue does not permit null elements 16.25/5.30 * @throws IllegalArgumentException if some property of this element 16.25/5.30 * prevents it from being added to this queue 16.25/5.30 */ 16.25/5.30 boolean offer(E e); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves and removes the head of this queue. This method differs 16.25/5.30 * from {@link #poll poll} only in that it throws an exception if this 16.25/5.30 * queue is empty. 16.25/5.30 * 16.25/5.30 * @return the head of this queue 16.25/5.30 * @throws NoSuchElementException if this queue is empty 16.25/5.30 */ 16.25/5.30 E remove(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves and removes the head of this queue, 16.25/5.30 * or returns null if this queue is empty. 16.25/5.30 * 16.25/5.30 * @return the head of this queue, or null if this queue is empty 16.25/5.30 */ 16.25/5.30 E poll(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves, but does not remove, the head of this queue. This method 16.25/5.30 * differs from {@link #peek peek} only in that it throws an exception 16.25/5.30 * if this queue is empty. 16.25/5.30 * 16.25/5.30 * @return the head of this queue 16.25/5.30 * @throws NoSuchElementException if this queue is empty 16.25/5.30 */ 16.25/5.30 E element(); 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Retrieves, but does not remove, the head of this queue, 16.25/5.30 * or returns null if this queue is empty. 16.25/5.30 * 16.25/5.30 * @return the head of this queue, or null if this queue is empty 16.25/5.30 */ 16.25/5.30 E peek(); 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * Copyright 2000-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Marker interface used by List implementations to indicate that 16.25/5.30 * they support fast (generally constant time) random access. The primary 16.25/5.30 * purpose of this interface is to allow generic algorithms to alter their 16.25/5.30 * behavior to provide good performance when applied to either random or 16.25/5.30 * sequential access lists. 16.25/5.30 * 16.25/5.30 *

The best algorithms for manipulating random access lists (such as 16.25/5.30 * ArrayList) can produce quadratic behavior when applied to 16.25/5.30 * sequential access lists (such as LinkedList). Generic list 16.25/5.30 * algorithms are encouraged to check whether the given list is an 16.25/5.30 * instanceof this interface before applying an algorithm that would 16.25/5.30 * provide poor performance if it were applied to a sequential access list, 16.25/5.30 * and to alter their behavior if necessary to guarantee acceptable 16.25/5.30 * performance. 16.25/5.30 * 16.25/5.30 *

It is recognized that the distinction between random and sequential 16.25/5.30 * access is often fuzzy. For example, some List implementations 16.25/5.30 * provide asymptotically linear access times if they get huge, but constant 16.25/5.30 * access times in practice. Such a List implementation 16.25/5.30 * should generally implement this interface. As a rule of thumb, a 16.25/5.30 * List implementation should implement this interface if, 16.25/5.30 * for typical instances of the class, this loop: 16.25/5.30 *

16.25/5.30	 *     for (int i=0, n=list.size(); i < n; i++)
16.25/5.30	 *         list.get(i);
16.25/5.30	 * 
16.25/5.30 * runs faster than this loop: 16.25/5.30 *
16.25/5.30	 *     for (Iterator i=list.iterator(); i.hasNext(); )
16.25/5.30	 *         i.next();
16.25/5.30	 * 
16.25/5.30 * 16.25/5.30 *

This interface is a member of the 16.25/5.30 * 16.25/5.30 * Java Collections Framework. 16.25/5.30 * 16.25/5.30 * @since 1.4 16.25/5.30 */ 16.25/5.30 public interface RandomAccess { 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 public class Random { 16.25/5.30 static String[] args; 16.25/5.30 static int index = 0; 16.25/5.30 16.25/5.30 public static int random() { 16.25/5.30 String string = args[index]; 16.25/5.30 index++; 16.25/5.30 return string.length(); 16.25/5.30 } 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 /* 16.25/5.30 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.30 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.30 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.30 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.30 * accompanied this code). 16.25/5.30 * 16.25/5.30 * You should have received a copy of the GNU General Public License version 16.25/5.30 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.30 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.30 * 16.25/5.30 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.30 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.30 * have any questions. 16.25/5.30 */ 16.25/5.30 16.25/5.30 package javaUtilEx; 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Thrown to indicate that the requested operation is not supported.

16.25/5.30 * 16.25/5.30 * This class is a member of the 16.25/5.30 * 16.25/5.30 * Java Collections Framework. 16.25/5.30 * 16.25/5.30 * @author Josh Bloch 16.25/5.30 * @since 1.2 16.25/5.30 */ 16.25/5.30 public class UnsupportedOperationException extends RuntimeException { 16.25/5.30 /** 16.25/5.30 * Constructs an UnsupportedOperationException with no detail message. 16.25/5.30 */ 16.25/5.30 public UnsupportedOperationException() { 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Constructs an UnsupportedOperationException with the specified 16.25/5.30 * detail message. 16.25/5.30 * 16.25/5.30 * @param message the detail message 16.25/5.30 */ 16.25/5.30 public UnsupportedOperationException(String message) { 16.25/5.30 super(message); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Constructs a new exception with the specified detail message and 16.25/5.30 * cause. 16.25/5.30 * 16.25/5.30 *

Note that the detail message associated with cause is 16.25/5.30 * not automatically incorporated in this exception's detail 16.25/5.30 * message. 16.25/5.30 * 16.25/5.30 * @param message the detail message (which is saved for later retrieval 16.25/5.30 * by the {@link Throwable#getMessage()} method). 16.25/5.30 * @param cause the cause (which is saved for later retrieval by the 16.25/5.30 * {@link Throwable#getCause()} method). (A null value 16.25/5.30 * is permitted, and indicates that the cause is nonexistent or 16.25/5.30 * unknown.) 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public UnsupportedOperationException(String message, Throwable cause) { 16.25/5.30 super(message, cause); 16.25/5.30 } 16.25/5.30 16.25/5.30 /** 16.25/5.30 * Constructs a new exception with the specified cause and a detail 16.25/5.30 * message of (cause==null ? null : cause.toString()) (which 16.25/5.30 * typically contains the class and detail message of cause). 16.25/5.30 * This constructor is useful for exceptions that are little more than 16.25/5.30 * wrappers for other throwables (for example, {@link 16.25/5.30 * java.security.PrivilegedActionException}). 16.25/5.30 * 16.25/5.30 * @param cause the cause (which is saved for later retrieval by the 16.25/5.30 * {@link Throwable#getCause()} method). (A null value is 16.25/5.30 * permitted, and indicates that the cause is nonexistent or 16.25/5.30 * unknown.) 16.25/5.30 * @since 1.5 16.25/5.30 */ 16.25/5.30 public UnsupportedOperationException(Throwable cause) { 16.25/5.30 super(cause); 16.25/5.30 } 16.25/5.30 16.25/5.30 static final long serialVersionUID = -1242599979055084673L; 16.25/5.30 } 16.25/5.30 16.25/5.30 16.25/5.30 16.25/5.30 ---------------------------------------- 16.25/5.30 16.25/5.30 (1) BareJBCToJBCProof (EQUIVALENT) 16.25/5.30 initialized classpath 16.25/5.30 ---------------------------------------- 16.25/5.30 16.25/5.30 (2) 16.25/5.30 Obligation: 16.25/5.30 need to prove termination of the following program: 16.25/5.30 /* 16.25/5.30 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.30 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.30 * 16.25/5.30 * This code is free software; you can redistribute it and/or modify it 16.25/5.30 * under the terms of the GNU General Public License version 2 only, as 16.25/5.30 * published by the Free Software Foundation. Sun designates this 16.25/5.30 * particular file as subject to the "Classpath" exception as provided 16.25/5.30 * by Sun in the LICENSE file that accompanied this code. 16.25/5.30 * 16.25/5.30 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.31 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.31 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.31 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.31 * accompanied this code). 16.25/5.31 * 16.25/5.31 * You should have received a copy of the GNU General Public License version 16.25/5.31 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.31 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.31 * 16.25/5.31 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.31 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.31 * have any questions. 16.25/5.31 */ 16.25/5.31 16.25/5.31 package javaUtilEx; 16.25/5.31 16.25/5.31 /** 16.25/5.31 * This class provides a skeletal implementation of the Collection 16.25/5.31 * interface, to minimize the effort required to implement this interface.

16.25/5.31 * 16.25/5.31 * To implement an unmodifiable collection, the programmer needs only to 16.25/5.31 * extend this class and provide implementations for the iterator and 16.25/5.31 * size methods. (The iterator returned by the iterator 16.25/5.31 * method must implement hasNext and next.)

16.25/5.31 * 16.25/5.31 * To implement a modifiable collection, the programmer must additionally 16.25/5.31 * override this class's add method (which otherwise throws an 16.25/5.31 * UnsupportedOperationException), and the iterator returned by the 16.25/5.31 * iterator method must additionally implement its remove 16.25/5.31 * method.

16.25/5.31 * 16.25/5.31 * The programmer should generally provide a void (no argument) and 16.25/5.31 * Collection constructor, as per the recommendation in the 16.25/5.31 * Collection interface specification.

16.25/5.31 * 16.25/5.31 * The documentation for each non-abstract method in this class describes its 16.25/5.31 * implementation in detail. Each of these methods may be overridden if 16.25/5.31 * the collection being implemented admits a more efficient implementation.

16.25/5.31 * 16.25/5.31 * This class is a member of the 16.25/5.31 * 16.25/5.31 * Java Collections Framework. 16.25/5.31 * 16.25/5.31 * @author Josh Bloch 16.25/5.31 * @author Neal Gafter 16.25/5.31 * @see Collection 16.25/5.31 * @since 1.2 16.25/5.31 */ 16.25/5.31 16.25/5.31 public abstract class AbstractCollection implements Collection { 16.25/5.31 /** 16.25/5.31 * Sole constructor. (For invocation by subclass constructors, typically 16.25/5.31 * implicit.) 16.25/5.31 */ 16.25/5.31 protected AbstractCollection() { 16.25/5.31 } 16.25/5.31 16.25/5.31 // Query Operations 16.25/5.31 16.25/5.31 /** 16.25/5.31 * Returns an iterator over the elements contained in this collection. 16.25/5.31 * 16.25/5.31 * @return an iterator over the elements contained in this collection 16.25/5.31 */ 16.25/5.31 public abstract Iterator iterator(); 16.25/5.31 16.25/5.31 public abstract int size(); 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation returns size() == 0. 16.25/5.31 */ 16.25/5.31 public boolean isEmpty() { 16.25/5.31 return size() == 0; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over the elements in the collection, 16.25/5.31 * checking each element in turn for equality with the specified element. 16.25/5.31 * 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public boolean contains(Object o) { 16.25/5.31 Iterator e = iterator(); 16.25/5.31 if (o==null) { 16.25/5.31 while (e.hasNext()) 16.25/5.31 if (e.next()==null) 16.25/5.31 return true; 16.25/5.31 } else { 16.25/5.31 while (e.hasNext()) 16.25/5.31 if (o.equals(e.next())) 16.25/5.31 return true; 16.25/5.31 } 16.25/5.31 return false; 16.25/5.31 } 16.25/5.31 16.25/5.31 // Modification Operations 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation always throws an 16.25/5.31 * UnsupportedOperationException. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.31 * @throws IllegalStateException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public boolean add(E e) { 16.25/5.31 throw new UnsupportedOperationException(); 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over the collection looking for the 16.25/5.31 * specified element. If it finds the element, it removes the element 16.25/5.31 * from the collection using the iterator's remove method. 16.25/5.31 * 16.25/5.31 *

Note that this implementation throws an 16.25/5.31 * UnsupportedOperationException if the iterator returned by this 16.25/5.31 * collection's iterator method does not implement the remove 16.25/5.31 * method and this collection contains the specified object. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public boolean remove(Object o) { 16.25/5.31 Iterator e = iterator(); 16.25/5.31 if (o==null) { 16.25/5.31 while (e.hasNext()) { 16.25/5.31 if (e.next()==null) { 16.25/5.31 e.remove(); 16.25/5.31 return true; 16.25/5.31 } 16.25/5.31 } 16.25/5.31 } else { 16.25/5.31 while (e.hasNext()) { 16.25/5.31 if (o.equals(e.next())) { 16.25/5.31 e.remove(); 16.25/5.31 return true; 16.25/5.31 } 16.25/5.31 } 16.25/5.31 } 16.25/5.31 return false; 16.25/5.31 } 16.25/5.31 16.25/5.31 16.25/5.31 // Bulk Operations 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over the specified collection, 16.25/5.31 * checking each element returned by the iterator in turn to see 16.25/5.31 * if it's contained in this collection. If all elements are so 16.25/5.31 * contained true is returned, otherwise false. 16.25/5.31 * 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * @see #contains(Object) 16.25/5.31 */ 16.25/5.31 public boolean containsAll(Collection c) { 16.25/5.31 Iterator e = c.iterator(); 16.25/5.31 while (e.hasNext()) 16.25/5.31 if (!contains(e.next())) 16.25/5.31 return false; 16.25/5.31 return true; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over the specified collection, and adds 16.25/5.31 * each object returned by the iterator to this collection, in turn. 16.25/5.31 * 16.25/5.31 *

Note that this implementation will throw an 16.25/5.31 * UnsupportedOperationException unless add is 16.25/5.31 * overridden (assuming the specified collection is non-empty). 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.31 * @throws IllegalStateException {@inheritDoc} 16.25/5.31 * 16.25/5.31 * @see #add(Object) 16.25/5.31 */ 16.25/5.31 public boolean addAll(Collection c) { 16.25/5.31 boolean modified = false; 16.25/5.31 Iterator e = c.iterator(); 16.25/5.31 while (e.hasNext()) { 16.25/5.31 if (add(e.next())) 16.25/5.31 modified = true; 16.25/5.31 } 16.25/5.31 return modified; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over this collection, checking each 16.25/5.31 * element returned by the iterator in turn to see if it's contained 16.25/5.31 * in the specified collection. If it's so contained, it's removed from 16.25/5.31 * this collection with the iterator's remove method. 16.25/5.31 * 16.25/5.31 *

Note that this implementation will throw an 16.25/5.31 * UnsupportedOperationException if the iterator returned by the 16.25/5.31 * iterator method does not implement the remove method 16.25/5.31 * and this collection contains one or more elements in common with the 16.25/5.31 * specified collection. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * 16.25/5.31 * @see #remove(Object) 16.25/5.31 * @see #contains(Object) 16.25/5.31 */ 16.25/5.31 public boolean removeAll(Collection c) { 16.25/5.31 boolean modified = false; 16.25/5.31 Iterator e = iterator(); 16.25/5.31 while (e.hasNext()) { 16.25/5.31 if (c.contains(e.next())) { 16.25/5.31 e.remove(); 16.25/5.31 modified = true; 16.25/5.31 } 16.25/5.31 } 16.25/5.31 return modified; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over this collection, checking each 16.25/5.31 * element returned by the iterator in turn to see if it's contained 16.25/5.31 * in the specified collection. If it's not so contained, it's removed 16.25/5.31 * from this collection with the iterator's remove method. 16.25/5.31 * 16.25/5.31 *

Note that this implementation will throw an 16.25/5.31 * UnsupportedOperationException if the iterator returned by the 16.25/5.31 * iterator method does not implement the remove method 16.25/5.31 * and this collection contains one or more elements not present in the 16.25/5.31 * specified collection. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * 16.25/5.31 * @see #remove(Object) 16.25/5.31 * @see #contains(Object) 16.25/5.31 */ 16.25/5.31 public boolean retainAll(Collection c) { 16.25/5.31 boolean modified = false; 16.25/5.31 Iterator e = iterator(); 16.25/5.31 while (e.hasNext()) { 16.25/5.31 if (!c.contains(e.next())) { 16.25/5.31 e.remove(); 16.25/5.31 modified = true; 16.25/5.31 } 16.25/5.31 } 16.25/5.31 return modified; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation iterates over this collection, removing each 16.25/5.31 * element using the Iterator.remove operation. Most 16.25/5.31 * implementations will probably choose to override this method for 16.25/5.31 * efficiency. 16.25/5.31 * 16.25/5.31 *

Note that this implementation will throw an 16.25/5.31 * UnsupportedOperationException if the iterator returned by this 16.25/5.31 * collection's iterator method does not implement the 16.25/5.31 * remove method and this collection is non-empty. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public void clear() { 16.25/5.31 Iterator e = iterator(); 16.25/5.31 while (e.hasNext()) { 16.25/5.31 e.next(); 16.25/5.31 e.remove(); 16.25/5.31 } 16.25/5.31 } 16.25/5.31 16.25/5.31 16.25/5.31 // String conversion 16.25/5.31 16.25/5.31 /** 16.25/5.31 * Returns a string representation of this collection. The string 16.25/5.31 * representation consists of a list of the collection's elements in the 16.25/5.31 * order they are returned by its iterator, enclosed in square brackets 16.25/5.31 * ("[]"). Adjacent elements are separated by the characters 16.25/5.31 * ", " (comma and space). Elements are converted to strings as 16.25/5.31 * by {@link String#valueOf(Object)}. 16.25/5.31 * 16.25/5.31 * @return a string representation of this collection 16.25/5.31 */ 16.25/5.31 public String toString() { 16.25/5.31 Iterator i = iterator(); 16.25/5.31 if (! i.hasNext()) 16.25/5.31 return "[]"; 16.25/5.31 16.25/5.31 String sb = ""; 16.25/5.31 sb = sb + "["; 16.25/5.31 for (;;) { 16.25/5.31 E e = i.next(); 16.25/5.31 sb = sb + (e == this ? "(this Collection)" : e); 16.25/5.31 if (! i.hasNext()) { 16.25/5.31 sb = sb + "]"; 16.25/5.31 return sb; 16.25/5.31 } 16.25/5.31 sb = sb + ", "; 16.25/5.31 } 16.25/5.31 } 16.25/5.31 16.25/5.31 } 16.25/5.31 16.25/5.31 16.25/5.31 /* 16.25/5.31 * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 16.25/5.31 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.25/5.31 * 16.25/5.31 * This code is free software; you can redistribute it and/or modify it 16.25/5.31 * under the terms of the GNU General Public License version 2 only, as 16.25/5.31 * published by the Free Software Foundation. Sun designates this 16.25/5.31 * particular file as subject to the "Classpath" exception as provided 16.25/5.31 * by Sun in the LICENSE file that accompanied this code. 16.25/5.31 * 16.25/5.31 * This code is distributed in the hope that it will be useful, but WITHOUT 16.25/5.31 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.25/5.31 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.25/5.31 * version 2 for more details (a copy is included in the LICENSE file that 16.25/5.31 * accompanied this code). 16.25/5.31 * 16.25/5.31 * You should have received a copy of the GNU General Public License version 16.25/5.31 * 2 along with this work; if not, write to the Free Software Foundation, 16.25/5.31 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.25/5.31 * 16.25/5.31 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.25/5.31 * CA 95054 USA or visit www.sun.com if you need additional information or 16.25/5.31 * have any questions. 16.25/5.31 */ 16.25/5.31 16.25/5.31 package javaUtilEx; 16.25/5.31 16.25/5.31 /** 16.25/5.31 * This class provides a skeletal implementation of the {@link List} 16.25/5.31 * interface to minimize the effort required to implement this interface 16.25/5.31 * backed by a "random access" data store (such as an array). For sequential 16.25/5.31 * access data (such as a linked list), {@link AbstractSequentialList} should 16.25/5.31 * be used in preference to this class. 16.25/5.31 * 16.25/5.31 *

To implement an unmodifiable list, the programmer needs only to extend 16.25/5.31 * this class and provide implementations for the {@link #get(int)} and 16.25/5.31 * {@link List#size() size()} methods. 16.25/5.31 * 16.25/5.31 *

To implement a modifiable list, the programmer must additionally 16.25/5.31 * override the {@link #set(int, Object) set(int, E)} method (which otherwise 16.25/5.31 * throws an {@code UnsupportedOperationException}). If the list is 16.25/5.31 * variable-size the programmer must additionally override the 16.25/5.31 * {@link #add(int, Object) add(int, E)} and {@link #remove(int)} methods. 16.25/5.31 * 16.25/5.31 *

The programmer should generally provide a void (no argument) and collection 16.25/5.31 * constructor, as per the recommendation in the {@link Collection} interface 16.25/5.31 * specification. 16.25/5.31 * 16.25/5.31 *

Unlike the other abstract collection implementations, the programmer does 16.25/5.31 * not have to provide an iterator implementation; the iterator and 16.25/5.31 * list iterator are implemented by this class, on top of the "random access" 16.25/5.31 * methods: 16.25/5.31 * {@link #get(int)}, 16.25/5.31 * {@link #set(int, Object) set(int, E)}, 16.25/5.31 * {@link #add(int, Object) add(int, E)} and 16.25/5.31 * {@link #remove(int)}. 16.25/5.31 * 16.25/5.31 *

The documentation for each non-abstract method in this class describes its 16.25/5.31 * implementation in detail. Each of these methods may be overridden if the 16.25/5.31 * collection being implemented admits a more efficient implementation. 16.25/5.31 * 16.25/5.31 *

This class is a member of the 16.25/5.31 * 16.25/5.31 * Java Collections Framework. 16.25/5.31 * 16.25/5.31 * @author Josh Bloch 16.25/5.31 * @author Neal Gafter 16.25/5.31 * @since 1.2 16.25/5.31 */ 16.25/5.31 16.25/5.31 public abstract class AbstractList extends AbstractCollection implements List { 16.25/5.31 /** 16.25/5.31 * Sole constructor. (For invocation by subclass constructors, typically 16.25/5.31 * implicit.) 16.25/5.31 */ 16.25/5.31 protected AbstractList() { 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * Appends the specified element to the end of this list (optional 16.25/5.31 * operation). 16.25/5.31 * 16.25/5.31 *

Lists that support this operation may place limitations on what 16.25/5.31 * elements may be added to this list. In particular, some 16.25/5.31 * lists will refuse to add null elements, and others will impose 16.25/5.31 * restrictions on the type of elements that may be added. List 16.25/5.31 * classes should clearly specify in their documentation any restrictions 16.25/5.31 * on what elements may be added. 16.25/5.31 * 16.25/5.31 *

This implementation calls {@code add(size(), e)}. 16.25/5.31 * 16.25/5.31 *

Note that this implementation throws an 16.25/5.31 * {@code UnsupportedOperationException} unless 16.25/5.31 * {@link #add(int, Object) add(int, E)} is overridden. 16.25/5.31 * 16.25/5.31 * @param e element to be appended to this list 16.25/5.31 * @return {@code true} (as specified by {@link Collection#add}) 16.25/5.31 * @throws UnsupportedOperationException if the {@code add} operation 16.25/5.31 * is not supported by this list 16.25/5.31 * @throws ClassCastException if the class of the specified element 16.25/5.31 * prevents it from being added to this list 16.25/5.31 * @throws NullPointerException if the specified element is null and this 16.25/5.31 * list does not permit null elements 16.25/5.31 * @throws IllegalArgumentException if some property of this element 16.25/5.31 * prevents it from being added to this list 16.25/5.31 */ 16.25/5.31 public boolean add(E e) { 16.25/5.31 add(size(), e); 16.25/5.31 return true; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 abstract public E get(int index); 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation always throws an 16.25/5.31 * {@code UnsupportedOperationException}. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public E set(int index, E element) { 16.25/5.31 throw new UnsupportedOperationException(); 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation always throws an 16.25/5.31 * {@code UnsupportedOperationException}. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.25/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public void add(int index, E element) { 16.25/5.31 throw new UnsupportedOperationException(); 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation always throws an 16.25/5.31 * {@code UnsupportedOperationException}. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public E remove(int index) { 16.25/5.31 throw new UnsupportedOperationException(); 16.25/5.31 } 16.25/5.31 16.25/5.31 16.25/5.31 // Search Operations 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation first gets a list iterator (with 16.25/5.31 * {@code listIterator()}). Then, it iterates over the list until the 16.25/5.31 * specified element is found or the end of the list is reached. 16.25/5.31 * 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public int indexOf(Object o) { 16.25/5.31 ListIterator e = listIterator(); 16.25/5.31 if (o==null) { 16.25/5.31 while (e.hasNext()) 16.25/5.31 if (e.next()==null) 16.25/5.31 return e.previousIndex(); 16.25/5.31 } else { 16.25/5.31 while (e.hasNext()) 16.25/5.31 if (o.equals(e.next())) 16.25/5.31 return e.previousIndex(); 16.25/5.31 } 16.25/5.31 return -1; 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation first gets a list iterator that points to the end 16.25/5.31 * of the list (with {@code listIterator(size())}). Then, it iterates 16.25/5.31 * backwards over the list until the specified element is found, or the 16.25/5.31 * beginning of the list is reached. 16.25/5.31 * 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.25/5.31 */ 16.25/5.31 public int lastIndexOf(Object o) { 16.25/5.31 ListIterator e = listIterator(size()); 16.25/5.31 if (o==null) { 16.25/5.31 while (e.hasPrevious()) 16.25/5.31 if (e.previous()==null) 16.25/5.31 return e.nextIndex(); 16.25/5.31 } else { 16.25/5.31 while (e.hasPrevious()) 16.25/5.31 if (o.equals(e.previous())) 16.25/5.31 return e.nextIndex(); 16.25/5.31 } 16.25/5.31 return -1; 16.25/5.31 } 16.25/5.31 16.25/5.31 16.25/5.31 // Bulk Operations 16.25/5.31 16.25/5.31 /** 16.25/5.31 * Removes all of the elements from this list (optional operation). 16.25/5.31 * The list will be empty after this call returns. 16.25/5.31 * 16.25/5.31 *

This implementation calls {@code removeRange(0, size())}. 16.25/5.31 * 16.25/5.31 *

Note that this implementation throws an 16.25/5.31 * {@code UnsupportedOperationException} unless {@code remove(int 16.25/5.31 * index)} or {@code removeRange(int fromIndex, int toIndex)} is 16.25/5.31 * overridden. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException if the {@code clear} operation 16.25/5.31 * is not supported by this list 16.25/5.31 */ 16.25/5.31 public void clear() { 16.25/5.31 removeRange(0, size()); 16.25/5.31 } 16.25/5.31 16.25/5.31 /** 16.25/5.31 * {@inheritDoc} 16.25/5.31 * 16.25/5.31 *

This implementation gets an iterator over the specified collection 16.25/5.31 * and iterates over it, inserting the elements obtained from the 16.25/5.31 * iterator into this list at the appropriate position, one at a time, 16.25/5.31 * using {@code add(int, E)}. 16.25/5.31 * Many implementations will override this method for efficiency. 16.25/5.31 * 16.25/5.31 *

Note that this implementation throws an 16.25/5.31 * {@code UnsupportedOperationException} unless 16.25/5.31 * {@link #add(int, Object) add(int, E)} is overridden. 16.25/5.31 * 16.25/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.25/5.31 * @throws ClassCastException {@inheritDoc} 16.25/5.31 * @throws NullPointerException {@inheritDoc} 16.33/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public boolean addAll(int index, Collection c) { 16.33/5.31 rangeCheckForAdd(index); 16.33/5.31 boolean modified = false; 16.33/5.31 Iterator e = c.iterator(); 16.33/5.31 while (e.hasNext()) { 16.33/5.31 add(index++, e.next()); 16.33/5.31 modified = true; 16.33/5.31 } 16.33/5.31 return modified; 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 // Iterators 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns an iterator over the elements in this list in proper sequence. 16.33/5.31 * 16.33/5.31 *

This implementation returns a straightforward implementation of the 16.33/5.31 * iterator interface, relying on the backing list's {@code size()}, 16.33/5.31 * {@code get(int)}, and {@code remove(int)} methods. 16.33/5.31 * 16.33/5.31 *

Note that the iterator returned by this method will throw an 16.33/5.31 * {@link UnsupportedOperationException} in response to its 16.33/5.31 * {@code remove} method unless the list's {@code remove(int)} method is 16.33/5.31 * overridden. 16.33/5.31 * 16.33/5.31 *

This implementation can be made to throw runtime exceptions in the 16.33/5.31 * face of concurrent modification, as described in the specification 16.33/5.31 * for the (protected) {@link #modCount} field. 16.33/5.31 * 16.33/5.31 * @return an iterator over the elements in this list in proper sequence 16.33/5.31 */ 16.33/5.31 public Iterator iterator() { 16.33/5.31 return new Itr(); 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * {@inheritDoc} 16.33/5.31 * 16.33/5.31 *

This implementation returns {@code listIterator(0)}. 16.33/5.31 * 16.33/5.31 * @see #listIterator(int) 16.33/5.31 */ 16.33/5.31 public ListIterator listIterator() { 16.33/5.31 return listIterator(0); 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * {@inheritDoc} 16.33/5.31 * 16.33/5.31 *

This implementation returns a straightforward implementation of the 16.33/5.31 * {@code ListIterator} interface that extends the implementation of the 16.33/5.31 * {@code Iterator} interface returned by the {@code iterator()} method. 16.33/5.31 * The {@code ListIterator} implementation relies on the backing list's 16.33/5.31 * {@code get(int)}, {@code set(int, E)}, {@code add(int, E)} 16.33/5.31 * and {@code remove(int)} methods. 16.33/5.31 * 16.33/5.31 *

Note that the list iterator returned by this implementation will 16.33/5.31 * throw an {@link UnsupportedOperationException} in response to its 16.33/5.31 * {@code remove}, {@code set} and {@code add} methods unless the 16.33/5.31 * list's {@code remove(int)}, {@code set(int, E)}, and 16.33/5.31 * {@code add(int, E)} methods are overridden. 16.33/5.31 * 16.33/5.31 *

This implementation can be made to throw runtime exceptions in the 16.33/5.31 * face of concurrent modification, as described in the specification for 16.33/5.31 * the (protected) {@link #modCount} field. 16.33/5.31 * 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public ListIterator listIterator(final int index) { 16.33/5.31 rangeCheckForAdd(index); 16.33/5.31 16.33/5.31 return new ListItr(index); 16.33/5.31 } 16.33/5.31 16.33/5.31 private class Itr implements Iterator { 16.33/5.31 /** 16.33/5.31 * Index of element to be returned by subsequent call to next. 16.33/5.31 */ 16.33/5.31 int cursor = 0; 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Index of element returned by most recent call to next or 16.33/5.31 * previous. Reset to -1 if this element is deleted by a call 16.33/5.31 * to remove. 16.33/5.31 */ 16.33/5.31 int lastRet = -1; 16.33/5.31 16.33/5.31 /** 16.33/5.31 * The modCount value that the iterator believes that the backing 16.33/5.31 * List should have. If this expectation is violated, the iterator 16.33/5.31 * has detected concurrent modification. 16.33/5.31 */ 16.33/5.31 int expectedModCount = modCount; 16.33/5.31 16.33/5.31 public boolean hasNext() { 16.33/5.31 return cursor != size(); 16.33/5.31 } 16.33/5.31 16.33/5.31 public E next() { 16.33/5.31 checkForComodification(); 16.33/5.31 try { 16.33/5.31 int i = cursor; 16.33/5.31 E next = get(i); 16.33/5.31 lastRet = i; 16.33/5.31 cursor = i + 1; 16.33/5.31 return next; 16.33/5.31 } catch (IndexOutOfBoundsException e) { 16.33/5.31 checkForComodification(); 16.33/5.31 throw new NoSuchElementException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 public void remove() { 16.33/5.31 if (lastRet < 0) 16.33/5.31 throw new IllegalStateException(); 16.33/5.31 checkForComodification(); 16.33/5.31 16.33/5.31 try { 16.33/5.31 AbstractList.this.remove(lastRet); 16.33/5.31 if (lastRet < cursor) 16.33/5.31 cursor--; 16.33/5.31 lastRet = -1; 16.33/5.31 expectedModCount = modCount; 16.33/5.31 } catch (IndexOutOfBoundsException e) { 16.33/5.31 throw new ConcurrentModificationException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 final void checkForComodification() { 16.33/5.31 if (modCount != expectedModCount) 16.33/5.31 throw new ConcurrentModificationException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 private class ListItr extends Itr implements ListIterator { 16.33/5.31 ListItr(int index) { 16.33/5.31 cursor = index; 16.33/5.31 } 16.33/5.31 16.33/5.31 public boolean hasPrevious() { 16.33/5.31 return cursor != 0; 16.33/5.31 } 16.33/5.31 16.33/5.31 public E previous() { 16.33/5.31 checkForComodification(); 16.33/5.31 try { 16.33/5.31 int i = cursor - 1; 16.33/5.31 E previous = get(i); 16.33/5.31 lastRet = cursor = i; 16.33/5.31 return previous; 16.33/5.31 } catch (IndexOutOfBoundsException e) { 16.33/5.31 checkForComodification(); 16.33/5.31 throw new NoSuchElementException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 public int nextIndex() { 16.33/5.31 return cursor; 16.33/5.31 } 16.33/5.31 16.33/5.31 public int previousIndex() { 16.33/5.31 return cursor-1; 16.33/5.31 } 16.33/5.31 16.33/5.31 public void set(E e) { 16.33/5.31 if (lastRet < 0) 16.33/5.31 throw new IllegalStateException(); 16.33/5.31 checkForComodification(); 16.33/5.31 16.33/5.31 try { 16.33/5.31 AbstractList.this.set(lastRet, e); 16.33/5.31 expectedModCount = modCount; 16.33/5.31 } catch (IndexOutOfBoundsException ex) { 16.33/5.31 throw new ConcurrentModificationException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 public void add(E e) { 16.33/5.31 checkForComodification(); 16.33/5.31 16.33/5.31 try { 16.33/5.31 int i = cursor; 16.33/5.31 AbstractList.this.add(i, e); 16.33/5.31 lastRet = -1; 16.33/5.31 cursor = i + 1; 16.33/5.31 expectedModCount = modCount; 16.33/5.31 } catch (IndexOutOfBoundsException ex) { 16.33/5.31 throw new ConcurrentModificationException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * {@inheritDoc} 16.33/5.31 * 16.33/5.31 *

This implementation returns a list that subclasses 16.33/5.31 * {@code AbstractList}. The subclass stores, in private fields, the 16.33/5.31 * offset of the subList within the backing list, the size of the subList 16.33/5.31 * (which can change over its lifetime), and the expected 16.33/5.31 * {@code modCount} value of the backing list. There are two variants 16.33/5.31 * of the subclass, one of which implements {@code RandomAccess}. 16.33/5.31 * If this list implements {@code RandomAccess} the returned list will 16.33/5.31 * be an instance of the subclass that implements {@code RandomAccess}. 16.33/5.31 * 16.33/5.31 *

The subclass's {@code set(int, E)}, {@code get(int)}, 16.33/5.31 * {@code add(int, E)}, {@code remove(int)}, {@code addAll(int, 16.33/5.31 * Collection)} and {@code removeRange(int, int)} methods all 16.33/5.31 * delegate to the corresponding methods on the backing abstract list, 16.33/5.31 * after bounds-checking the index and adjusting for the offset. The 16.33/5.31 * {@code addAll(Collection c)} method merely returns {@code addAll(size, 16.33/5.31 * c)}. 16.33/5.31 * 16.33/5.31 *

The {@code listIterator(int)} method returns a "wrapper object" 16.33/5.31 * over a list iterator on the backing list, which is created with the 16.33/5.31 * corresponding method on the backing list. The {@code iterator} method 16.33/5.31 * merely returns {@code listIterator()}, and the {@code size} method 16.33/5.31 * merely returns the subclass's {@code size} field. 16.33/5.31 * 16.33/5.31 *

All methods first check to see if the actual {@code modCount} of 16.33/5.31 * the backing list is equal to its expected value, and throw a 16.33/5.31 * {@code ConcurrentModificationException} if it is not. 16.33/5.31 * 16.33/5.31 * @throws IndexOutOfBoundsException if an endpoint index value is out of range 16.33/5.31 * {@code (fromIndex < 0 || toIndex > size)} 16.33/5.31 * @throws IllegalArgumentException if the endpoint indices are out of order 16.33/5.31 * {@code (fromIndex > toIndex)} 16.33/5.31 */ 16.33/5.31 public List subList(int fromIndex, int toIndex) { 16.33/5.31 return (this instanceof RandomAccess ? 16.33/5.31 new RandomAccessSubList(this, fromIndex, toIndex) : 16.33/5.31 new SubList(this, fromIndex, toIndex)); 16.33/5.31 } 16.33/5.31 16.33/5.31 // Comparison and hashing 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Compares the specified object with this list for equality. Returns 16.33/5.31 * {@code true} if and only if the specified object is also a list, both 16.33/5.31 * lists have the same size, and all corresponding pairs of elements in 16.33/5.31 * the two lists are equal. (Two elements {@code e1} and 16.33/5.31 * {@code e2} are equal if {@code (e1==null ? e2==null : 16.33/5.31 * e1.equals(e2))}.) In other words, two lists are defined to be 16.33/5.31 * equal if they contain the same elements in the same order.

16.33/5.31 * 16.33/5.31 * This implementation first checks if the specified object is this 16.33/5.31 * list. If so, it returns {@code true}; if not, it checks if the 16.33/5.31 * specified object is a list. If not, it returns {@code false}; if so, 16.33/5.31 * it iterates over both lists, comparing corresponding pairs of elements. 16.33/5.31 * If any comparison returns {@code false}, this method returns 16.33/5.31 * {@code false}. If either iterator runs out of elements before the 16.33/5.31 * other it returns {@code false} (as the lists are of unequal length); 16.33/5.31 * otherwise it returns {@code true} when the iterations complete. 16.33/5.31 * 16.33/5.31 * @param o the object to be compared for equality with this list 16.33/5.31 * @return {@code true} if the specified object is equal to this list 16.33/5.31 */ 16.33/5.31 public boolean equals(Object o) { 16.33/5.31 if (o == this) 16.33/5.31 return true; 16.33/5.31 if (!(o instanceof List)) 16.33/5.31 return false; 16.33/5.31 16.33/5.31 ListIterator e1 = listIterator(); 16.33/5.31 ListIterator e2 = ((List) o).listIterator(); 16.33/5.31 while(e1.hasNext() && e2.hasNext()) { 16.33/5.31 E o1 = e1.next(); 16.33/5.31 Object o2 = e2.next(); 16.33/5.31 if (!(o1==null ? o2==null : o1.equals(o2))) 16.33/5.31 return false; 16.33/5.31 } 16.33/5.31 return !(e1.hasNext() || e2.hasNext()); 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns the hash code value for this list. 16.33/5.31 * 16.33/5.31 *

This implementation uses exactly the code that is used to define the 16.33/5.31 * list hash function in the documentation for the {@link List#hashCode} 16.33/5.31 * method. 16.33/5.31 * 16.33/5.31 * @return the hash code value for this list 16.33/5.31 */ 16.33/5.31 public int hashCode() { 16.33/5.31 int hashCode = 1; 16.33/5.31 Iterator it = this.iterator(); 16.33/5.31 while (it.hasNext()) { 16.33/5.31 E e = it.next(); 16.33/5.31 hashCode = 31*hashCode + (e==null ? 0 : e.hashCode()); 16.33/5.31 } 16.33/5.31 return hashCode; 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Removes from this list all of the elements whose index is between 16.33/5.31 * {@code fromIndex}, inclusive, and {@code toIndex}, exclusive. 16.33/5.31 * Shifts any succeeding elements to the left (reduces their index). 16.33/5.31 * This call shortens the list by {@code (toIndex - fromIndex)} elements. 16.33/5.31 * (If {@code toIndex==fromIndex}, this operation has no effect.) 16.33/5.31 * 16.33/5.31 *

This method is called by the {@code clear} operation on this list 16.33/5.31 * and its subLists. Overriding this method to take advantage of 16.33/5.31 * the internals of the list implementation can substantially 16.33/5.31 * improve the performance of the {@code clear} operation on this list 16.33/5.31 * and its subLists. 16.33/5.31 * 16.33/5.31 *

This implementation gets a list iterator positioned before 16.33/5.31 * {@code fromIndex}, and repeatedly calls {@code ListIterator.next} 16.33/5.31 * followed by {@code ListIterator.remove} until the entire range has 16.33/5.31 * been removed. Note: if {@code ListIterator.remove} requires linear 16.33/5.31 * time, this implementation requires quadratic time. 16.33/5.31 * 16.33/5.31 * @param fromIndex index of first element to be removed 16.33/5.31 * @param toIndex index after last element to be removed 16.33/5.31 */ 16.33/5.31 protected void removeRange(int fromIndex, int toIndex) { 16.33/5.31 ListIterator it = listIterator(fromIndex); 16.33/5.31 for (int i=0, n=toIndex-fromIndex; istructurally modified. 16.33/5.31 * Structural modifications are those that change the size of the 16.33/5.31 * list, or otherwise perturb it in such a fashion that iterations in 16.33/5.31 * progress may yield incorrect results. 16.33/5.31 * 16.33/5.31 *

This field is used by the iterator and list iterator implementation 16.33/5.31 * returned by the {@code iterator} and {@code listIterator} methods. 16.33/5.31 * If the value of this field changes unexpectedly, the iterator (or list 16.33/5.31 * iterator) will throw a {@code ConcurrentModificationException} in 16.33/5.31 * response to the {@code next}, {@code remove}, {@code previous}, 16.33/5.31 * {@code set} or {@code add} operations. This provides 16.33/5.31 * fail-fast behavior, rather than non-deterministic behavior in 16.33/5.31 * the face of concurrent modification during iteration. 16.33/5.31 * 16.33/5.31 *

Use of this field by subclasses is optional. If a subclass 16.33/5.31 * wishes to provide fail-fast iterators (and list iterators), then it 16.33/5.31 * merely has to increment this field in its {@code add(int, E)} and 16.33/5.31 * {@code remove(int)} methods (and any other methods that it overrides 16.33/5.31 * that result in structural modifications to the list). A single call to 16.33/5.31 * {@code add(int, E)} or {@code remove(int)} must add no more than 16.33/5.31 * one to this field, or the iterators (and list iterators) will throw 16.33/5.31 * bogus {@code ConcurrentModificationExceptions}. If an implementation 16.33/5.31 * does not wish to provide fail-fast iterators, this field may be 16.33/5.31 * ignored. 16.33/5.31 */ 16.33/5.31 protected transient int modCount = 0; 16.33/5.31 16.33/5.31 private void rangeCheckForAdd(int index) { 16.33/5.31 if (index < 0 || index > size()) 16.33/5.31 throw new IndexOutOfBoundsException(outOfBoundsMsg(index)); 16.33/5.31 } 16.33/5.31 16.33/5.31 private String outOfBoundsMsg(int index) { 16.33/5.31 return ""; 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 class SubList extends AbstractList { 16.33/5.31 private final AbstractList l; 16.33/5.31 private final int offset; 16.33/5.31 private int size; 16.33/5.31 16.33/5.31 SubList(AbstractList list, int fromIndex, int toIndex) { 16.33/5.31 if (fromIndex < 0) 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 if (toIndex > list.size()) 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 if (fromIndex > toIndex) 16.33/5.31 throw new IllegalArgumentException(); 16.33/5.31 l = list; 16.33/5.31 offset = fromIndex; 16.33/5.31 size = toIndex - fromIndex; 16.33/5.31 this.modCount = l.modCount; 16.33/5.31 } 16.33/5.31 16.33/5.31 public E set(int index, E element) { 16.33/5.31 rangeCheck(index); 16.33/5.31 checkForComodification(); 16.33/5.31 return l.set(index+offset, element); 16.33/5.31 } 16.33/5.31 16.33/5.31 public E get(int index) { 16.33/5.31 rangeCheck(index); 16.33/5.31 checkForComodification(); 16.33/5.31 return l.get(index+offset); 16.33/5.31 } 16.33/5.31 16.33/5.31 public int size() { 16.33/5.31 checkForComodification(); 16.33/5.31 return size; 16.33/5.31 } 16.33/5.31 16.33/5.31 public void add(int index, E element) { 16.33/5.31 rangeCheckForAdd(index); 16.33/5.31 checkForComodification(); 16.33/5.31 l.add(index+offset, element); 16.33/5.31 this.modCount = l.modCount; 16.33/5.31 size++; 16.33/5.31 } 16.33/5.31 16.33/5.31 public E remove(int index) { 16.33/5.31 rangeCheck(index); 16.33/5.31 checkForComodification(); 16.33/5.31 E result = l.remove(index+offset); 16.33/5.31 this.modCount = l.modCount; 16.33/5.31 size--; 16.33/5.31 return result; 16.33/5.31 } 16.33/5.31 16.33/5.31 protected void removeRange(int fromIndex, int toIndex) { 16.33/5.31 checkForComodification(); 16.33/5.31 l.removeRange(fromIndex+offset, toIndex+offset); 16.33/5.31 this.modCount = l.modCount; 16.33/5.31 size -= (toIndex-fromIndex); 16.33/5.31 } 16.33/5.31 16.33/5.31 public boolean addAll(Collection c) { 16.33/5.31 return addAll(size, c); 16.33/5.31 } 16.33/5.31 16.33/5.31 public boolean addAll(int index, Collection c) { 16.33/5.31 rangeCheckForAdd(index); 16.33/5.31 int cSize = c.size(); 16.33/5.31 if (cSize==0) 16.33/5.31 return false; 16.33/5.31 16.33/5.31 checkForComodification(); 16.33/5.31 l.addAll(offset+index, c); 16.33/5.31 this.modCount = l.modCount; 16.33/5.31 size += cSize; 16.33/5.31 return true; 16.33/5.31 } 16.33/5.31 16.33/5.31 public Iterator iterator() { 16.33/5.31 return listIterator(); 16.33/5.31 } 16.33/5.31 16.33/5.31 public ListIterator listIterator(final int index) { 16.33/5.31 checkForComodification(); 16.33/5.31 rangeCheckForAdd(index); 16.33/5.31 16.33/5.31 return new ListIterator() { 16.33/5.31 private final ListIterator i = l.listIterator(index+offset); 16.33/5.31 16.33/5.31 public boolean hasNext() { 16.33/5.31 return nextIndex() < size; 16.33/5.31 } 16.33/5.31 16.33/5.31 public E next() { 16.33/5.31 if (hasNext()) 16.33/5.31 return i.next(); 16.33/5.31 else 16.33/5.31 throw new NoSuchElementException(); 16.33/5.31 } 16.33/5.31 16.33/5.31 public boolean hasPrevious() { 16.33/5.31 return previousIndex() >= 0; 16.33/5.31 } 16.33/5.31 16.33/5.31 public E previous() { 16.33/5.31 if (hasPrevious()) 16.33/5.31 return i.previous(); 16.33/5.31 else 16.33/5.31 throw new NoSuchElementException(); 16.33/5.31 } 16.33/5.31 16.33/5.31 public int nextIndex() { 16.33/5.31 return i.nextIndex() - offset; 16.33/5.31 } 16.33/5.31 16.33/5.31 public int previousIndex() { 16.33/5.31 return i.previousIndex() - offset; 16.33/5.31 } 16.33/5.31 16.33/5.31 public void remove() { 16.33/5.31 i.remove(); 16.33/5.31 SubList.this.modCount = l.modCount; 16.33/5.31 size--; 16.33/5.31 } 16.33/5.31 16.33/5.31 public void set(E e) { 16.33/5.31 i.set(e); 16.33/5.31 } 16.33/5.31 16.33/5.31 public void add(E e) { 16.33/5.31 i.add(e); 16.33/5.31 SubList.this.modCount = l.modCount; 16.33/5.31 size++; 16.33/5.31 } 16.33/5.31 }; 16.33/5.31 } 16.33/5.31 16.33/5.31 public List subList(int fromIndex, int toIndex) { 16.33/5.31 return new SubList(this, fromIndex, toIndex); 16.33/5.31 } 16.33/5.31 16.33/5.31 private void rangeCheck(int index) { 16.33/5.31 if (index < 0 || index >= size) 16.33/5.31 throw new IndexOutOfBoundsException(outOfBoundsMsg(index)); 16.33/5.31 } 16.33/5.31 16.33/5.31 private void rangeCheckForAdd(int index) { 16.33/5.31 if (index < 0 || index > size) 16.33/5.31 throw new IndexOutOfBoundsException(outOfBoundsMsg(index)); 16.33/5.31 } 16.33/5.31 16.33/5.31 private String outOfBoundsMsg(int index) { 16.33/5.31 return ""; 16.33/5.31 } 16.33/5.31 16.33/5.31 private void checkForComodification() { 16.33/5.31 if (this.modCount != l.modCount) 16.33/5.31 throw new ConcurrentModificationException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 class RandomAccessSubList extends SubList implements RandomAccess { 16.33/5.31 RandomAccessSubList(AbstractList list, int fromIndex, int toIndex) { 16.33/5.31 super(list, fromIndex, toIndex); 16.33/5.31 } 16.33/5.31 16.33/5.31 public List subList(int fromIndex, int toIndex) { 16.33/5.31 return new RandomAccessSubList(this, fromIndex, toIndex); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 /* 16.33/5.31 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.31 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.31 * 16.33/5.31 * This code is free software; you can redistribute it and/or modify it 16.33/5.31 * under the terms of the GNU General Public License version 2 only, as 16.33/5.31 * published by the Free Software Foundation. Sun designates this 16.33/5.31 * particular file as subject to the "Classpath" exception as provided 16.33/5.31 * by Sun in the LICENSE file that accompanied this code. 16.33/5.31 * 16.33/5.31 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.31 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.31 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.31 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.31 * accompanied this code). 16.33/5.31 * 16.33/5.31 * You should have received a copy of the GNU General Public License version 16.33/5.31 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.31 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.31 * 16.33/5.31 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.31 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.31 * have any questions. 16.33/5.31 */ 16.33/5.31 16.33/5.31 package javaUtilEx; 16.33/5.31 16.33/5.31 /** 16.33/5.31 * This class provides a skeletal implementation of the List 16.33/5.31 * interface to minimize the effort required to implement this interface 16.33/5.31 * backed by a "sequential access" data store (such as a linked list). For 16.33/5.31 * random access data (such as an array), AbstractList should be used 16.33/5.31 * in preference to this class.

16.33/5.31 * 16.33/5.31 * This class is the opposite of the AbstractList class in the sense 16.33/5.31 * that it implements the "random access" methods (get(int index), 16.33/5.31 * set(int index, E element), add(int index, E element) and 16.33/5.31 * remove(int index)) on top of the list's list iterator, instead of 16.33/5.31 * the other way around.

16.33/5.31 * 16.33/5.31 * To implement a list the programmer needs only to extend this class and 16.33/5.31 * provide implementations for the listIterator and size 16.33/5.31 * methods. For an unmodifiable list, the programmer need only implement the 16.33/5.31 * list iterator's hasNext, next, hasPrevious, 16.33/5.31 * previous and index methods.

16.33/5.31 * 16.33/5.31 * For a modifiable list the programmer should additionally implement the list 16.33/5.31 * iterator's set method. For a variable-size list the programmer 16.33/5.31 * should additionally implement the list iterator's remove and 16.33/5.31 * add methods.

16.33/5.31 * 16.33/5.31 * The programmer should generally provide a void (no argument) and collection 16.33/5.31 * constructor, as per the recommendation in the Collection interface 16.33/5.31 * specification.

16.33/5.31 * 16.33/5.31 * This class is a member of the 16.33/5.31 * 16.33/5.31 * Java Collections Framework. 16.33/5.31 * 16.33/5.31 * @author Josh Bloch 16.33/5.31 * @author Neal Gafter 16.33/5.31 * @see Collection 16.33/5.31 * @see List 16.33/5.31 * @see AbstractList 16.33/5.31 * @see AbstractCollection 16.33/5.31 * @since 1.2 16.33/5.31 */ 16.33/5.31 16.33/5.31 public abstract class AbstractSequentialList extends AbstractList { 16.33/5.31 /** 16.33/5.31 * Sole constructor. (For invocation by subclass constructors, typically 16.33/5.31 * implicit.) 16.33/5.31 */ 16.33/5.31 protected AbstractSequentialList() { 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns the element at the specified position in this list. 16.33/5.31 * 16.33/5.31 *

This implementation first gets a list iterator pointing to the 16.33/5.31 * indexed element (with listIterator(index)). Then, it gets 16.33/5.31 * the element using ListIterator.next and returns it. 16.33/5.31 * 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public E get(int index) { 16.33/5.31 try { 16.33/5.31 return listIterator(index).next(); 16.33/5.31 } catch (NoSuchElementException exc) { 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Replaces the element at the specified position in this list with the 16.33/5.31 * specified element (optional operation). 16.33/5.31 * 16.33/5.31 *

This implementation first gets a list iterator pointing to the 16.33/5.31 * indexed element (with listIterator(index)). Then, it gets 16.33/5.31 * the current element using ListIterator.next and replaces it 16.33/5.31 * with ListIterator.set. 16.33/5.31 * 16.33/5.31 *

Note that this implementation will throw an 16.33/5.31 * UnsupportedOperationException if the list iterator does not 16.33/5.31 * implement the set operation. 16.33/5.31 * 16.33/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.33/5.31 * @throws ClassCastException {@inheritDoc} 16.33/5.31 * @throws NullPointerException {@inheritDoc} 16.33/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public E set(int index, E element) { 16.33/5.31 try { 16.33/5.31 ListIterator e = listIterator(index); 16.33/5.31 E oldVal = e.next(); 16.33/5.31 e.set(element); 16.33/5.31 return oldVal; 16.33/5.31 } catch (NoSuchElementException exc) { 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Inserts the specified element at the specified position in this list 16.33/5.31 * (optional operation). Shifts the element currently at that position 16.33/5.31 * (if any) and any subsequent elements to the right (adds one to their 16.33/5.31 * indices). 16.33/5.31 * 16.33/5.31 *

This implementation first gets a list iterator pointing to the 16.33/5.31 * indexed element (with listIterator(index)). Then, it 16.33/5.31 * inserts the specified element with ListIterator.add. 16.33/5.31 * 16.33/5.31 *

Note that this implementation will throw an 16.33/5.31 * UnsupportedOperationException if the list iterator does not 16.33/5.31 * implement the add operation. 16.33/5.31 * 16.33/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.33/5.31 * @throws ClassCastException {@inheritDoc} 16.33/5.31 * @throws NullPointerException {@inheritDoc} 16.33/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public void add(int index, E element) { 16.33/5.31 try { 16.33/5.31 listIterator(index).add(element); 16.33/5.31 } catch (NoSuchElementException exc) { 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Removes the element at the specified position in this list (optional 16.33/5.31 * operation). Shifts any subsequent elements to the left (subtracts one 16.33/5.31 * from their indices). Returns the element that was removed from the 16.33/5.31 * list. 16.33/5.31 * 16.33/5.31 *

This implementation first gets a list iterator pointing to the 16.33/5.31 * indexed element (with listIterator(index)). Then, it removes 16.33/5.31 * the element with ListIterator.remove. 16.33/5.31 * 16.33/5.31 *

Note that this implementation will throw an 16.33/5.31 * UnsupportedOperationException if the list iterator does not 16.33/5.31 * implement the remove operation. 16.33/5.31 * 16.33/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public E remove(int index) { 16.33/5.31 try { 16.33/5.31 ListIterator e = listIterator(index); 16.33/5.31 E outCast = e.next(); 16.33/5.31 e.remove(); 16.33/5.31 return outCast; 16.33/5.31 } catch (NoSuchElementException exc) { 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 // Bulk Operations 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Inserts all of the elements in the specified collection into this 16.33/5.31 * list at the specified position (optional operation). Shifts the 16.33/5.31 * element currently at that position (if any) and any subsequent 16.33/5.31 * elements to the right (increases their indices). The new elements 16.33/5.31 * will appear in this list in the order that they are returned by the 16.33/5.31 * specified collection's iterator. The behavior of this operation is 16.33/5.31 * undefined if the specified collection is modified while the 16.33/5.31 * operation is in progress. (Note that this will occur if the specified 16.33/5.31 * collection is this list, and it's nonempty.) 16.33/5.31 * 16.33/5.31 *

This implementation gets an iterator over the specified collection and 16.33/5.31 * a list iterator over this list pointing to the indexed element (with 16.33/5.31 * listIterator(index)). Then, it iterates over the specified 16.33/5.31 * collection, inserting the elements obtained from the iterator into this 16.33/5.31 * list, one at a time, using ListIterator.add followed by 16.33/5.31 * ListIterator.next (to skip over the added element). 16.33/5.31 * 16.33/5.31 *

Note that this implementation will throw an 16.33/5.31 * UnsupportedOperationException if the list iterator returned by 16.33/5.31 * the listIterator method does not implement the add 16.33/5.31 * operation. 16.33/5.31 * 16.33/5.31 * @throws UnsupportedOperationException {@inheritDoc} 16.33/5.31 * @throws ClassCastException {@inheritDoc} 16.33/5.31 * @throws NullPointerException {@inheritDoc} 16.33/5.31 * @throws IllegalArgumentException {@inheritDoc} 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public boolean addAll(int index, Collection c) { 16.33/5.31 try { 16.33/5.31 boolean modified = false; 16.33/5.31 ListIterator e1 = listIterator(index); 16.33/5.31 Iterator e2 = c.iterator(); 16.33/5.31 while (e2.hasNext()) { 16.33/5.31 e1.add(e2.next()); 16.33/5.31 modified = true; 16.33/5.31 } 16.33/5.31 return modified; 16.33/5.31 } catch (NoSuchElementException exc) { 16.33/5.31 throw new IndexOutOfBoundsException(); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 // Iterators 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns an iterator over the elements in this list (in proper 16.33/5.31 * sequence).

16.33/5.31 * 16.33/5.31 * This implementation merely returns a list iterator over the list. 16.33/5.31 * 16.33/5.31 * @return an iterator over the elements in this list (in proper sequence) 16.33/5.31 */ 16.33/5.31 public Iterator iterator() { 16.33/5.31 return listIterator(); 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns a list iterator over the elements in this list (in proper 16.33/5.31 * sequence). 16.33/5.31 * 16.33/5.31 * @param index index of first element to be returned from the list 16.33/5.31 * iterator (by a call to the next method) 16.33/5.31 * @return a list iterator over the elements in this list (in proper 16.33/5.31 * sequence) 16.33/5.31 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.31 */ 16.33/5.31 public abstract ListIterator listIterator(int index); 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 /* 16.33/5.31 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.31 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.31 * 16.33/5.31 * This code is free software; you can redistribute it and/or modify it 16.33/5.31 * under the terms of the GNU General Public License version 2 only, as 16.33/5.31 * published by the Free Software Foundation. Sun designates this 16.33/5.31 * particular file as subject to the "Classpath" exception as provided 16.33/5.31 * by Sun in the LICENSE file that accompanied this code. 16.33/5.31 * 16.33/5.31 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.31 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.31 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.31 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.31 * accompanied this code). 16.33/5.31 * 16.33/5.31 * You should have received a copy of the GNU General Public License version 16.33/5.31 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.31 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.31 * 16.33/5.31 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.31 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.31 * have any questions. 16.33/5.31 */ 16.33/5.31 16.33/5.31 package javaUtilEx; 16.33/5.31 16.33/5.31 /** 16.33/5.31 * The root interface in the collection hierarchy. A collection 16.33/5.31 * represents a group of objects, known as its elements. Some 16.33/5.31 * collections allow duplicate elements and others do not. Some are ordered 16.33/5.31 * and others unordered. The JDK does not provide any direct 16.33/5.31 * implementations of this interface: it provides implementations of more 16.33/5.31 * specific subinterfaces like Set and List. This interface 16.33/5.31 * is typically used to pass collections around and manipulate them where 16.33/5.31 * maximum generality is desired. 16.33/5.31 * 16.33/5.31 *

Bags or multisets (unordered collections that may contain 16.33/5.31 * duplicate elements) should implement this interface directly. 16.33/5.31 * 16.33/5.31 *

All general-purpose Collection implementation classes (which 16.33/5.31 * typically implement Collection indirectly through one of its 16.33/5.31 * subinterfaces) should provide two "standard" constructors: a void (no 16.33/5.31 * arguments) constructor, which creates an empty collection, and a 16.33/5.31 * constructor with a single argument of type Collection, which 16.33/5.31 * creates a new collection with the same elements as its argument. In 16.33/5.31 * effect, the latter constructor allows the user to copy any collection, 16.33/5.31 * producing an equivalent collection of the desired implementation type. 16.33/5.31 * There is no way to enforce this convention (as interfaces cannot contain 16.33/5.31 * constructors) but all of the general-purpose Collection 16.33/5.31 * implementations in the Java platform libraries comply. 16.33/5.31 * 16.33/5.31 *

The "destructive" methods contained in this interface, that is, the 16.33/5.31 * methods that modify the collection on which they operate, are specified to 16.33/5.31 * throw UnsupportedOperationException if this collection does not 16.33/5.31 * support the operation. If this is the case, these methods may, but are not 16.33/5.31 * required to, throw an UnsupportedOperationException if the 16.33/5.31 * invocation would have no effect on the collection. For example, invoking 16.33/5.31 * the {@link #addAll(Collection)} method on an unmodifiable collection may, 16.33/5.31 * but is not required to, throw the exception if the collection to be added 16.33/5.31 * is empty. 16.33/5.31 * 16.33/5.31 *

Some collection implementations have restrictions on the elements that 16.33/5.31 * they may contain. For example, some implementations prohibit null elements, 16.33/5.31 * and some have restrictions on the types of their elements. Attempting to 16.33/5.31 * add an ineligible element throws an unchecked exception, typically 16.33/5.31 * NullPointerException or ClassCastException. Attempting 16.33/5.31 * to query the presence of an ineligible element may throw an exception, 16.33/5.31 * or it may simply return false; some implementations will exhibit the former 16.33/5.31 * behavior and some will exhibit the latter. More generally, attempting an 16.33/5.31 * operation on an ineligible element whose completion would not result in 16.33/5.31 * the insertion of an ineligible element into the collection may throw an 16.33/5.31 * exception or it may succeed, at the option of the implementation. 16.33/5.31 * Such exceptions are marked as "optional" in the specification for this 16.33/5.31 * interface. 16.33/5.31 * 16.33/5.31 *

It is up to each collection to determine its own synchronization 16.33/5.31 * policy. In the absence of a stronger guarantee by the 16.33/5.31 * implementation, undefined behavior may result from the invocation 16.33/5.31 * of any method on a collection that is being mutated by another 16.33/5.31 * thread; this includes direct invocations, passing the collection to 16.33/5.31 * a method that might perform invocations, and using an existing 16.33/5.31 * iterator to examine the collection. 16.33/5.31 * 16.33/5.31 *

Many methods in Collections Framework interfaces are defined in 16.33/5.31 * terms of the {@link Object#equals(Object) equals} method. For example, 16.33/5.31 * the specification for the {@link #contains(Object) contains(Object o)} 16.33/5.31 * method says: "returns true if and only if this collection 16.33/5.31 * contains at least one element e such that 16.33/5.31 * (o==null ? e==null : o.equals(e))." This specification should 16.33/5.31 * not be construed to imply that invoking Collection.contains 16.33/5.31 * with a non-null argument o will cause o.equals(e) to be 16.33/5.31 * invoked for any element e. Implementations are free to implement 16.33/5.31 * optimizations whereby the equals invocation is avoided, for 16.33/5.31 * example, by first comparing the hash codes of the two elements. (The 16.33/5.31 * {@link Object#hashCode()} specification guarantees that two objects with 16.33/5.31 * unequal hash codes cannot be equal.) More generally, implementations of 16.33/5.31 * the various Collections Framework interfaces are free to take advantage of 16.33/5.31 * the specified behavior of underlying {@link Object} methods wherever the 16.33/5.31 * implementor deems it appropriate. 16.33/5.31 * 16.33/5.31 *

This interface is a member of the 16.33/5.31 * 16.33/5.31 * Java Collections Framework. 16.33/5.31 * 16.33/5.31 * @author Josh Bloch 16.33/5.31 * @author Neal Gafter 16.33/5.31 * @see Set 16.33/5.31 * @see List 16.33/5.31 * @see Map 16.33/5.31 * @see SortedSet 16.33/5.31 * @see SortedMap 16.33/5.31 * @see HashSet 16.33/5.31 * @see TreeSet 16.33/5.31 * @see ArrayList 16.33/5.31 * @see LinkedList 16.33/5.31 * @see Vector 16.33/5.31 * @see Collections 16.33/5.31 * @see Arrays 16.33/5.31 * @see AbstractCollection 16.33/5.31 * @since 1.2 16.33/5.31 */ 16.33/5.31 16.33/5.31 public interface Collection { 16.33/5.31 // Query Operations 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns the number of elements in this collection. If this collection 16.33/5.31 * contains more than Integer.MAX_VALUE elements, returns 16.33/5.31 * Integer.MAX_VALUE. 16.33/5.31 * 16.33/5.31 * @return the number of elements in this collection 16.33/5.31 */ 16.33/5.31 int size(); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns true if this collection contains no elements. 16.33/5.31 * 16.33/5.31 * @return true if this collection contains no elements 16.33/5.31 */ 16.33/5.31 boolean isEmpty(); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns true if this collection contains the specified element. 16.33/5.31 * More formally, returns true if and only if this collection 16.33/5.31 * contains at least one element e such that 16.33/5.31 * (o==null ? e==null : o.equals(e)). 16.33/5.31 * 16.33/5.31 * @param o element whose presence in this collection is to be tested 16.33/5.31 * @return true if this collection contains the specified 16.33/5.31 * element 16.33/5.31 * @throws ClassCastException if the type of the specified element 16.33/5.31 * is incompatible with this collection (optional) 16.33/5.31 * @throws NullPointerException if the specified element is null and this 16.33/5.31 * collection does not permit null elements (optional) 16.33/5.31 */ 16.33/5.31 boolean contains(Object o); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns an iterator over the elements in this collection. There are no 16.33/5.31 * guarantees concerning the order in which the elements are returned 16.33/5.31 * (unless this collection is an instance of some class that provides a 16.33/5.31 * guarantee). 16.33/5.31 * 16.33/5.31 * @return an Iterator over the elements in this collection 16.33/5.31 */ 16.33/5.31 Iterator iterator(); 16.33/5.31 16.33/5.31 // Modification Operations 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Ensures that this collection contains the specified element (optional 16.33/5.31 * operation). Returns true if this collection changed as a 16.33/5.31 * result of the call. (Returns false if this collection does 16.33/5.31 * not permit duplicates and already contains the specified element.)

16.33/5.31 * 16.33/5.31 * Collections that support this operation may place limitations on what 16.33/5.31 * elements may be added to this collection. In particular, some 16.33/5.31 * collections will refuse to add null elements, and others will 16.33/5.31 * impose restrictions on the type of elements that may be added. 16.33/5.31 * Collection classes should clearly specify in their documentation any 16.33/5.31 * restrictions on what elements may be added.

16.33/5.31 * 16.33/5.31 * If a collection refuses to add a particular element for any reason 16.33/5.31 * other than that it already contains the element, it must throw 16.33/5.31 * an exception (rather than returning false). This preserves 16.33/5.31 * the invariant that a collection always contains the specified element 16.33/5.31 * after this call returns. 16.33/5.31 * 16.33/5.31 * @param e element whose presence in this collection is to be ensured 16.33/5.31 * @return true if this collection changed as a result of the 16.33/5.31 * call 16.33/5.31 * @throws UnsupportedOperationException if the add operation 16.33/5.31 * is not supported by this collection 16.33/5.31 * @throws ClassCastException if the class of the specified element 16.33/5.31 * prevents it from being added to this collection 16.33/5.31 * @throws NullPointerException if the specified element is null and this 16.33/5.31 * collection does not permit null elements 16.33/5.31 * @throws IllegalArgumentException if some property of the element 16.33/5.31 * prevents it from being added to this collection 16.33/5.31 * @throws IllegalStateException if the element cannot be added at this 16.33/5.31 * time due to insertion restrictions 16.33/5.31 */ 16.33/5.31 boolean add(E e); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Removes a single instance of the specified element from this 16.33/5.31 * collection, if it is present (optional operation). More formally, 16.33/5.31 * removes an element e such that 16.33/5.31 * (o==null ? e==null : o.equals(e)), if 16.33/5.31 * this collection contains one or more such elements. Returns 16.33/5.31 * true if this collection contained the specified element (or 16.33/5.31 * equivalently, if this collection changed as a result of the call). 16.33/5.31 * 16.33/5.31 * @param o element to be removed from this collection, if present 16.33/5.31 * @return true if an element was removed as a result of this call 16.33/5.31 * @throws ClassCastException if the type of the specified element 16.33/5.31 * is incompatible with this collection (optional) 16.33/5.31 * @throws NullPointerException if the specified element is null and this 16.33/5.31 * collection does not permit null elements (optional) 16.33/5.31 * @throws UnsupportedOperationException if the remove operation 16.33/5.31 * is not supported by this collection 16.33/5.31 */ 16.33/5.31 boolean remove(Object o); 16.33/5.31 16.33/5.31 16.33/5.31 // Bulk Operations 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns true if this collection contains all of the elements 16.33/5.31 * in the specified collection. 16.33/5.31 * 16.33/5.31 * @param c collection to be checked for containment in this collection 16.33/5.31 * @return true if this collection contains all of the elements 16.33/5.31 * in the specified collection 16.33/5.31 * @throws ClassCastException if the types of one or more elements 16.33/5.31 * in the specified collection are incompatible with this 16.33/5.31 * collection (optional) 16.33/5.31 * @throws NullPointerException if the specified collection contains one 16.33/5.31 * or more null elements and this collection does not permit null 16.33/5.31 * elements (optional), or if the specified collection is null 16.33/5.31 * @see #contains(Object) 16.33/5.31 */ 16.33/5.31 boolean containsAll(Collection c); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Adds all of the elements in the specified collection to this collection 16.33/5.31 * (optional operation). The behavior of this operation is undefined if 16.33/5.31 * the specified collection is modified while the operation is in progress. 16.33/5.31 * (This implies that the behavior of this call is undefined if the 16.33/5.31 * specified collection is this collection, and this collection is 16.33/5.31 * nonempty.) 16.33/5.31 * 16.33/5.31 * @param c collection containing elements to be added to this collection 16.33/5.31 * @return true if this collection changed as a result of the call 16.33/5.31 * @throws UnsupportedOperationException if the addAll operation 16.33/5.31 * is not supported by this collection 16.33/5.31 * @throws ClassCastException if the class of an element of the specified 16.33/5.31 * collection prevents it from being added to this collection 16.33/5.31 * @throws NullPointerException if the specified collection contains a 16.33/5.31 * null element and this collection does not permit null elements, 16.33/5.31 * or if the specified collection is null 16.33/5.31 * @throws IllegalArgumentException if some property of an element of the 16.33/5.31 * specified collection prevents it from being added to this 16.33/5.31 * collection 16.33/5.31 * @throws IllegalStateException if not all the elements can be added at 16.33/5.31 * this time due to insertion restrictions 16.33/5.31 * @see #add(Object) 16.33/5.31 */ 16.33/5.31 boolean addAll(Collection c); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Removes all of this collection's elements that are also contained in the 16.33/5.31 * specified collection (optional operation). After this call returns, 16.33/5.31 * this collection will contain no elements in common with the specified 16.33/5.31 * collection. 16.33/5.31 * 16.33/5.31 * @param c collection containing elements to be removed from this collection 16.33/5.31 * @return true if this collection changed as a result of the 16.33/5.31 * call 16.33/5.31 * @throws UnsupportedOperationException if the removeAll method 16.33/5.31 * is not supported by this collection 16.33/5.31 * @throws ClassCastException if the types of one or more elements 16.33/5.31 * in this collection are incompatible with the specified 16.33/5.31 * collection (optional) 16.33/5.31 * @throws NullPointerException if this collection contains one or more 16.33/5.31 * null elements and the specified collection does not support 16.33/5.31 * null elements (optional), or if the specified collection is null 16.33/5.31 * @see #remove(Object) 16.33/5.31 * @see #contains(Object) 16.33/5.31 */ 16.33/5.31 boolean removeAll(Collection c); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Retains only the elements in this collection that are contained in the 16.33/5.31 * specified collection (optional operation). In other words, removes from 16.33/5.31 * this collection all of its elements that are not contained in the 16.33/5.31 * specified collection. 16.33/5.31 * 16.33/5.31 * @param c collection containing elements to be retained in this collection 16.33/5.31 * @return true if this collection changed as a result of the call 16.33/5.31 * @throws UnsupportedOperationException if the retainAll operation 16.33/5.31 * is not supported by this collection 16.33/5.31 * @throws ClassCastException if the types of one or more elements 16.33/5.31 * in this collection are incompatible with the specified 16.33/5.31 * collection (optional) 16.33/5.31 * @throws NullPointerException if this collection contains one or more 16.33/5.31 * null elements and the specified collection does not permit null 16.33/5.31 * elements (optional), or if the specified collection is null 16.33/5.31 * @see #remove(Object) 16.33/5.31 * @see #contains(Object) 16.33/5.31 */ 16.33/5.31 boolean retainAll(Collection c); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Removes all of the elements from this collection (optional operation). 16.33/5.31 * The collection will be empty after this method returns. 16.33/5.31 * 16.33/5.31 * @throws UnsupportedOperationException if the clear operation 16.33/5.31 * is not supported by this collection 16.33/5.31 */ 16.33/5.31 void clear(); 16.33/5.31 16.33/5.31 16.33/5.31 // Comparison and hashing 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Compares the specified object with this collection for equality.

16.33/5.31 * 16.33/5.31 * While the Collection interface adds no stipulations to the 16.33/5.31 * general contract for the Object.equals, programmers who 16.33/5.31 * implement the Collection interface "directly" (in other words, 16.33/5.31 * create a class that is a Collection but is not a Set 16.33/5.31 * or a List) must exercise care if they choose to override the 16.33/5.31 * Object.equals. It is not necessary to do so, and the simplest 16.33/5.31 * course of action is to rely on Object's implementation, but 16.33/5.31 * the implementor may wish to implement a "value comparison" in place of 16.33/5.31 * the default "reference comparison." (The List and 16.33/5.31 * Set interfaces mandate such value comparisons.)

16.33/5.31 * 16.33/5.31 * The general contract for the Object.equals method states that 16.33/5.31 * equals must be symmetric (in other words, a.equals(b) if and 16.33/5.31 * only if b.equals(a)). The contracts for List.equals 16.33/5.31 * and Set.equals state that lists are only equal to other lists, 16.33/5.31 * and sets to other sets. Thus, a custom equals method for a 16.33/5.31 * collection class that implements neither the List nor 16.33/5.31 * Set interface must return false when this collection 16.33/5.31 * is compared to any list or set. (By the same logic, it is not possible 16.33/5.31 * to write a class that correctly implements both the Set and 16.33/5.31 * List interfaces.) 16.33/5.31 * 16.33/5.31 * @param o object to be compared for equality with this collection 16.33/5.31 * @return true if the specified object is equal to this 16.33/5.31 * collection 16.33/5.31 * 16.33/5.31 * @see Object#equals(Object) 16.33/5.31 * @see Set#equals(Object) 16.33/5.31 * @see List#equals(Object) 16.33/5.31 */ 16.33/5.31 boolean equals(Object o); 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Returns the hash code value for this collection. While the 16.33/5.31 * Collection interface adds no stipulations to the general 16.33/5.31 * contract for the Object.hashCode method, programmers should 16.33/5.31 * take note that any class that overrides the Object.equals 16.33/5.31 * method must also override the Object.hashCode method in order 16.33/5.31 * to satisfy the general contract for the Object.hashCodemethod. 16.33/5.31 * In particular, c1.equals(c2) implies that 16.33/5.31 * c1.hashCode()==c2.hashCode(). 16.33/5.31 * 16.33/5.31 * @return the hash code value for this collection 16.33/5.31 * 16.33/5.31 * @see Object#hashCode() 16.33/5.31 * @see Object#equals(Object) 16.33/5.31 */ 16.33/5.31 int hashCode(); 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 /* 16.33/5.31 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.31 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.31 * 16.33/5.31 * This code is free software; you can redistribute it and/or modify it 16.33/5.31 * under the terms of the GNU General Public License version 2 only, as 16.33/5.31 * published by the Free Software Foundation. Sun designates this 16.33/5.31 * particular file as subject to the "Classpath" exception as provided 16.33/5.31 * by Sun in the LICENSE file that accompanied this code. 16.33/5.31 * 16.33/5.31 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.31 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.31 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.31 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.31 * accompanied this code). 16.33/5.31 * 16.33/5.31 * You should have received a copy of the GNU General Public License version 16.33/5.31 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.31 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.31 * 16.33/5.31 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.31 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.31 * have any questions. 16.33/5.31 */ 16.33/5.31 16.33/5.31 package javaUtilEx; 16.33/5.31 16.33/5.31 /** 16.33/5.31 * This exception may be thrown by methods that have detected concurrent 16.33/5.31 * modification of an object when such modification is not permissible. 16.33/5.31 *

16.33/5.31 * For example, it is not generally permissible for one thread to modify a Collection 16.33/5.31 * while another thread is iterating over it. In general, the results of the 16.33/5.31 * iteration are undefined under these circumstances. Some Iterator 16.33/5.31 * implementations (including those of all the general purpose collection implementations 16.33/5.31 * provided by the JRE) may choose to throw this exception if this behavior is 16.33/5.31 * detected. Iterators that do this are known as fail-fast iterators, 16.33/5.31 * as they fail quickly and cleanly, rather that risking arbitrary, 16.33/5.31 * non-deterministic behavior at an undetermined time in the future. 16.33/5.31 *

16.33/5.31 * Note that this exception does not always indicate that an object has 16.33/5.31 * been concurrently modified by a different thread. If a single 16.33/5.31 * thread issues a sequence of method invocations that violates the 16.33/5.31 * contract of an object, the object may throw this exception. For 16.33/5.31 * example, if a thread modifies a collection directly while it is 16.33/5.31 * iterating over the collection with a fail-fast iterator, the iterator 16.33/5.31 * will throw this exception. 16.33/5.31 * 16.33/5.31 *

Note that fail-fast behavior cannot be guaranteed as it is, generally 16.33/5.31 * speaking, impossible to make any hard guarantees in the presence of 16.33/5.31 * unsynchronized concurrent modification. Fail-fast operations 16.33/5.31 * throw ConcurrentModificationException on a best-effort basis. 16.33/5.31 * Therefore, it would be wrong to write a program that depended on this 16.33/5.31 * exception for its correctness: ConcurrentModificationException 16.33/5.31 * should be used only to detect bugs. 16.33/5.31 * 16.33/5.31 * @author Josh Bloch 16.33/5.31 * @see Collection 16.33/5.31 * @see Iterator 16.33/5.31 * @see ListIterator 16.33/5.31 * @see Vector 16.33/5.31 * @see LinkedList 16.33/5.31 * @see HashSet 16.33/5.31 * @see Hashtable 16.33/5.31 * @see TreeMap 16.33/5.31 * @see AbstractList 16.33/5.31 * @since 1.2 16.33/5.31 */ 16.33/5.31 public class ConcurrentModificationException extends RuntimeException { 16.33/5.31 /** 16.33/5.31 * Constructs a ConcurrentModificationException with no 16.33/5.31 * detail message. 16.33/5.31 */ 16.33/5.31 public ConcurrentModificationException() { 16.33/5.31 } 16.33/5.31 16.33/5.31 /** 16.33/5.31 * Constructs a ConcurrentModificationException with the 16.33/5.31 * specified detail message. 16.33/5.31 * 16.33/5.31 * @param message the detail message pertaining to this exception. 16.33/5.31 */ 16.33/5.31 public ConcurrentModificationException(String message) { 16.33/5.31 super(message); 16.33/5.31 } 16.33/5.31 } 16.33/5.31 16.33/5.31 16.33/5.31 /* 16.33/5.31 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.31 * 16.33/5.31 * This code is free software; you can redistribute it and/or modify it 16.33/5.31 * under the terms of the GNU General Public License version 2 only, as 16.33/5.31 * published by the Free Software Foundation. Sun designates this 16.33/5.31 * particular file as subject to the "Classpath" exception as provided 16.33/5.31 * by Sun in the LICENSE file that accompanied this code. 16.33/5.31 * 16.33/5.31 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.31 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.31 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.31 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.31 * accompanied this code). 16.33/5.31 * 16.33/5.31 * You should have received a copy of the GNU General Public License version 16.33/5.31 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.31 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.31 * 16.33/5.31 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.31 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.31 * have any questions. 16.33/5.31 */ 16.33/5.31 16.33/5.31 /* 16.33/5.31 * This file is available under and governed by the GNU General Public 16.33/5.31 * License version 2 only, as published by the Free Software Foundation. 16.33/5.31 * However, the following notice accompanied the original version of this 16.33/5.31 * file: 16.33/5.31 * 16.33/5.31 * Written by Doug Lea and Josh Bloch with assistance from members of 16.33/5.31 * JCP JSR-166 Expert Group and released to the public domain, as explained 16.33/5.31 * at http://creativecommons.org/licenses/publicdomain 16.33/5.31 */ 16.33/5.31 16.33/5.31 package javaUtilEx; 16.33/5.31 16.33/5.31 /** 16.33/5.31 * A linear collection that supports element insertion and removal at 16.33/5.31 * both ends. The name deque is short for "double ended queue" 16.33/5.31 * and is usually pronounced "deck". Most Deque 16.33/5.31 * implementations place no fixed limits on the number of elements 16.33/5.31 * they may contain, but this interface supports capacity-restricted 16.33/5.31 * deques as well as those with no fixed size limit. 16.33/5.31 * 16.33/5.31 *

This interface defines methods to access the elements at both 16.33/5.31 * ends of the deque. Methods are provided to insert, remove, and 16.33/5.31 * examine the element. Each of these methods exists in two forms: 16.33/5.31 * one throws an exception if the operation fails, the other returns a 16.33/5.31 * special value (either null or false, depending on 16.33/5.31 * the operation). The latter form of the insert operation is 16.33/5.31 * designed specifically for use with capacity-restricted 16.33/5.31 * Deque implementations; in most implementations, insert 16.33/5.31 * operations cannot fail. 16.33/5.31 * 16.33/5.31 *

The twelve methods described above are summarized in the 16.33/5.31 * following table: 16.33/5.31 * 16.33/5.31 *

16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 *
First Element (Head) Last Element (Tail)
Throws exceptionSpecial valueThrows exceptionSpecial value
Insert{@link #addFirst addFirst(e)}{@link #offerFirst offerFirst(e)}{@link #addLast addLast(e)}{@link #offerLast offerLast(e)}
Remove{@link #removeFirst removeFirst()}{@link #pollFirst pollFirst()}{@link #removeLast removeLast()}{@link #pollLast pollLast()}
Examine{@link #getFirst getFirst()}{@link #peekFirst peekFirst()}{@link #getLast getLast()}{@link #peekLast peekLast()}
16.33/5.31 * 16.33/5.31 *

This interface extends the {@link Queue} interface. When a deque is 16.33/5.31 * used as a queue, FIFO (First-In-First-Out) behavior results. Elements are 16.33/5.31 * added at the end of the deque and removed from the beginning. The methods 16.33/5.31 * inherited from the Queue interface are precisely equivalent to 16.33/5.31 * Deque methods as indicated in the following table: 16.33/5.31 * 16.33/5.31 *

16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 *
Queue Method Equivalent Deque Method
{@link java.util.Queue#add add(e)}{@link #addLast addLast(e)}
{@link java.util.Queue#offer offer(e)}{@link #offerLast offerLast(e)}
{@link java.util.Queue#remove remove()}{@link #removeFirst removeFirst()}
{@link java.util.Queue#poll poll()}{@link #pollFirst pollFirst()}
{@link java.util.Queue#element element()}{@link #getFirst getFirst()}
{@link java.util.Queue#peek peek()}{@link #peek peekFirst()}
16.33/5.31 * 16.33/5.31 *

Deques can also be used as LIFO (Last-In-First-Out) stacks. This 16.33/5.31 * interface should be used in preference to the legacy {@link Stack} class. 16.33/5.31 * When a deque is used as a stack, elements are pushed and popped from the 16.33/5.31 * beginning of the deque. Stack methods are precisely equivalent to 16.33/5.31 * Deque methods as indicated in the table below: 16.33/5.31 * 16.33/5.31 *

16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 * 16.33/5.31 *
Stack Method Equivalent Deque Method
{@link #push push(e)}{@link #addFirst addFirst(e)}
{@link #pop pop()}{@link #removeFirst removeFirst()}
{@link #peek peek()}{@link #peekFirst peekFirst()}
16.33/5.31 * 16.33/5.31 *

Note that the {@link #peek peek} method works equally well when 16.33/5.31 * a deque is used as a queue or a stack; in either case, elements are 16.33/5.31 * drawn from the beginning of the deque. 16.33/5.31 * 16.33/5.31 *

This interface provides two methods to remove interior 16.33/5.31 * elements, {@link #removeFirstOccurrence removeFirstOccurrence} and 16.33/5.31 * {@link #removeLastOccurrence removeLastOccurrence}. 16.33/5.32 * 16.33/5.32 *

Unlike the {@link List} interface, this interface does not 16.33/5.32 * provide support for indexed access to elements. 16.33/5.32 * 16.33/5.32 *

While Deque implementations are not strictly required 16.33/5.32 * to prohibit the insertion of null elements, they are strongly 16.33/5.32 * encouraged to do so. Users of any Deque implementations 16.33/5.32 * that do allow null elements are strongly encouraged not to 16.33/5.32 * take advantage of the ability to insert nulls. This is so because 16.33/5.32 * null is used as a special return value by various methods 16.33/5.32 * to indicated that the deque is empty. 16.33/5.32 * 16.33/5.32 *

Deque implementations generally do not define 16.33/5.32 * element-based versions of the equals and hashCode 16.33/5.32 * methods, but instead inherit the identity-based versions from class 16.33/5.32 * Object. 16.33/5.32 * 16.33/5.32 *

This interface is a member of the Java Collections 16.33/5.32 * Framework. 16.33/5.32 * 16.33/5.32 * @author Doug Lea 16.33/5.32 * @author Josh Bloch 16.33/5.32 * @since 1.6 16.33/5.32 * @param the type of elements held in this collection 16.33/5.32 */ 16.33/5.32 16.33/5.32 public interface Deque extends Queue { 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the front of this deque if it is 16.33/5.32 * possible to do so immediately without violating capacity restrictions. 16.33/5.32 * When using a capacity-restricted deque, it is generally preferable to 16.33/5.32 * use method {@link #offerFirst}. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @throws IllegalStateException if the element cannot be added at this 16.33/5.32 * time due to capacity restrictions 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 void addFirst(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the end of this deque if it is 16.33/5.32 * possible to do so immediately without violating capacity restrictions. 16.33/5.32 * When using a capacity-restricted deque, it is generally preferable to 16.33/5.32 * use method {@link #offerLast}. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #add}. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @throws IllegalStateException if the element cannot be added at this 16.33/5.32 * time due to capacity restrictions 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 void addLast(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the front of this deque unless it would 16.33/5.32 * violate capacity restrictions. When using a capacity-restricted deque, 16.33/5.32 * this method is generally preferable to the {@link #addFirst} method, 16.33/5.32 * which can fail to insert an element only by throwing an exception. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @return true if the element was added to this deque, else 16.33/5.32 * false 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 boolean offerFirst(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the end of this deque unless it would 16.33/5.32 * violate capacity restrictions. When using a capacity-restricted deque, 16.33/5.32 * this method is generally preferable to the {@link #addLast} method, 16.33/5.32 * which can fail to insert an element only by throwing an exception. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @return true if the element was added to this deque, else 16.33/5.32 * false 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 boolean offerLast(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the first element of this deque. This method 16.33/5.32 * differs from {@link #pollFirst pollFirst} only in that it throws an 16.33/5.32 * exception if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the head of this deque 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E removeFirst(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the last element of this deque. This method 16.33/5.32 * differs from {@link #pollLast pollLast} only in that it throws an 16.33/5.32 * exception if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the tail of this deque 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E removeLast(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the first element of this deque, 16.33/5.32 * or returns null if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the head of this deque, or null if this deque is empty 16.33/5.32 */ 16.33/5.32 E pollFirst(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the last element of this deque, 16.33/5.32 * or returns null if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the tail of this deque, or null if this deque is empty 16.33/5.32 */ 16.33/5.32 E pollLast(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the first element of this deque. 16.33/5.32 * 16.33/5.32 * This method differs from {@link #peekFirst peekFirst} only in that it 16.33/5.32 * throws an exception if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the head of this deque 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E getFirst(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the last element of this deque. 16.33/5.32 * This method differs from {@link #peekLast peekLast} only in that it 16.33/5.32 * throws an exception if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the tail of this deque 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E getLast(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the first element of this deque, 16.33/5.32 * or returns null if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the head of this deque, or null if this deque is empty 16.33/5.32 */ 16.33/5.32 E peekFirst(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the last element of this deque, 16.33/5.32 * or returns null if this deque is empty. 16.33/5.32 * 16.33/5.32 * @return the tail of this deque, or null if this deque is empty 16.33/5.32 */ 16.33/5.32 E peekLast(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the first occurrence of the specified element from this deque. 16.33/5.32 * If the deque does not contain the element, it is unchanged. 16.33/5.32 * More formally, removes the first element e such that 16.33/5.32 * (o==null ? e==null : o.equals(e)) 16.33/5.32 * (if such an element exists). 16.33/5.32 * Returns true if this deque contained the specified element 16.33/5.32 * (or equivalently, if this deque changed as a result of the call). 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this deque, if present 16.33/5.32 * @return true if an element was removed as a result of this call 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * is incompatible with this deque (optional) 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements (optional) 16.33/5.32 */ 16.33/5.32 boolean removeFirstOccurrence(Object o); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the last occurrence of the specified element from this deque. 16.33/5.32 * If the deque does not contain the element, it is unchanged. 16.33/5.32 * More formally, removes the last element e such that 16.33/5.32 * (o==null ? e==null : o.equals(e)) 16.33/5.32 * (if such an element exists). 16.33/5.32 * Returns true if this deque contained the specified element 16.33/5.32 * (or equivalently, if this deque changed as a result of the call). 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this deque, if present 16.33/5.32 * @return true if an element was removed as a result of this call 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * is incompatible with this deque (optional) 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements (optional) 16.33/5.32 */ 16.33/5.32 boolean removeLastOccurrence(Object o); 16.33/5.32 16.33/5.32 // *** Queue methods *** 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element into the queue represented by this deque 16.33/5.32 * (in other words, at the tail of this deque) if it is possible to do so 16.33/5.32 * immediately without violating capacity restrictions, returning 16.33/5.32 * true upon success and throwing an 16.33/5.32 * IllegalStateException if no space is currently available. 16.33/5.32 * When using a capacity-restricted deque, it is generally preferable to 16.33/5.32 * use {@link #offer(Object) offer}. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #addLast}. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @return true (as specified by {@link Collection#add}) 16.33/5.32 * @throws IllegalStateException if the element cannot be added at this 16.33/5.32 * time due to capacity restrictions 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 boolean add(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element into the queue represented by this deque 16.33/5.32 * (in other words, at the tail of this deque) if it is possible to do so 16.33/5.32 * immediately without violating capacity restrictions, returning 16.33/5.32 * true upon success and false if no space is currently 16.33/5.32 * available. When using a capacity-restricted deque, this method is 16.33/5.32 * generally preferable to the {@link #add} method, which can fail to 16.33/5.32 * insert an element only by throwing an exception. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #offerLast}. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @return true if the element was added to this deque, else 16.33/5.32 * false 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 boolean offer(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the head of the queue represented by this deque 16.33/5.32 * (in other words, the first element of this deque). 16.33/5.32 * This method differs from {@link #poll poll} only in that it throws an 16.33/5.32 * exception if this deque is empty. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #removeFirst()}. 16.33/5.32 * 16.33/5.32 * @return the head of the queue represented by this deque 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E remove(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the head of the queue represented by this deque 16.33/5.32 * (in other words, the first element of this deque), or returns 16.33/5.32 * null if this deque is empty. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #pollFirst()}. 16.33/5.32 * 16.33/5.32 * @return the first element of this deque, or null if 16.33/5.32 * this deque is empty 16.33/5.32 */ 16.33/5.32 E poll(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the head of the queue represented by 16.33/5.32 * this deque (in other words, the first element of this deque). 16.33/5.32 * This method differs from {@link #peek peek} only in that it throws an 16.33/5.32 * exception if this deque is empty. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #getFirst()}. 16.33/5.32 * 16.33/5.32 * @return the head of the queue represented by this deque 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E element(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the head of the queue represented by 16.33/5.32 * this deque (in other words, the first element of this deque), or 16.33/5.32 * returns null if this deque is empty. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #peekFirst()}. 16.33/5.32 * 16.33/5.32 * @return the head of the queue represented by this deque, or 16.33/5.32 * null if this deque is empty 16.33/5.32 */ 16.33/5.32 E peek(); 16.33/5.32 16.33/5.32 16.33/5.32 // *** Stack methods *** 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Pushes an element onto the stack represented by this deque (in other 16.33/5.32 * words, at the head of this deque) if it is possible to do so 16.33/5.32 * immediately without violating capacity restrictions, returning 16.33/5.32 * true upon success and throwing an 16.33/5.32 * IllegalStateException if no space is currently available. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #addFirst}. 16.33/5.32 * 16.33/5.32 * @param e the element to push 16.33/5.32 * @throws IllegalStateException if the element cannot be added at this 16.33/5.32 * time due to capacity restrictions 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this deque 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of the specified 16.33/5.32 * element prevents it from being added to this deque 16.33/5.32 */ 16.33/5.32 void push(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Pops an element from the stack represented by this deque. In other 16.33/5.32 * words, removes and returns the first element of this deque. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #removeFirst()}. 16.33/5.32 * 16.33/5.32 * @return the element at the front of this deque (which is the top 16.33/5.32 * of the stack represented by this deque) 16.33/5.32 * @throws NoSuchElementException if this deque is empty 16.33/5.32 */ 16.33/5.32 E pop(); 16.33/5.32 16.33/5.32 16.33/5.32 // *** Collection methods *** 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the first occurrence of the specified element from this deque. 16.33/5.32 * If the deque does not contain the element, it is unchanged. 16.33/5.32 * More formally, removes the first element e such that 16.33/5.32 * (o==null ? e==null : o.equals(e)) 16.33/5.32 * (if such an element exists). 16.33/5.32 * Returns true if this deque contained the specified element 16.33/5.32 * (or equivalently, if this deque changed as a result of the call). 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #removeFirstOccurrence}. 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this deque, if present 16.33/5.32 * @return true if an element was removed as a result of this call 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * is incompatible with this deque (optional) 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements (optional) 16.33/5.32 */ 16.33/5.32 boolean remove(Object o); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns true if this deque contains the specified element. 16.33/5.32 * More formally, returns true if and only if this deque contains 16.33/5.32 * at least one element e such that 16.33/5.32 * (o==null ? e==null : o.equals(e)). 16.33/5.32 * 16.33/5.32 * @param o element whose presence in this deque is to be tested 16.33/5.32 * @return true if this deque contains the specified element 16.33/5.32 * @throws ClassCastException if the type of the specified element 16.33/5.32 * is incompatible with this deque (optional) 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * deque does not permit null elements (optional) 16.33/5.32 */ 16.33/5.32 boolean contains(Object o); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the number of elements in this deque. 16.33/5.32 * 16.33/5.32 * @return the number of elements in this deque 16.33/5.32 */ 16.33/5.32 public int size(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns an iterator over the elements in this deque in proper sequence. 16.33/5.32 * The elements will be returned in order from first (head) to last (tail). 16.33/5.32 * 16.33/5.32 * @return an iterator over the elements in this deque in proper sequence 16.33/5.32 */ 16.33/5.32 Iterator iterator(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns an iterator over the elements in this deque in reverse 16.33/5.32 * sequential order. The elements will be returned in order from 16.33/5.32 * last (tail) to first (head). 16.33/5.32 * 16.33/5.32 * @return an iterator over the elements in this deque in reverse 16.33/5.32 * sequence 16.33/5.32 */ 16.33/5.32 Iterator descendingIterator(); 16.33/5.32 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 /* 16.33/5.32 * Copyright 1994-2003 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.32 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.32 * 16.33/5.32 * This code is free software; you can redistribute it and/or modify it 16.33/5.32 * under the terms of the GNU General Public License version 2 only, as 16.33/5.32 * published by the Free Software Foundation. Sun designates this 16.33/5.32 * particular file as subject to the "Classpath" exception as provided 16.33/5.32 * by Sun in the LICENSE file that accompanied this code. 16.33/5.32 * 16.33/5.32 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.32 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.32 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.32 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.32 * accompanied this code). 16.33/5.32 * 16.33/5.32 * You should have received a copy of the GNU General Public License version 16.33/5.32 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.32 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.32 * 16.33/5.32 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.32 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.32 * have any questions. 16.33/5.32 */ 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Thrown to indicate that a method has been passed an illegal or 16.33/5.32 * inappropriate argument. 16.33/5.32 * 16.33/5.32 * @author unascribed 16.33/5.32 * @see java.lang.Thread#setPriority(int) 16.33/5.32 * @since JDK1.0 16.33/5.32 */ 16.33/5.32 public 16.33/5.32 class IllegalArgumentException extends RuntimeException { 16.33/5.32 /** 16.33/5.32 * Constructs an IllegalArgumentException with no 16.33/5.32 * detail message. 16.33/5.32 */ 16.33/5.32 public IllegalArgumentException() { 16.33/5.32 super(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs an IllegalArgumentException with the 16.33/5.32 * specified detail message. 16.33/5.32 * 16.33/5.32 * @param s the detail message. 16.33/5.32 */ 16.33/5.32 public IllegalArgumentException(String s) { 16.33/5.32 super(s); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs a new exception with the specified detail message and 16.33/5.32 * cause. 16.33/5.32 * 16.33/5.32 *

Note that the detail message associated with cause is 16.33/5.32 * not automatically incorporated in this exception's detail 16.33/5.32 * message. 16.33/5.32 * 16.33/5.32 * @param message the detail message (which is saved for later retrieval 16.33/5.32 * by the {@link Throwable#getMessage()} method). 16.33/5.32 * @param cause the cause (which is saved for later retrieval by the 16.33/5.32 * {@link Throwable#getCause()} method). (A null value 16.33/5.32 * is permitted, and indicates that the cause is nonexistent or 16.33/5.32 * unknown.) 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public IllegalArgumentException(String message, Throwable cause) { 16.33/5.32 super(message, cause); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs a new exception with the specified cause and a detail 16.33/5.32 * message of (cause==null ? null : cause.toString()) (which 16.33/5.32 * typically contains the class and detail message of cause). 16.33/5.32 * This constructor is useful for exceptions that are little more than 16.33/5.32 * wrappers for other throwables (for example, {@link 16.33/5.32 * java.security.PrivilegedActionException}). 16.33/5.32 * 16.33/5.32 * @param cause the cause (which is saved for later retrieval by the 16.33/5.32 * {@link Throwable#getCause()} method). (A null value is 16.33/5.32 * permitted, and indicates that the cause is nonexistent or 16.33/5.32 * unknown.) 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public IllegalArgumentException(Throwable cause) { 16.33/5.32 super(cause); 16.33/5.32 } 16.33/5.32 16.33/5.32 private static final long serialVersionUID = -5365630128856068164L; 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 /* 16.33/5.32 * Copyright 1996-2003 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.32 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.32 * 16.33/5.32 * This code is free software; you can redistribute it and/or modify it 16.33/5.32 * under the terms of the GNU General Public License version 2 only, as 16.33/5.32 * published by the Free Software Foundation. Sun designates this 16.33/5.32 * particular file as subject to the "Classpath" exception as provided 16.33/5.32 * by Sun in the LICENSE file that accompanied this code. 16.33/5.32 * 16.33/5.32 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.32 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.32 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.32 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.32 * accompanied this code). 16.33/5.32 * 16.33/5.32 * You should have received a copy of the GNU General Public License version 16.33/5.32 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.32 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.32 * 16.33/5.32 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.32 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.32 * have any questions. 16.33/5.32 */ 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Signals that a method has been invoked at an illegal or 16.33/5.32 * inappropriate time. In other words, the Java environment or 16.33/5.32 * Java application is not in an appropriate state for the requested 16.33/5.32 * operation. 16.33/5.32 * 16.33/5.32 * @author Jonni Kanerva 16.33/5.32 * @since JDK1.1 16.33/5.32 */ 16.33/5.32 public 16.33/5.32 class IllegalStateException extends RuntimeException { 16.33/5.32 /** 16.33/5.32 * Constructs an IllegalStateException with no detail message. 16.33/5.32 * A detail message is a String that describes this particular exception. 16.33/5.32 */ 16.33/5.32 public IllegalStateException() { 16.33/5.32 super(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs an IllegalStateException with the specified detail 16.33/5.32 * message. A detail message is a String that describes this particular 16.33/5.32 * exception. 16.33/5.32 * 16.33/5.32 * @param s the String that contains a detailed message 16.33/5.32 */ 16.33/5.32 public IllegalStateException(String s) { 16.33/5.32 super(s); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs a new exception with the specified detail message and 16.33/5.32 * cause. 16.33/5.32 * 16.33/5.32 *

Note that the detail message associated with cause is 16.33/5.32 * not automatically incorporated in this exception's detail 16.33/5.32 * message. 16.33/5.32 * 16.33/5.32 * @param message the detail message (which is saved for later retrieval 16.33/5.32 * by the {@link Throwable#getMessage()} method). 16.33/5.32 * @param cause the cause (which is saved for later retrieval by the 16.33/5.32 * {@link Throwable#getCause()} method). (A null value 16.33/5.32 * is permitted, and indicates that the cause is nonexistent or 16.33/5.32 * unknown.) 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public IllegalStateException(String message, Throwable cause) { 16.33/5.32 super(message, cause); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs a new exception with the specified cause and a detail 16.33/5.32 * message of (cause==null ? null : cause.toString()) (which 16.33/5.32 * typically contains the class and detail message of cause). 16.33/5.32 * This constructor is useful for exceptions that are little more than 16.33/5.32 * wrappers for other throwables (for example, {@link 16.33/5.32 * java.security.PrivilegedActionException}). 16.33/5.32 * 16.33/5.32 * @param cause the cause (which is saved for later retrieval by the 16.33/5.32 * {@link Throwable#getCause()} method). (A null value is 16.33/5.32 * permitted, and indicates that the cause is nonexistent or 16.33/5.32 * unknown.) 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public IllegalStateException(Throwable cause) { 16.33/5.32 super(cause); 16.33/5.32 } 16.33/5.32 16.33/5.32 static final long serialVersionUID = -1848914673093119416L; 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 /* 16.33/5.32 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.32 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.32 * 16.33/5.32 * This code is free software; you can redistribute it and/or modify it 16.33/5.32 * under the terms of the GNU General Public License version 2 only, as 16.33/5.32 * published by the Free Software Foundation. Sun designates this 16.33/5.32 * particular file as subject to the "Classpath" exception as provided 16.33/5.32 * by Sun in the LICENSE file that accompanied this code. 16.33/5.32 * 16.33/5.32 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.32 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.32 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.32 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.32 * accompanied this code). 16.33/5.32 * 16.33/5.32 * You should have received a copy of the GNU General Public License version 16.33/5.32 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.32 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.32 * 16.33/5.32 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.32 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.32 * have any questions. 16.33/5.32 */ 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * An iterator over a collection. {@code Iterator} takes the place of 16.33/5.32 * {@link Enumeration} in the Java Collections Framework. Iterators 16.33/5.32 * differ from enumerations in two ways: 16.33/5.32 * 16.33/5.32 *

16.33/5.32 * 16.33/5.32 *

This interface is a member of the 16.33/5.32 * 16.33/5.32 * Java Collections Framework. 16.33/5.32 * 16.33/5.32 * @author Josh Bloch 16.33/5.32 * @see Collection 16.33/5.32 * @see ListIterator 16.33/5.32 * @see Iterable 16.33/5.32 * @since 1.2 16.33/5.32 */ 16.33/5.32 public interface Iterator { 16.33/5.32 /** 16.33/5.32 * Returns {@code true} if the iteration has more elements. 16.33/5.32 * (In other words, returns {@code true} if {@link #next} would 16.33/5.32 * return an element rather than throwing an exception.) 16.33/5.32 * 16.33/5.32 * @return {@code true} if the iteration has more elements 16.33/5.32 */ 16.33/5.32 boolean hasNext(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the next element in the iteration. 16.33/5.32 * 16.33/5.32 * @return the next element in the iteration 16.33/5.32 * @throws NoSuchElementException if the iteration has no more elements 16.33/5.32 */ 16.33/5.32 E next(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes from the underlying collection the last element returned 16.33/5.32 * by this iterator (optional operation). This method can be called 16.33/5.32 * only once per call to {@link #next}. The behavior of an iterator 16.33/5.32 * is unspecified if the underlying collection is modified while the 16.33/5.32 * iteration is in progress in any way other than by calling this 16.33/5.32 * method. 16.33/5.32 * 16.33/5.32 * @throws UnsupportedOperationException if the {@code remove} 16.33/5.32 * operation is not supported by this iterator 16.33/5.32 * 16.33/5.32 * @throws IllegalStateException if the {@code next} method has not 16.33/5.32 * yet been called, or the {@code remove} method has already 16.33/5.32 * been called after the last call to the {@code next} 16.33/5.32 * method 16.33/5.32 */ 16.33/5.32 void remove(); 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 public class juLinkedListCreateAddLast { 16.33/5.32 public static void main(String[] args) { 16.33/5.32 Random.args = args; 16.33/5.32 16.33/5.32 LinkedList l = createList(Random.random()); 16.33/5.32 l.addLast(new Content(Random.random())); 16.33/5.32 } 16.33/5.32 16.33/5.32 public static LinkedList createList(int n) { 16.33/5.32 LinkedList l = new LinkedList(); 16.33/5.32 while (n > 0) { 16.33/5.32 l.addLast(new Content(Random.random())); 16.33/5.32 n--; 16.33/5.32 } 16.33/5.32 return l; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 16.33/5.32 final class Content { 16.33/5.32 int val; 16.33/5.32 16.33/5.32 public Content(int v) { 16.33/5.32 this.val = v; 16.33/5.32 } 16.33/5.32 16.33/5.32 public int hashCode() { 16.33/5.32 return val^31; 16.33/5.32 } 16.33/5.32 16.33/5.32 public boolean equals(Object o) { 16.33/5.32 if (o instanceof Content) { 16.33/5.32 return this.val == ((Content) o).val; 16.33/5.32 } 16.33/5.32 return false; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 /* 16.33/5.32 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.32 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.32 * 16.33/5.32 * This code is free software; you can redistribute it and/or modify it 16.33/5.32 * under the terms of the GNU General Public License version 2 only, as 16.33/5.32 * published by the Free Software Foundation. Sun designates this 16.33/5.32 * particular file as subject to the "Classpath" exception as provided 16.33/5.32 * by Sun in the LICENSE file that accompanied this code. 16.33/5.32 * 16.33/5.32 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.32 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.32 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.32 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.32 * accompanied this code). 16.33/5.32 * 16.33/5.32 * You should have received a copy of the GNU General Public License version 16.33/5.32 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.32 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.32 * 16.33/5.32 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.32 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.32 * have any questions. 16.33/5.32 */ 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Linked list implementation of the List interface. Implements all 16.33/5.32 * optional list operations, and permits all elements (including 16.33/5.32 * null). In addition to implementing the List interface, 16.33/5.32 * the LinkedList class provides uniformly named methods to 16.33/5.32 * get, remove and insert an element at the 16.33/5.32 * beginning and end of the list. These operations allow linked lists to be 16.33/5.32 * used as a stack, {@linkplain Queue queue}, or {@linkplain Deque 16.33/5.32 * double-ended queue}.

16.33/5.32 * 16.33/5.32 * The class implements the Deque interface, providing 16.33/5.32 * first-in-first-out queue operations for add, 16.33/5.32 * poll, along with other stack and deque operations.

16.33/5.32 * 16.33/5.32 * All of the operations perform as could be expected for a doubly-linked 16.33/5.32 * list. Operations that index into the list will traverse the list from 16.33/5.32 * the beginning or the end, whichever is closer to the specified index.

16.33/5.32 * 16.33/5.32 *

Note that this implementation is not synchronized. 16.33/5.32 * If multiple threads access a linked list concurrently, and at least 16.33/5.32 * one of the threads modifies the list structurally, it must be 16.33/5.32 * synchronized externally. (A structural modification is any operation 16.33/5.32 * that adds or deletes one or more elements; merely setting the value of 16.33/5.32 * an element is not a structural modification.) This is typically 16.33/5.32 * accomplished by synchronizing on some object that naturally 16.33/5.32 * encapsulates the list. 16.33/5.32 * 16.33/5.32 * If no such object exists, the list should be "wrapped" using the 16.33/5.32 * {@link Collections#synchronizedList Collections.synchronizedList} 16.33/5.32 * method. This is best done at creation time, to prevent accidental 16.33/5.32 * unsynchronized access to the list:

16.33/5.32	 *   List list = Collections.synchronizedList(new LinkedList(...));
16.33/5.32 * 16.33/5.32 *

The iterators returned by this class's iterator and 16.33/5.32 * listIterator methods are fail-fast: if the list is 16.33/5.32 * structurally modified at any time after the iterator is created, in 16.33/5.32 * any way except through the Iterator's own remove or 16.33/5.32 * add methods, the iterator will throw a {@link 16.33/5.32 * ConcurrentModificationException}. Thus, in the face of concurrent 16.33/5.32 * modification, the iterator fails quickly and cleanly, rather than 16.33/5.32 * risking arbitrary, non-deterministic behavior at an undetermined 16.33/5.32 * time in the future. 16.33/5.32 * 16.33/5.32 *

Note that the fail-fast behavior of an iterator cannot be guaranteed 16.33/5.32 * as it is, generally speaking, impossible to make any hard guarantees in the 16.33/5.32 * presence of unsynchronized concurrent modification. Fail-fast iterators 16.33/5.32 * throw ConcurrentModificationException on a best-effort basis. 16.33/5.32 * Therefore, it would be wrong to write a program that depended on this 16.33/5.32 * exception for its correctness: the fail-fast behavior of iterators 16.33/5.32 * should be used only to detect bugs. 16.33/5.32 * 16.33/5.32 *

This class is a member of the 16.33/5.32 * 16.33/5.32 * Java Collections Framework. 16.33/5.32 * 16.33/5.32 * @author Josh Bloch 16.33/5.32 * @see List 16.33/5.32 * @see ArrayList 16.33/5.32 * @see Vector 16.33/5.32 * @since 1.2 16.33/5.32 * @param the type of elements held in this collection 16.33/5.32 */ 16.33/5.32 16.33/5.32 public class LinkedList 16.33/5.32 extends AbstractSequentialList 16.33/5.32 implements List, Deque 16.33/5.32 { 16.33/5.32 private transient Entry header = new Entry(null, null, null); 16.33/5.32 private transient int size = 0; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs an empty list. 16.33/5.32 */ 16.33/5.32 public LinkedList() { 16.33/5.32 header.next = header.previous = header; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Constructs a list containing the elements of the specified 16.33/5.32 * collection, in the order they are returned by the collection's 16.33/5.32 * iterator. 16.33/5.32 * 16.33/5.32 * @param c the collection whose elements are to be placed into this list 16.33/5.32 * @throws NullPointerException if the specified collection is null 16.33/5.32 */ 16.33/5.32 public LinkedList(Collection c) { 16.33/5.32 this(); 16.33/5.32 addAll(c); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the first element in this list. 16.33/5.32 * 16.33/5.32 * @return the first element in this list 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 */ 16.33/5.32 public E getFirst() { 16.33/5.32 if (size==0) 16.33/5.32 throw new NoSuchElementException(); 16.33/5.32 16.33/5.32 return header.next.element; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the last element in this list. 16.33/5.32 * 16.33/5.32 * @return the last element in this list 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 */ 16.33/5.32 public E getLast() { 16.33/5.32 if (size==0) 16.33/5.32 throw new NoSuchElementException(); 16.33/5.32 16.33/5.32 return header.previous.element; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes and returns the first element from this list. 16.33/5.32 * 16.33/5.32 * @return the first element from this list 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 */ 16.33/5.32 public E removeFirst() { 16.33/5.32 return remove(header.next); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes and returns the last element from this list. 16.33/5.32 * 16.33/5.32 * @return the last element from this list 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 */ 16.33/5.32 public E removeLast() { 16.33/5.32 return remove(header.previous); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the beginning of this list. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 */ 16.33/5.32 public void addFirst(E e) { 16.33/5.32 addBefore(e, header.next); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Appends the specified element to the end of this list. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #add}. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 */ 16.33/5.32 public void addLast(E e) { 16.33/5.32 addBefore(e, header); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns true if this list contains the specified element. 16.33/5.32 * More formally, returns true if and only if this list contains 16.33/5.32 * at least one element e such that 16.33/5.32 * (o==null ? e==null : o.equals(e)). 16.33/5.32 * 16.33/5.32 * @param o element whose presence in this list is to be tested 16.33/5.32 * @return true if this list contains the specified element 16.33/5.32 */ 16.33/5.32 public boolean contains(Object o) { 16.33/5.32 return indexOf(o) != -1; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the number of elements in this list. 16.33/5.32 * 16.33/5.32 * @return the number of elements in this list 16.33/5.32 */ 16.33/5.32 public int size() { 16.33/5.32 return size; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Appends the specified element to the end of this list. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #addLast}. 16.33/5.32 * 16.33/5.32 * @param e element to be appended to this list 16.33/5.32 * @return true (as specified by {@link Collection#add}) 16.33/5.32 */ 16.33/5.32 public boolean add(E e) { 16.33/5.32 addBefore(e, header); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the first occurrence of the specified element from this list, 16.33/5.32 * if it is present. If this list does not contain the element, it is 16.33/5.32 * unchanged. More formally, removes the element with the lowest index 16.33/5.32 * i such that 16.33/5.32 * (o==null ? get(i)==null : o.equals(get(i))) 16.33/5.32 * (if such an element exists). Returns true if this list 16.33/5.32 * contained the specified element (or equivalently, if this list 16.33/5.32 * changed as a result of the call). 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this list, if present 16.33/5.32 * @return true if this list contained the specified element 16.33/5.32 */ 16.33/5.32 public boolean remove(Object o) { 16.33/5.32 if (o==null) { 16.33/5.32 for (Entry e = header.next; e != header; e = e.next) { 16.33/5.32 if (e.element==null) { 16.33/5.32 remove(e); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 } else { 16.33/5.32 for (Entry e = header.next; e != header; e = e.next) { 16.33/5.32 if (o.equals(e.element)) { 16.33/5.32 remove(e); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 } 16.33/5.32 return false; 16.33/5.32 } 16.33/5.32 /** 16.33/5.32 * Removes all of the elements from this list. 16.33/5.32 */ 16.33/5.32 public void clear() { 16.33/5.32 Entry e = header.next; 16.33/5.32 while (e != header) { 16.33/5.32 Entry next = e.next; 16.33/5.32 e.next = e.previous = null; 16.33/5.32 e.element = null; 16.33/5.32 e = next; 16.33/5.32 } 16.33/5.32 header.next = header.previous = header; 16.33/5.32 size = 0; 16.33/5.32 modCount++; 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 // Positional Access Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the element at the specified position in this list. 16.33/5.32 * 16.33/5.32 * @param index index of the element to return 16.33/5.32 * @return the element at the specified position in this list 16.33/5.32 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.32 */ 16.33/5.32 public E get(int index) { 16.33/5.32 return entry(index).element; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Replaces the element at the specified position in this list with the 16.33/5.32 * specified element. 16.33/5.32 * 16.33/5.32 * @param index index of the element to replace 16.33/5.32 * @param element element to be stored at the specified position 16.33/5.32 * @return the element previously at the specified position 16.33/5.32 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.32 */ 16.33/5.32 public E set(int index, E element) { 16.33/5.32 Entry e = entry(index); 16.33/5.32 E oldVal = e.element; 16.33/5.32 e.element = element; 16.33/5.32 return oldVal; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the specified position in this list. 16.33/5.32 * Shifts the element currently at that position (if any) and any 16.33/5.32 * subsequent elements to the right (adds one to their indices). 16.33/5.32 * 16.33/5.32 * @param index index at which the specified element is to be inserted 16.33/5.32 * @param element element to be inserted 16.33/5.32 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.32 */ 16.33/5.32 public void add(int index, E element) { 16.33/5.32 addBefore(element, (index==size ? header : entry(index))); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the element at the specified position in this list. Shifts any 16.33/5.32 * subsequent elements to the left (subtracts one from their indices). 16.33/5.32 * Returns the element that was removed from the list. 16.33/5.32 * 16.33/5.32 * @param index the index of the element to be removed 16.33/5.32 * @return the element previously at the specified position 16.33/5.32 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.32 */ 16.33/5.32 public E remove(int index) { 16.33/5.32 return remove(entry(index)); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the indexed entry. 16.33/5.32 */ 16.33/5.32 private Entry entry(int index) { 16.33/5.32 if (index < 0 || index >= size) 16.33/5.32 throw new IndexOutOfBoundsException(); 16.33/5.32 Entry e = header; 16.33/5.32 if (index < (size >> 1)) { 16.33/5.32 for (int i = 0; i <= index; i++) 16.33/5.32 e = e.next; 16.33/5.32 } else { 16.33/5.32 for (int i = size; i > index; i--) 16.33/5.32 e = e.previous; 16.33/5.32 } 16.33/5.32 return e; 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 // Search Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the index of the first occurrence of the specified element 16.33/5.32 * in this list, or -1 if this list does not contain the element. 16.33/5.32 * More formally, returns the lowest index i such that 16.33/5.32 * (o==null ? get(i)==null : o.equals(get(i))), 16.33/5.32 * or -1 if there is no such index. 16.33/5.32 * 16.33/5.32 * @param o element to search for 16.33/5.32 * @return the index of the first occurrence of the specified element in 16.33/5.32 * this list, or -1 if this list does not contain the element 16.33/5.32 */ 16.33/5.32 public int indexOf(Object o) { 16.33/5.32 int index = 0; 16.33/5.32 if (o==null) { 16.33/5.32 for (Entry e = header.next; e != header; e = e.next) { 16.33/5.32 if (e.element==null) 16.33/5.32 return index; 16.33/5.32 index++; 16.33/5.32 } 16.33/5.32 } else { 16.33/5.32 for (Entry e = header.next; e != header; e = e.next) { 16.33/5.32 if (o.equals(e.element)) 16.33/5.32 return index; 16.33/5.32 index++; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 return -1; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the index of the last occurrence of the specified element 16.33/5.32 * in this list, or -1 if this list does not contain the element. 16.33/5.32 * More formally, returns the highest index i such that 16.33/5.32 * (o==null ? get(i)==null : o.equals(get(i))), 16.33/5.32 * or -1 if there is no such index. 16.33/5.32 * 16.33/5.32 * @param o element to search for 16.33/5.32 * @return the index of the last occurrence of the specified element in 16.33/5.32 * this list, or -1 if this list does not contain the element 16.33/5.32 */ 16.33/5.32 public int lastIndexOf(Object o) { 16.33/5.32 int index = size; 16.33/5.32 if (o==null) { 16.33/5.32 for (Entry e = header.previous; e != header; e = e.previous) { 16.33/5.32 index--; 16.33/5.32 if (e.element==null) 16.33/5.32 return index; 16.33/5.32 } 16.33/5.32 } else { 16.33/5.32 for (Entry e = header.previous; e != header; e = e.previous) { 16.33/5.32 index--; 16.33/5.32 if (o.equals(e.element)) 16.33/5.32 return index; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 return -1; 16.33/5.32 } 16.33/5.32 16.33/5.32 // Queue operations. 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the head (first element) of this list. 16.33/5.32 * @return the head of this list, or null if this list is empty 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public E peek() { 16.33/5.32 if (size==0) 16.33/5.32 return null; 16.33/5.32 return getFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the head (first element) of this list. 16.33/5.32 * @return the head of this list 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public E element() { 16.33/5.32 return getFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the head (first element) of this list 16.33/5.32 * @return the head of this list, or null if this list is empty 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public E poll() { 16.33/5.32 if (size==0) 16.33/5.32 return null; 16.33/5.32 return removeFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the head (first element) of this list. 16.33/5.32 * 16.33/5.32 * @return the head of this list 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public E remove() { 16.33/5.32 return removeFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Adds the specified element as the tail (last element) of this list. 16.33/5.32 * 16.33/5.32 * @param e the element to add 16.33/5.32 * @return true (as specified by {@link Queue#offer}) 16.33/5.32 * @since 1.5 16.33/5.32 */ 16.33/5.32 public boolean offer(E e) { 16.33/5.32 return add(e); 16.33/5.32 } 16.33/5.32 16.33/5.32 // Deque operations 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the front of this list. 16.33/5.32 * 16.33/5.32 * @param e the element to insert 16.33/5.32 * @return true (as specified by {@link Deque#offerFirst}) 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public boolean offerFirst(E e) { 16.33/5.32 addFirst(e); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element at the end of this list. 16.33/5.32 * 16.33/5.32 * @param e the element to insert 16.33/5.32 * @return true (as specified by {@link Deque#offerLast}) 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public boolean offerLast(E e) { 16.33/5.32 addLast(e); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the first element of this list, 16.33/5.32 * or returns null if this list is empty. 16.33/5.32 * 16.33/5.32 * @return the first element of this list, or null 16.33/5.32 * if this list is empty 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public E peekFirst() { 16.33/5.32 if (size==0) 16.33/5.32 return null; 16.33/5.32 return getFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves, but does not remove, the last element of this list, 16.33/5.32 * or returns null if this list is empty. 16.33/5.32 * 16.33/5.32 * @return the last element of this list, or null 16.33/5.32 * if this list is empty 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public E peekLast() { 16.33/5.32 if (size==0) 16.33/5.32 return null; 16.33/5.32 return getLast(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the first element of this list, 16.33/5.32 * or returns null if this list is empty. 16.33/5.32 * 16.33/5.32 * @return the first element of this list, or null if 16.33/5.32 * this list is empty 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public E pollFirst() { 16.33/5.32 if (size==0) 16.33/5.32 return null; 16.33/5.32 return removeFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retrieves and removes the last element of this list, 16.33/5.32 * or returns null if this list is empty. 16.33/5.32 * 16.33/5.32 * @return the last element of this list, or null if 16.33/5.32 * this list is empty 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public E pollLast() { 16.33/5.32 if (size==0) 16.33/5.32 return null; 16.33/5.32 return removeLast(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Pushes an element onto the stack represented by this list. In other 16.33/5.32 * words, inserts the element at the front of this list. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #addFirst}. 16.33/5.32 * 16.33/5.32 * @param e the element to push 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public void push(E e) { 16.33/5.32 addFirst(e); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Pops an element from the stack represented by this list. In other 16.33/5.32 * words, removes and returns the first element of this list. 16.33/5.32 * 16.33/5.32 *

This method is equivalent to {@link #removeFirst()}. 16.33/5.32 * 16.33/5.32 * @return the element at the front of this list (which is the top 16.33/5.32 * of the stack represented by this list) 16.33/5.32 * @throws NoSuchElementException if this list is empty 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public E pop() { 16.33/5.32 return removeFirst(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the first occurrence of the specified element in this 16.33/5.32 * list (when traversing the list from head to tail). If the list 16.33/5.32 * does not contain the element, it is unchanged. 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this list, if present 16.33/5.32 * @return true if the list contained the specified element 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public boolean removeFirstOccurrence(Object o) { 16.33/5.32 return remove(o); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the last occurrence of the specified element in this 16.33/5.32 * list (when traversing the list from head to tail). If the list 16.33/5.32 * does not contain the element, it is unchanged. 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this list, if present 16.33/5.32 * @return true if the list contained the specified element 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public boolean removeLastOccurrence(Object o) { 16.33/5.32 if (o==null) { 16.33/5.32 for (Entry e = header.previous; e != header; e = e.previous) { 16.33/5.32 if (e.element==null) { 16.33/5.32 remove(e); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 } else { 16.33/5.32 for (Entry e = header.previous; e != header; e = e.previous) { 16.33/5.32 if (o.equals(e.element)) { 16.33/5.32 remove(e); 16.33/5.32 return true; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 } 16.33/5.32 return false; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns a list-iterator of the elements in this list (in proper 16.33/5.32 * sequence), starting at the specified position in the list. 16.33/5.32 * Obeys the general contract of List.listIterator(int).

16.33/5.32 * 16.33/5.32 * The list-iterator is fail-fast: if the list is structurally 16.33/5.32 * modified at any time after the Iterator is created, in any way except 16.33/5.32 * through the list-iterator's own remove or add 16.33/5.32 * methods, the list-iterator will throw a 16.33/5.32 * ConcurrentModificationException. Thus, in the face of 16.33/5.32 * concurrent modification, the iterator fails quickly and cleanly, rather 16.33/5.32 * than risking arbitrary, non-deterministic behavior at an undetermined 16.33/5.32 * time in the future. 16.33/5.32 * 16.33/5.32 * @param index index of the first element to be returned from the 16.33/5.32 * list-iterator (by a call to next) 16.33/5.32 * @return a ListIterator of the elements in this list (in proper 16.33/5.32 * sequence), starting at the specified position in the list 16.33/5.32 * @throws IndexOutOfBoundsException {@inheritDoc} 16.33/5.32 * @see List#listIterator(int) 16.33/5.32 */ 16.33/5.32 public ListIterator listIterator(int index) { 16.33/5.32 return new ListItr(index); 16.33/5.32 } 16.33/5.32 16.33/5.32 private class ListItr implements ListIterator { 16.33/5.32 private Entry lastReturned = header; 16.33/5.32 private Entry next; 16.33/5.32 private int nextIndex; 16.33/5.32 private int expectedModCount = modCount; 16.33/5.32 16.33/5.32 ListItr(int index) { 16.33/5.32 if (index < 0 || index > size) 16.33/5.32 throw new IndexOutOfBoundsException(); 16.33/5.32 if (index < (size >> 1)) { 16.33/5.32 next = header.next; 16.33/5.32 for (nextIndex=0; nextIndexindex; nextIndex--) 16.33/5.32 next = next.previous; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 16.33/5.32 public boolean hasNext() { 16.33/5.32 return nextIndex != size; 16.33/5.32 } 16.33/5.32 16.33/5.32 public E next() { 16.33/5.32 checkForComodification(); 16.33/5.32 if (nextIndex == size) 16.33/5.32 throw new NoSuchElementException(); 16.33/5.32 16.33/5.32 lastReturned = next; 16.33/5.32 next = next.next; 16.33/5.32 nextIndex++; 16.33/5.32 return lastReturned.element; 16.33/5.32 } 16.33/5.32 16.33/5.32 public boolean hasPrevious() { 16.33/5.32 return nextIndex != 0; 16.33/5.32 } 16.33/5.32 16.33/5.32 public E previous() { 16.33/5.32 if (nextIndex == 0) 16.33/5.32 throw new NoSuchElementException(); 16.33/5.32 16.33/5.32 lastReturned = next = next.previous; 16.33/5.32 nextIndex--; 16.33/5.32 checkForComodification(); 16.33/5.32 return lastReturned.element; 16.33/5.32 } 16.33/5.32 16.33/5.32 public int nextIndex() { 16.33/5.32 return nextIndex; 16.33/5.32 } 16.33/5.32 16.33/5.32 public int previousIndex() { 16.33/5.32 return nextIndex-1; 16.33/5.32 } 16.33/5.32 16.33/5.32 public void remove() { 16.33/5.32 checkForComodification(); 16.33/5.32 Entry lastNext = lastReturned.next; 16.33/5.32 try { 16.33/5.32 LinkedList.this.remove(lastReturned); 16.33/5.32 } catch (NoSuchElementException e) { 16.33/5.32 throw new IllegalStateException(); 16.33/5.32 } 16.33/5.32 if (next==lastReturned) 16.33/5.32 next = lastNext; 16.33/5.32 else 16.33/5.32 nextIndex--; 16.33/5.32 lastReturned = header; 16.33/5.32 expectedModCount++; 16.33/5.32 } 16.33/5.32 16.33/5.32 public void set(E e) { 16.33/5.32 if (lastReturned == header) 16.33/5.32 throw new IllegalStateException(); 16.33/5.32 checkForComodification(); 16.33/5.32 lastReturned.element = e; 16.33/5.32 } 16.33/5.32 16.33/5.32 public void add(E e) { 16.33/5.32 checkForComodification(); 16.33/5.32 lastReturned = header; 16.33/5.32 addBefore(e, next); 16.33/5.32 nextIndex++; 16.33/5.32 expectedModCount++; 16.33/5.32 } 16.33/5.32 16.33/5.32 final void checkForComodification() { 16.33/5.32 if (modCount != expectedModCount) 16.33/5.32 throw new ConcurrentModificationException(); 16.33/5.32 } 16.33/5.32 } 16.33/5.32 16.33/5.32 private static class Entry { 16.33/5.32 E element; 16.33/5.32 Entry next; 16.33/5.32 Entry previous; 16.33/5.32 16.33/5.32 Entry(E element, Entry next, Entry previous) { 16.33/5.32 this.element = element; 16.33/5.32 this.next = next; 16.33/5.32 this.previous = previous; 16.33/5.32 } 16.33/5.32 } 16.33/5.32 16.33/5.32 private Entry addBefore(E e, Entry entry) { 16.33/5.32 Entry newEntry = new Entry(e, entry, entry.previous); 16.33/5.32 newEntry.previous.next = newEntry; 16.33/5.32 newEntry.next.previous = newEntry; 16.33/5.32 size++; 16.33/5.32 modCount++; 16.33/5.32 return newEntry; 16.33/5.32 } 16.33/5.32 16.33/5.32 private E remove(Entry e) { 16.33/5.32 if (e == header) 16.33/5.32 throw new NoSuchElementException(); 16.33/5.32 16.33/5.32 E result = e.element; 16.33/5.32 e.previous.next = e.next; 16.33/5.32 e.next.previous = e.previous; 16.33/5.32 e.next = e.previous = null; 16.33/5.32 e.element = null; 16.33/5.32 size--; 16.33/5.32 modCount++; 16.33/5.32 return result; 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * @since 1.6 16.33/5.32 */ 16.33/5.32 public Iterator descendingIterator() { 16.33/5.32 return new DescendingIterator(); 16.33/5.32 } 16.33/5.32 16.33/5.32 /** Adapter to provide descending iterators via ListItr.previous */ 16.33/5.32 private class DescendingIterator implements Iterator { 16.33/5.32 final ListItr itr = new ListItr(size()); 16.33/5.32 public boolean hasNext() { 16.33/5.32 return itr.hasPrevious(); 16.33/5.32 } 16.33/5.32 public E next() { 16.33/5.32 return itr.previous(); 16.33/5.32 } 16.33/5.32 public void remove() { 16.33/5.32 itr.remove(); 16.33/5.32 } 16.33/5.32 } 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns an array containing all of the elements in this list 16.33/5.32 * in proper sequence (from first to last element). 16.33/5.32 * 16.33/5.32 *

The returned array will be "safe" in that no references to it are 16.33/5.32 * maintained by this list. (In other words, this method must allocate 16.33/5.32 * a new array). The caller is thus free to modify the returned array. 16.33/5.32 * 16.33/5.32 *

This method acts as bridge between array-based and collection-based 16.33/5.32 * APIs. 16.33/5.32 * 16.33/5.32 * @return an array containing all of the elements in this list 16.33/5.32 * in proper sequence 16.33/5.32 */ 16.33/5.32 public Object[] toArray() { 16.33/5.32 Object[] result = new Object[size]; 16.33/5.32 int i = 0; 16.33/5.32 for (Entry e = header.next; e != header; e = e.next) 16.33/5.32 result[i++] = e.element; 16.33/5.32 return result; 16.33/5.32 } 16.33/5.32 16.33/5.32 private static final long serialVersionUID = 876323262645176354L; 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 /* 16.33/5.32 * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.32 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.32 * 16.33/5.32 * This code is free software; you can redistribute it and/or modify it 16.33/5.32 * under the terms of the GNU General Public License version 2 only, as 16.33/5.32 * published by the Free Software Foundation. Sun designates this 16.33/5.32 * particular file as subject to the "Classpath" exception as provided 16.33/5.32 * by Sun in the LICENSE file that accompanied this code. 16.33/5.32 * 16.33/5.32 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.32 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.32 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.32 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.32 * accompanied this code). 16.33/5.32 * 16.33/5.32 * You should have received a copy of the GNU General Public License version 16.33/5.32 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.32 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.32 * 16.33/5.32 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.32 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.32 * have any questions. 16.33/5.32 */ 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * An iterator for lists that allows the programmer 16.33/5.32 * to traverse the list in either direction, modify 16.33/5.32 * the list during iteration, and obtain the iterator's 16.33/5.32 * current position in the list. A {@code ListIterator} 16.33/5.32 * has no current element; its cursor position always 16.33/5.32 * lies between the element that would be returned by a call 16.33/5.32 * to {@code previous()} and the element that would be 16.33/5.32 * returned by a call to {@code next()}. 16.33/5.32 * An iterator for a list of length {@code n} has {@code n+1} possible 16.33/5.32 * cursor positions, as illustrated by the carets ({@code ^}) below: 16.33/5.32 *

16.33/5.32	 *                      Element(0)   Element(1)   Element(2)   ... Element(n-1)
16.33/5.32	 * cursor positions:  ^            ^            ^            ^                  ^
16.33/5.32	 * 
16.33/5.32 * Note that the {@link #remove} and {@link #set(Object)} methods are 16.33/5.32 * not defined in terms of the cursor position; they are defined to 16.33/5.32 * operate on the last element returned by a call to {@link #next} or 16.33/5.32 * {@link #previous()}. 16.33/5.32 * 16.33/5.32 *

This interface is a member of the 16.33/5.32 * 16.33/5.32 * Java Collections Framework. 16.33/5.32 * 16.33/5.32 * @author Josh Bloch 16.33/5.32 * @see Collection 16.33/5.32 * @see List 16.33/5.32 * @see Iterator 16.33/5.32 * @see Enumeration 16.33/5.32 * @see List#listIterator() 16.33/5.32 * @since 1.2 16.33/5.32 */ 16.33/5.32 public interface ListIterator extends Iterator { 16.33/5.32 // Query Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns {@code true} if this list iterator has more elements when 16.33/5.32 * traversing the list in the forward direction. (In other words, 16.33/5.32 * returns {@code true} if {@link #next} would return an element rather 16.33/5.32 * than throwing an exception.) 16.33/5.32 * 16.33/5.32 * @return {@code true} if the list iterator has more elements when 16.33/5.32 * traversing the list in the forward direction 16.33/5.32 */ 16.33/5.32 boolean hasNext(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the next element in the list and advances the cursor position. 16.33/5.32 * This method may be called repeatedly to iterate through the list, 16.33/5.32 * or intermixed with calls to {@link #previous} to go back and forth. 16.33/5.32 * (Note that alternating calls to {@code next} and {@code previous} 16.33/5.32 * will return the same element repeatedly.) 16.33/5.32 * 16.33/5.32 * @return the next element in the list 16.33/5.32 * @throws NoSuchElementException if the iteration has no next element 16.33/5.32 */ 16.33/5.32 E next(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns {@code true} if this list iterator has more elements when 16.33/5.32 * traversing the list in the reverse direction. (In other words, 16.33/5.32 * returns {@code true} if {@link #previous} would return an element 16.33/5.32 * rather than throwing an exception.) 16.33/5.32 * 16.33/5.32 * @return {@code true} if the list iterator has more elements when 16.33/5.32 * traversing the list in the reverse direction 16.33/5.32 */ 16.33/5.32 boolean hasPrevious(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the previous element in the list and moves the cursor 16.33/5.32 * position backwards. This method may be called repeatedly to 16.33/5.32 * iterate through the list backwards, or intermixed with calls to 16.33/5.32 * {@link #next} to go back and forth. (Note that alternating calls 16.33/5.32 * to {@code next} and {@code previous} will return the same 16.33/5.32 * element repeatedly.) 16.33/5.32 * 16.33/5.32 * @return the previous element in the list 16.33/5.32 * @throws NoSuchElementException if the iteration has no previous 16.33/5.32 * element 16.33/5.32 */ 16.33/5.32 E previous(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the index of the element that would be returned by a 16.33/5.32 * subsequent call to {@link #next}. (Returns list size if the list 16.33/5.32 * iterator is at the end of the list.) 16.33/5.32 * 16.33/5.32 * @return the index of the element that would be returned by a 16.33/5.32 * subsequent call to {@code next}, or list size if the list 16.33/5.32 * iterator is at the end of the list 16.33/5.32 */ 16.33/5.32 int nextIndex(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the index of the element that would be returned by a 16.33/5.32 * subsequent call to {@link #previous}. (Returns -1 if the list 16.33/5.32 * iterator is at the beginning of the list.) 16.33/5.32 * 16.33/5.32 * @return the index of the element that would be returned by a 16.33/5.32 * subsequent call to {@code previous}, or -1 if the list 16.33/5.32 * iterator is at the beginning of the list 16.33/5.32 */ 16.33/5.32 int previousIndex(); 16.33/5.32 16.33/5.32 16.33/5.32 // Modification Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes from the list the last element that was returned by {@link 16.33/5.32 * #next} or {@link #previous} (optional operation). This call can 16.33/5.32 * only be made once per call to {@code next} or {@code previous}. 16.33/5.32 * It can be made only if {@link #add} has not been 16.33/5.32 * called after the last call to {@code next} or {@code previous}. 16.33/5.32 * 16.33/5.32 * @throws UnsupportedOperationException if the {@code remove} 16.33/5.32 * operation is not supported by this list iterator 16.33/5.32 * @throws IllegalStateException if neither {@code next} nor 16.33/5.32 * {@code previous} have been called, or {@code remove} or 16.33/5.32 * {@code add} have been called after the last call to 16.33/5.32 * {@code next} or {@code previous} 16.33/5.32 */ 16.33/5.32 void remove(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Replaces the last element returned by {@link #next} or 16.33/5.32 * {@link #previous} with the specified element (optional operation). 16.33/5.32 * This call can be made only if neither {@link #remove} nor {@link 16.33/5.32 * #add} have been called after the last call to {@code next} or 16.33/5.32 * {@code previous}. 16.33/5.32 * 16.33/5.32 * @param e the element with which to replace the last element returned by 16.33/5.32 * {@code next} or {@code previous} 16.33/5.32 * @throws UnsupportedOperationException if the {@code set} operation 16.33/5.32 * is not supported by this list iterator 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this list 16.33/5.32 * @throws IllegalArgumentException if some aspect of the specified 16.33/5.32 * element prevents it from being added to this list 16.33/5.32 * @throws IllegalStateException if neither {@code next} nor 16.33/5.32 * {@code previous} have been called, or {@code remove} or 16.33/5.32 * {@code add} have been called after the last call to 16.33/5.32 * {@code next} or {@code previous} 16.33/5.32 */ 16.33/5.32 void set(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts the specified element into the list (optional operation). 16.33/5.32 * The element is inserted immediately before the next element that 16.33/5.32 * would be returned by {@link #next}, if any, and after the next 16.33/5.32 * element that would be returned by {@link #previous}, if any. (If the 16.33/5.32 * list contains no elements, the new element becomes the sole element 16.33/5.32 * on the list.) The new element is inserted before the implicit 16.33/5.32 * cursor: a subsequent call to {@code next} would be unaffected, and a 16.33/5.32 * subsequent call to {@code previous} would return the new element. 16.33/5.32 * (This call increases by one the value that would be returned by a 16.33/5.32 * call to {@code nextIndex} or {@code previousIndex}.) 16.33/5.32 * 16.33/5.32 * @param e the element to insert 16.33/5.32 * @throws UnsupportedOperationException if the {@code add} method is 16.33/5.32 * not supported by this list iterator 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this list 16.33/5.32 * @throws IllegalArgumentException if some aspect of this element 16.33/5.32 * prevents it from being added to this list 16.33/5.32 */ 16.33/5.32 void add(E e); 16.33/5.32 } 16.33/5.32 16.33/5.32 16.33/5.32 /* 16.33/5.32 * Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.32 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.32 * 16.33/5.32 * This code is free software; you can redistribute it and/or modify it 16.33/5.32 * under the terms of the GNU General Public License version 2 only, as 16.33/5.32 * published by the Free Software Foundation. Sun designates this 16.33/5.32 * particular file as subject to the "Classpath" exception as provided 16.33/5.32 * by Sun in the LICENSE file that accompanied this code. 16.33/5.32 * 16.33/5.32 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.32 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.32 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.32 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.32 * accompanied this code). 16.33/5.32 * 16.33/5.32 * You should have received a copy of the GNU General Public License version 16.33/5.32 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.32 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.32 * 16.33/5.32 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.32 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.32 * have any questions. 16.33/5.32 */ 16.33/5.32 16.33/5.32 package javaUtilEx; 16.33/5.32 16.33/5.32 /** 16.33/5.32 * An ordered collection (also known as a sequence). The user of this 16.33/5.32 * interface has precise control over where in the list each element is 16.33/5.32 * inserted. The user can access elements by their integer index (position in 16.33/5.32 * the list), and search for elements in the list.

16.33/5.32 * 16.33/5.32 * Unlike sets, lists typically allow duplicate elements. More formally, 16.33/5.32 * lists typically allow pairs of elements e1 and e2 16.33/5.32 * such that e1.equals(e2), and they typically allow multiple 16.33/5.32 * null elements if they allow null elements at all. It is not inconceivable 16.33/5.32 * that someone might wish to implement a list that prohibits duplicates, by 16.33/5.32 * throwing runtime exceptions when the user attempts to insert them, but we 16.33/5.32 * expect this usage to be rare.

16.33/5.32 * 16.33/5.32 * The List interface places additional stipulations, beyond those 16.33/5.32 * specified in the Collection interface, on the contracts of the 16.33/5.32 * iterator, add, remove, equals, and 16.33/5.32 * hashCode methods. Declarations for other inherited methods are 16.33/5.32 * also included here for convenience.

16.33/5.32 * 16.33/5.32 * The List interface provides four methods for positional (indexed) 16.33/5.32 * access to list elements. Lists (like Java arrays) are zero based. Note 16.33/5.32 * that these operations may execute in time proportional to the index value 16.33/5.32 * for some implementations (the LinkedList class, for 16.33/5.32 * example). Thus, iterating over the elements in a list is typically 16.33/5.32 * preferable to indexing through it if the caller does not know the 16.33/5.32 * implementation.

16.33/5.32 * 16.33/5.32 * The List interface provides a special iterator, called a 16.33/5.32 * ListIterator, that allows element insertion and replacement, and 16.33/5.32 * bidirectional access in addition to the normal operations that the 16.33/5.32 * Iterator interface provides. A method is provided to obtain a 16.33/5.32 * list iterator that starts at a specified position in the list.

16.33/5.32 * 16.33/5.32 * The List interface provides two methods to search for a specified 16.33/5.32 * object. From a performance standpoint, these methods should be used with 16.33/5.32 * caution. In many implementations they will perform costly linear 16.33/5.32 * searches.

16.33/5.32 * 16.33/5.32 * The List interface provides two methods to efficiently insert and 16.33/5.32 * remove multiple elements at an arbitrary point in the list.

16.33/5.32 * 16.33/5.32 * Note: While it is permissible for lists to contain themselves as elements, 16.33/5.32 * extreme caution is advised: the equals and hashCode 16.33/5.32 * methods are no longer well defined on such a list. 16.33/5.32 * 16.33/5.32 *

Some list implementations have restrictions on the elements that 16.33/5.32 * they may contain. For example, some implementations prohibit null elements, 16.33/5.32 * and some have restrictions on the types of their elements. Attempting to 16.33/5.32 * add an ineligible element throws an unchecked exception, typically 16.33/5.32 * NullPointerException or ClassCastException. Attempting 16.33/5.32 * to query the presence of an ineligible element may throw an exception, 16.33/5.32 * or it may simply return false; some implementations will exhibit the former 16.33/5.32 * behavior and some will exhibit the latter. More generally, attempting an 16.33/5.32 * operation on an ineligible element whose completion would not result in 16.33/5.32 * the insertion of an ineligible element into the list may throw an 16.33/5.32 * exception or it may succeed, at the option of the implementation. 16.33/5.32 * Such exceptions are marked as "optional" in the specification for this 16.33/5.32 * interface. 16.33/5.32 * 16.33/5.32 *

This interface is a member of the 16.33/5.32 * 16.33/5.32 * Java Collections Framework. 16.33/5.32 * 16.33/5.32 * @author Josh Bloch 16.33/5.32 * @author Neal Gafter 16.33/5.32 * @see Collection 16.33/5.32 * @see Set 16.33/5.32 * @see ArrayList 16.33/5.32 * @see LinkedList 16.33/5.32 * @see Vector 16.33/5.32 * @see Arrays#asList(Object[]) 16.33/5.32 * @see Collections#nCopies(int, Object) 16.33/5.32 * @see Collections#EMPTY_LIST 16.33/5.32 * @see AbstractList 16.33/5.32 * @see AbstractSequentialList 16.33/5.32 * @since 1.2 16.33/5.32 */ 16.33/5.32 16.33/5.32 public interface List extends Collection { 16.33/5.32 // Query Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns the number of elements in this list. If this list contains 16.33/5.32 * more than Integer.MAX_VALUE elements, returns 16.33/5.32 * Integer.MAX_VALUE. 16.33/5.32 * 16.33/5.32 * @return the number of elements in this list 16.33/5.32 */ 16.33/5.32 int size(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns true if this list contains no elements. 16.33/5.32 * 16.33/5.32 * @return true if this list contains no elements 16.33/5.32 */ 16.33/5.32 boolean isEmpty(); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns true if this list contains the specified element. 16.33/5.32 * More formally, returns true if and only if this list contains 16.33/5.32 * at least one element e such that 16.33/5.32 * (o==null ? e==null : o.equals(e)). 16.33/5.32 * 16.33/5.32 * @param o element whose presence in this list is to be tested 16.33/5.32 * @return true if this list contains the specified element 16.33/5.32 * @throws ClassCastException if the type of the specified element 16.33/5.32 * is incompatible with this list (optional) 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * list does not permit null elements (optional) 16.33/5.32 */ 16.33/5.32 boolean contains(Object o); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns an iterator over the elements in this list in proper sequence. 16.33/5.32 * 16.33/5.32 * @return an iterator over the elements in this list in proper sequence 16.33/5.32 */ 16.33/5.32 Iterator iterator(); 16.33/5.32 16.33/5.32 // Modification Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Appends the specified element to the end of this list (optional 16.33/5.32 * operation). 16.33/5.32 * 16.33/5.32 *

Lists that support this operation may place limitations on what 16.33/5.32 * elements may be added to this list. In particular, some 16.33/5.32 * lists will refuse to add null elements, and others will impose 16.33/5.32 * restrictions on the type of elements that may be added. List 16.33/5.32 * classes should clearly specify in their documentation any restrictions 16.33/5.32 * on what elements may be added. 16.33/5.32 * 16.33/5.32 * @param e element to be appended to this list 16.33/5.32 * @return true (as specified by {@link Collection#add}) 16.33/5.32 * @throws UnsupportedOperationException if the add operation 16.33/5.32 * is not supported by this list 16.33/5.32 * @throws ClassCastException if the class of the specified element 16.33/5.32 * prevents it from being added to this list 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * list does not permit null elements 16.33/5.32 * @throws IllegalArgumentException if some property of this element 16.33/5.32 * prevents it from being added to this list 16.33/5.32 */ 16.33/5.32 boolean add(E e); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes the first occurrence of the specified element from this list, 16.33/5.32 * if it is present (optional operation). If this list does not contain 16.33/5.32 * the element, it is unchanged. More formally, removes the element with 16.33/5.32 * the lowest index i such that 16.33/5.32 * (o==null ? get(i)==null : o.equals(get(i))) 16.33/5.32 * (if such an element exists). Returns true if this list 16.33/5.32 * contained the specified element (or equivalently, if this list changed 16.33/5.32 * as a result of the call). 16.33/5.32 * 16.33/5.32 * @param o element to be removed from this list, if present 16.33/5.32 * @return true if this list contained the specified element 16.33/5.32 * @throws ClassCastException if the type of the specified element 16.33/5.32 * is incompatible with this list (optional) 16.33/5.32 * @throws NullPointerException if the specified element is null and this 16.33/5.32 * list does not permit null elements (optional) 16.33/5.32 * @throws UnsupportedOperationException if the remove operation 16.33/5.32 * is not supported by this list 16.33/5.32 */ 16.33/5.32 boolean remove(Object o); 16.33/5.32 16.33/5.32 16.33/5.32 // Bulk Modification Operations 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Returns true if this list contains all of the elements of the 16.33/5.32 * specified collection. 16.33/5.32 * 16.33/5.32 * @param c collection to be checked for containment in this list 16.33/5.32 * @return true if this list contains all of the elements of the 16.33/5.32 * specified collection 16.33/5.32 * @throws ClassCastException if the types of one or more elements 16.33/5.32 * in the specified collection are incompatible with this 16.33/5.32 * list (optional) 16.33/5.32 * @throws NullPointerException if the specified collection contains one 16.33/5.32 * or more null elements and this list does not permit null 16.33/5.32 * elements (optional), or if the specified collection is null 16.33/5.32 * @see #contains(Object) 16.33/5.32 */ 16.33/5.32 boolean containsAll(Collection c); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Appends all of the elements in the specified collection to the end of 16.33/5.32 * this list, in the order that they are returned by the specified 16.33/5.32 * collection's iterator (optional operation). The behavior of this 16.33/5.32 * operation is undefined if the specified collection is modified while 16.33/5.32 * the operation is in progress. (Note that this will occur if the 16.33/5.32 * specified collection is this list, and it's nonempty.) 16.33/5.32 * 16.33/5.32 * @param c collection containing elements to be added to this list 16.33/5.32 * @return true if this list changed as a result of the call 16.33/5.32 * @throws UnsupportedOperationException if the addAll operation 16.33/5.32 * is not supported by this list 16.33/5.32 * @throws ClassCastException if the class of an element of the specified 16.33/5.32 * collection prevents it from being added to this list 16.33/5.32 * @throws NullPointerException if the specified collection contains one 16.33/5.32 * or more null elements and this list does not permit null 16.33/5.32 * elements, or if the specified collection is null 16.33/5.32 * @throws IllegalArgumentException if some property of an element of the 16.33/5.32 * specified collection prevents it from being added to this list 16.33/5.32 * @see #add(Object) 16.33/5.32 */ 16.33/5.32 boolean addAll(Collection c); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Inserts all of the elements in the specified collection into this 16.33/5.32 * list at the specified position (optional operation). Shifts the 16.33/5.32 * element currently at that position (if any) and any subsequent 16.33/5.32 * elements to the right (increases their indices). The new elements 16.33/5.32 * will appear in this list in the order that they are returned by the 16.33/5.32 * specified collection's iterator. The behavior of this operation is 16.33/5.32 * undefined if the specified collection is modified while the 16.33/5.32 * operation is in progress. (Note that this will occur if the specified 16.33/5.32 * collection is this list, and it's nonempty.) 16.33/5.32 * 16.33/5.32 * @param index index at which to insert the first element from the 16.33/5.32 * specified collection 16.33/5.32 * @param c collection containing elements to be added to this list 16.33/5.32 * @return true if this list changed as a result of the call 16.33/5.32 * @throws UnsupportedOperationException if the addAll operation 16.33/5.32 * is not supported by this list 16.33/5.32 * @throws ClassCastException if the class of an element of the specified 16.33/5.32 * collection prevents it from being added to this list 16.33/5.32 * @throws NullPointerException if the specified collection contains one 16.33/5.32 * or more null elements and this list does not permit null 16.33/5.32 * elements, or if the specified collection is null 16.33/5.32 * @throws IllegalArgumentException if some property of an element of the 16.33/5.32 * specified collection prevents it from being added to this list 16.33/5.32 * @throws IndexOutOfBoundsException if the index is out of range 16.33/5.32 * (index < 0 || index > size()) 16.33/5.32 */ 16.33/5.32 boolean addAll(int index, Collection c); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes from this list all of its elements that are contained in the 16.33/5.32 * specified collection (optional operation). 16.33/5.32 * 16.33/5.32 * @param c collection containing elements to be removed from this list 16.33/5.32 * @return true if this list changed as a result of the call 16.33/5.32 * @throws UnsupportedOperationException if the removeAll operation 16.33/5.32 * is not supported by this list 16.33/5.32 * @throws ClassCastException if the class of an element of this list 16.33/5.32 * is incompatible with the specified collection (optional) 16.33/5.32 * @throws NullPointerException if this list contains a null element and the 16.33/5.32 * specified collection does not permit null elements (optional), 16.33/5.32 * or if the specified collection is null 16.33/5.32 * @see #remove(Object) 16.33/5.32 * @see #contains(Object) 16.33/5.32 */ 16.33/5.32 boolean removeAll(Collection c); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Retains only the elements in this list that are contained in the 16.33/5.32 * specified collection (optional operation). In other words, removes 16.33/5.32 * from this list all of its elements that are not contained in the 16.33/5.32 * specified collection. 16.33/5.32 * 16.33/5.32 * @param c collection containing elements to be retained in this list 16.33/5.32 * @return true if this list changed as a result of the call 16.33/5.32 * @throws UnsupportedOperationException if the retainAll operation 16.33/5.32 * is not supported by this list 16.33/5.32 * @throws ClassCastException if the class of an element of this list 16.33/5.32 * is incompatible with the specified collection (optional) 16.33/5.32 * @throws NullPointerException if this list contains a null element and the 16.33/5.32 * specified collection does not permit null elements (optional), 16.33/5.32 * or if the specified collection is null 16.33/5.32 * @see #remove(Object) 16.33/5.32 * @see #contains(Object) 16.33/5.32 */ 16.33/5.32 boolean retainAll(Collection c); 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Removes all of the elements from this list (optional operation). 16.33/5.32 * The list will be empty after this call returns. 16.33/5.32 * 16.33/5.32 * @throws UnsupportedOperationException if the clear operation 16.33/5.32 * is not supported by this list 16.33/5.32 */ 16.33/5.32 void clear(); 16.33/5.32 16.33/5.32 16.33/5.32 // Comparison and hashing 16.33/5.32 16.33/5.32 /** 16.33/5.32 * Compares the specified object with this list for equality. Returns 16.33/5.33 * true if and only if the specified object is also a list, both 16.33/5.33 * lists have the same size, and all corresponding pairs of elements in 16.33/5.33 * the two lists are equal. (Two elements e1 and 16.33/5.33 * e2 are equal if (e1==null ? e2==null : 16.33/5.33 * e1.equals(e2)).) In other words, two lists are defined to be 16.33/5.33 * equal if they contain the same elements in the same order. This 16.33/5.33 * definition ensures that the equals method works properly across 16.33/5.33 * different implementations of the List interface. 16.33/5.33 * 16.33/5.33 * @param o the object to be compared for equality with this list 16.33/5.33 * @return true if the specified object is equal to this list 16.33/5.33 */ 16.33/5.33 boolean equals(Object o); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns the hash code value for this list. The hash code of a list 16.33/5.33 * is defined to be the result of the following calculation: 16.33/5.33 *

16.33/5.33	     *  int hashCode = 1;
16.33/5.33	     *  for (E e : list)
16.33/5.33	     *      hashCode = 31*hashCode + (e==null ? 0 : e.hashCode());
16.33/5.33	     * 
16.33/5.33 * This ensures that list1.equals(list2) implies that 16.33/5.33 * list1.hashCode()==list2.hashCode() for any two lists, 16.33/5.33 * list1 and list2, as required by the general 16.33/5.33 * contract of {@link Object#hashCode}. 16.33/5.33 * 16.33/5.33 * @return the hash code value for this list 16.33/5.33 * @see Object#equals(Object) 16.33/5.33 * @see #equals(Object) 16.33/5.33 */ 16.33/5.33 int hashCode(); 16.33/5.33 16.33/5.33 16.33/5.33 // Positional Access Operations 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns the element at the specified position in this list. 16.33/5.33 * 16.33/5.33 * @param index index of the element to return 16.33/5.33 * @return the element at the specified position in this list 16.33/5.33 * @throws IndexOutOfBoundsException if the index is out of range 16.33/5.33 * (index < 0 || index >= size()) 16.33/5.33 */ 16.33/5.33 E get(int index); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Replaces the element at the specified position in this list with the 16.33/5.33 * specified element (optional operation). 16.33/5.33 * 16.33/5.33 * @param index index of the element to replace 16.33/5.33 * @param element element to be stored at the specified position 16.33/5.33 * @return the element previously at the specified position 16.33/5.33 * @throws UnsupportedOperationException if the set operation 16.33/5.33 * is not supported by this list 16.33/5.33 * @throws ClassCastException if the class of the specified element 16.33/5.33 * prevents it from being added to this list 16.33/5.33 * @throws NullPointerException if the specified element is null and 16.33/5.33 * this list does not permit null elements 16.33/5.33 * @throws IllegalArgumentException if some property of the specified 16.33/5.33 * element prevents it from being added to this list 16.33/5.33 * @throws IndexOutOfBoundsException if the index is out of range 16.33/5.33 * (index < 0 || index >= size()) 16.33/5.33 */ 16.33/5.33 E set(int index, E element); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Inserts the specified element at the specified position in this list 16.33/5.33 * (optional operation). Shifts the element currently at that position 16.33/5.33 * (if any) and any subsequent elements to the right (adds one to their 16.33/5.33 * indices). 16.33/5.33 * 16.33/5.33 * @param index index at which the specified element is to be inserted 16.33/5.33 * @param element element to be inserted 16.33/5.33 * @throws UnsupportedOperationException if the add operation 16.33/5.33 * is not supported by this list 16.33/5.33 * @throws ClassCastException if the class of the specified element 16.33/5.33 * prevents it from being added to this list 16.33/5.33 * @throws NullPointerException if the specified element is null and 16.33/5.33 * this list does not permit null elements 16.33/5.33 * @throws IllegalArgumentException if some property of the specified 16.33/5.33 * element prevents it from being added to this list 16.33/5.33 * @throws IndexOutOfBoundsException if the index is out of range 16.33/5.33 * (index < 0 || index > size()) 16.33/5.33 */ 16.33/5.33 void add(int index, E element); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Removes the element at the specified position in this list (optional 16.33/5.33 * operation). Shifts any subsequent elements to the left (subtracts one 16.33/5.33 * from their indices). Returns the element that was removed from the 16.33/5.33 * list. 16.33/5.33 * 16.33/5.33 * @param index the index of the element to be removed 16.33/5.33 * @return the element previously at the specified position 16.33/5.33 * @throws UnsupportedOperationException if the remove operation 16.33/5.33 * is not supported by this list 16.33/5.33 * @throws IndexOutOfBoundsException if the index is out of range 16.33/5.33 * (index < 0 || index >= size()) 16.33/5.33 */ 16.33/5.33 E remove(int index); 16.33/5.33 16.33/5.33 16.33/5.33 // Search Operations 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns the index of the first occurrence of the specified element 16.33/5.33 * in this list, or -1 if this list does not contain the element. 16.33/5.33 * More formally, returns the lowest index i such that 16.33/5.33 * (o==null ? get(i)==null : o.equals(get(i))), 16.33/5.33 * or -1 if there is no such index. 16.33/5.33 * 16.33/5.33 * @param o element to search for 16.33/5.33 * @return the index of the first occurrence of the specified element in 16.33/5.33 * this list, or -1 if this list does not contain the element 16.33/5.33 * @throws ClassCastException if the type of the specified element 16.33/5.33 * is incompatible with this list (optional) 16.33/5.33 * @throws NullPointerException if the specified element is null and this 16.33/5.33 * list does not permit null elements (optional) 16.33/5.33 */ 16.33/5.33 int indexOf(Object o); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns the index of the last occurrence of the specified element 16.33/5.33 * in this list, or -1 if this list does not contain the element. 16.33/5.33 * More formally, returns the highest index i such that 16.33/5.33 * (o==null ? get(i)==null : o.equals(get(i))), 16.33/5.33 * or -1 if there is no such index. 16.33/5.33 * 16.33/5.33 * @param o element to search for 16.33/5.33 * @return the index of the last occurrence of the specified element in 16.33/5.33 * this list, or -1 if this list does not contain the element 16.33/5.33 * @throws ClassCastException if the type of the specified element 16.33/5.33 * is incompatible with this list (optional) 16.33/5.33 * @throws NullPointerException if the specified element is null and this 16.33/5.33 * list does not permit null elements (optional) 16.33/5.33 */ 16.33/5.33 int lastIndexOf(Object o); 16.33/5.33 16.33/5.33 16.33/5.33 // List Iterators 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns a list iterator over the elements in this list (in proper 16.33/5.33 * sequence). 16.33/5.33 * 16.33/5.33 * @return a list iterator over the elements in this list (in proper 16.33/5.33 * sequence) 16.33/5.33 */ 16.33/5.33 ListIterator listIterator(); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns a list iterator over the elements in this list (in proper 16.33/5.33 * sequence), starting at the specified position in the list. 16.33/5.33 * The specified index indicates the first element that would be 16.33/5.33 * returned by an initial call to {@link ListIterator#next next}. 16.33/5.33 * An initial call to {@link ListIterator#previous previous} would 16.33/5.33 * return the element with the specified index minus one. 16.33/5.33 * 16.33/5.33 * @param index index of the first element to be returned from the 16.33/5.33 * list iterator (by a call to {@link ListIterator#next next}) 16.33/5.33 * @return a list iterator over the elements in this list (in proper 16.33/5.33 * sequence), starting at the specified position in the list 16.33/5.33 * @throws IndexOutOfBoundsException if the index is out of range 16.33/5.33 * ({@code index < 0 || index > size()}) 16.33/5.33 */ 16.33/5.33 ListIterator listIterator(int index); 16.33/5.33 16.33/5.33 // View 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Returns a view of the portion of this list between the specified 16.33/5.33 * fromIndex, inclusive, and toIndex, exclusive. (If 16.33/5.33 * fromIndex and toIndex are equal, the returned list is 16.33/5.33 * empty.) The returned list is backed by this list, so non-structural 16.33/5.33 * changes in the returned list are reflected in this list, and vice-versa. 16.33/5.33 * The returned list supports all of the optional list operations supported 16.33/5.33 * by this list.

16.33/5.33 * 16.33/5.33 * This method eliminates the need for explicit range operations (of 16.33/5.33 * the sort that commonly exist for arrays). Any operation that expects 16.33/5.33 * a list can be used as a range operation by passing a subList view 16.33/5.33 * instead of a whole list. For example, the following idiom 16.33/5.33 * removes a range of elements from a list: 16.33/5.33 *

16.33/5.33	     *      list.subList(from, to).clear();
16.33/5.33	     * 
16.33/5.33 * Similar idioms may be constructed for indexOf and 16.33/5.33 * lastIndexOf, and all of the algorithms in the 16.33/5.33 * Collections class can be applied to a subList.

16.33/5.33 * 16.33/5.33 * The semantics of the list returned by this method become undefined if 16.33/5.33 * the backing list (i.e., this list) is structurally modified in 16.33/5.33 * any way other than via the returned list. (Structural modifications are 16.33/5.33 * those that change the size of this list, or otherwise perturb it in such 16.33/5.33 * a fashion that iterations in progress may yield incorrect results.) 16.33/5.33 * 16.33/5.33 * @param fromIndex low endpoint (inclusive) of the subList 16.33/5.33 * @param toIndex high endpoint (exclusive) of the subList 16.33/5.33 * @return a view of the specified range within this list 16.33/5.33 * @throws IndexOutOfBoundsException for an illegal endpoint index value 16.33/5.33 * (fromIndex < 0 || toIndex > size || 16.33/5.33 * fromIndex > toIndex) 16.33/5.33 */ 16.33/5.33 List subList(int fromIndex, int toIndex); 16.33/5.33 } 16.33/5.33 16.33/5.33 16.33/5.33 /* 16.33/5.33 * Copyright 1994-1998 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.33 * 16.33/5.33 * This code is free software; you can redistribute it and/or modify it 16.33/5.33 * under the terms of the GNU General Public License version 2 only, as 16.33/5.33 * published by the Free Software Foundation. Sun designates this 16.33/5.33 * particular file as subject to the "Classpath" exception as provided 16.33/5.33 * by Sun in the LICENSE file that accompanied this code. 16.33/5.33 * 16.33/5.33 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.33 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.33 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.33 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.33 * accompanied this code). 16.33/5.33 * 16.33/5.33 * You should have received a copy of the GNU General Public License version 16.33/5.33 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.33 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.33 * 16.33/5.33 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.33 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.33 * have any questions. 16.33/5.33 */ 16.33/5.33 16.33/5.33 package javaUtilEx; 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Thrown by the nextElement method of an 16.33/5.33 * Enumeration to indicate that there are no more 16.33/5.33 * elements in the enumeration. 16.33/5.33 * 16.33/5.33 * @author unascribed 16.33/5.33 * @see java.util.Enumeration 16.33/5.33 * @see java.util.Enumeration#nextElement() 16.33/5.33 * @since JDK1.0 16.33/5.33 */ 16.33/5.33 public 16.33/5.33 class NoSuchElementException extends RuntimeException { 16.33/5.33 /** 16.33/5.33 * Constructs a NoSuchElementException with null 16.33/5.33 * as its error message string. 16.33/5.33 */ 16.33/5.33 public NoSuchElementException() { 16.33/5.33 super(); 16.33/5.33 } 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Constructs a NoSuchElementException, saving a reference 16.33/5.33 * to the error message string s for later retrieval by the 16.33/5.33 * getMessage method. 16.33/5.33 * 16.33/5.33 * @param s the detail message. 16.33/5.33 */ 16.33/5.33 public NoSuchElementException(String s) { 16.33/5.33 super(s); 16.33/5.33 } 16.33/5.33 } 16.33/5.33 16.33/5.33 16.33/5.33 /* 16.33/5.33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.33 * 16.33/5.33 * This code is free software; you can redistribute it and/or modify it 16.33/5.33 * under the terms of the GNU General Public License version 2 only, as 16.33/5.33 * published by the Free Software Foundation. Sun designates this 16.33/5.33 * particular file as subject to the "Classpath" exception as provided 16.33/5.33 * by Sun in the LICENSE file that accompanied this code. 16.33/5.33 * 16.33/5.33 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.33 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.33 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.33 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.33 * accompanied this code). 16.33/5.33 * 16.33/5.33 * You should have received a copy of the GNU General Public License version 16.33/5.33 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.33 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.33 * 16.33/5.33 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.33 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.33 * have any questions. 16.33/5.33 */ 16.33/5.33 16.33/5.33 /* 16.33/5.33 * This file is available under and governed by the GNU General Public 16.33/5.33 * License version 2 only, as published by the Free Software Foundation. 16.33/5.33 * However, the following notice accompanied the original version of this 16.33/5.33 * file: 16.33/5.33 * 16.33/5.33 * Written by Doug Lea with assistance from members of JCP JSR-166 16.33/5.33 * Expert Group and released to the public domain, as explained at 16.33/5.33 * http://creativecommons.org/licenses/publicdomain 16.33/5.33 */ 16.33/5.33 16.33/5.33 package javaUtilEx; 16.33/5.33 16.33/5.33 /** 16.33/5.33 * A collection designed for holding elements prior to processing. 16.33/5.33 * Besides basic {@link java.util.Collection Collection} operations, 16.33/5.33 * queues provide additional insertion, extraction, and inspection 16.33/5.33 * operations. Each of these methods exists in two forms: one throws 16.33/5.33 * an exception if the operation fails, the other returns a special 16.33/5.33 * value (either null or false, depending on the 16.33/5.33 * operation). The latter form of the insert operation is designed 16.33/5.33 * specifically for use with capacity-restricted Queue 16.33/5.33 * implementations; in most implementations, insert operations cannot 16.33/5.33 * fail. 16.33/5.33 * 16.33/5.33 *

16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 * 16.33/5.33 *
Throws exceptionReturns special value
Insert{@link #add add(e)}{@link #offer offer(e)}
Remove{@link #remove remove()}{@link #poll poll()}
Examine{@link #element element()}{@link #peek peek()}
16.33/5.33 * 16.33/5.33 *

Queues typically, but do not necessarily, order elements in a 16.33/5.33 * FIFO (first-in-first-out) manner. Among the exceptions are 16.33/5.33 * priority queues, which order elements according to a supplied 16.33/5.33 * comparator, or the elements' natural ordering, and LIFO queues (or 16.33/5.33 * stacks) which order the elements LIFO (last-in-first-out). 16.33/5.33 * Whatever the ordering used, the head of the queue is that 16.33/5.33 * element which would be removed by a call to {@link #remove() } or 16.33/5.33 * {@link #poll()}. In a FIFO queue, all new elements are inserted at 16.33/5.33 * the tail of the queue. Other kinds of queues may use 16.33/5.33 * different placement rules. Every Queue implementation 16.33/5.33 * must specify its ordering properties. 16.33/5.33 * 16.33/5.33 *

The {@link #offer offer} method inserts an element if possible, 16.33/5.33 * otherwise returning false. This differs from the {@link 16.33/5.33 * java.util.Collection#add Collection.add} method, which can fail to 16.33/5.33 * add an element only by throwing an unchecked exception. The 16.33/5.33 * offer method is designed for use when failure is a normal, 16.33/5.33 * rather than exceptional occurrence, for example, in fixed-capacity 16.33/5.33 * (or "bounded") queues. 16.33/5.33 * 16.33/5.33 *

The {@link #remove()} and {@link #poll()} methods remove and 16.33/5.33 * return the head of the queue. 16.33/5.33 * Exactly which element is removed from the queue is a 16.33/5.33 * function of the queue's ordering policy, which differs from 16.33/5.33 * implementation to implementation. The remove() and 16.33/5.33 * poll() methods differ only in their behavior when the 16.33/5.33 * queue is empty: the remove() method throws an exception, 16.33/5.33 * while the poll() method returns null. 16.33/5.33 * 16.33/5.33 *

The {@link #element()} and {@link #peek()} methods return, but do 16.33/5.33 * not remove, the head of the queue. 16.33/5.33 * 16.33/5.33 *

The Queue interface does not define the blocking queue 16.33/5.33 * methods, which are common in concurrent programming. These methods, 16.33/5.33 * which wait for elements to appear or for space to become available, are 16.33/5.33 * defined in the {@link java.util.concurrent.BlockingQueue} interface, which 16.33/5.33 * extends this interface. 16.33/5.33 * 16.33/5.33 *

Queue implementations generally do not allow insertion 16.33/5.33 * of null elements, although some implementations, such as 16.33/5.33 * {@link LinkedList}, do not prohibit insertion of null. 16.33/5.33 * Even in the implementations that permit it, null should 16.33/5.33 * not be inserted into a Queue, as null is also 16.33/5.33 * used as a special return value by the poll method to 16.33/5.33 * indicate that the queue contains no elements. 16.33/5.33 * 16.33/5.33 *

Queue implementations generally do not define 16.33/5.33 * element-based versions of methods equals and 16.33/5.33 * hashCode but instead inherit the identity based versions 16.33/5.33 * from class Object, because element-based equality is not 16.33/5.33 * always well-defined for queues with the same elements but different 16.33/5.33 * ordering properties. 16.33/5.33 * 16.33/5.33 * 16.33/5.33 *

This interface is a member of the 16.33/5.33 * 16.33/5.33 * Java Collections Framework. 16.33/5.33 * 16.33/5.33 * @see java.util.Collection 16.33/5.33 * @see LinkedList 16.33/5.33 * @see PriorityQueue 16.33/5.33 * @see java.util.concurrent.LinkedBlockingQueue 16.33/5.33 * @see java.util.concurrent.BlockingQueue 16.33/5.33 * @see java.util.concurrent.ArrayBlockingQueue 16.33/5.33 * @see java.util.concurrent.LinkedBlockingQueue 16.33/5.33 * @see java.util.concurrent.PriorityBlockingQueue 16.33/5.33 * @since 1.5 16.33/5.33 * @author Doug Lea 16.33/5.33 * @param the type of elements held in this collection 16.33/5.33 */ 16.33/5.33 public interface Queue extends Collection { 16.33/5.33 /** 16.33/5.33 * Inserts the specified element into this queue if it is possible to do so 16.33/5.33 * immediately without violating capacity restrictions, returning 16.33/5.33 * true upon success and throwing an IllegalStateException 16.33/5.33 * if no space is currently available. 16.33/5.33 * 16.33/5.33 * @param e the element to add 16.33/5.33 * @return true (as specified by {@link Collection#add}) 16.33/5.33 * @throws IllegalStateException if the element cannot be added at this 16.33/5.33 * time due to capacity restrictions 16.33/5.33 * @throws ClassCastException if the class of the specified element 16.33/5.33 * prevents it from being added to this queue 16.33/5.33 * @throws NullPointerException if the specified element is null and 16.33/5.33 * this queue does not permit null elements 16.33/5.33 * @throws IllegalArgumentException if some property of this element 16.33/5.33 * prevents it from being added to this queue 16.33/5.33 */ 16.33/5.33 boolean add(E e); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Inserts the specified element into this queue if it is possible to do 16.33/5.33 * so immediately without violating capacity restrictions. 16.33/5.33 * When using a capacity-restricted queue, this method is generally 16.33/5.33 * preferable to {@link #add}, which can fail to insert an element only 16.33/5.33 * by throwing an exception. 16.33/5.33 * 16.33/5.33 * @param e the element to add 16.33/5.33 * @return true if the element was added to this queue, else 16.33/5.33 * false 16.33/5.33 * @throws ClassCastException if the class of the specified element 16.33/5.33 * prevents it from being added to this queue 16.33/5.33 * @throws NullPointerException if the specified element is null and 16.33/5.33 * this queue does not permit null elements 16.33/5.33 * @throws IllegalArgumentException if some property of this element 16.33/5.33 * prevents it from being added to this queue 16.33/5.33 */ 16.33/5.33 boolean offer(E e); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Retrieves and removes the head of this queue. This method differs 16.33/5.33 * from {@link #poll poll} only in that it throws an exception if this 16.33/5.33 * queue is empty. 16.33/5.33 * 16.33/5.33 * @return the head of this queue 16.33/5.33 * @throws NoSuchElementException if this queue is empty 16.33/5.33 */ 16.33/5.33 E remove(); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Retrieves and removes the head of this queue, 16.33/5.33 * or returns null if this queue is empty. 16.33/5.33 * 16.33/5.33 * @return the head of this queue, or null if this queue is empty 16.33/5.33 */ 16.33/5.33 E poll(); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Retrieves, but does not remove, the head of this queue. This method 16.33/5.33 * differs from {@link #peek peek} only in that it throws an exception 16.33/5.33 * if this queue is empty. 16.33/5.33 * 16.33/5.33 * @return the head of this queue 16.33/5.33 * @throws NoSuchElementException if this queue is empty 16.33/5.33 */ 16.33/5.33 E element(); 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Retrieves, but does not remove, the head of this queue, 16.33/5.33 * or returns null if this queue is empty. 16.33/5.33 * 16.33/5.33 * @return the head of this queue, or null if this queue is empty 16.33/5.33 */ 16.33/5.33 E peek(); 16.33/5.33 } 16.33/5.33 16.33/5.33 16.33/5.33 /* 16.33/5.33 * Copyright 2000-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.33 * 16.33/5.33 * This code is free software; you can redistribute it and/or modify it 16.33/5.33 * under the terms of the GNU General Public License version 2 only, as 16.33/5.33 * published by the Free Software Foundation. Sun designates this 16.33/5.33 * particular file as subject to the "Classpath" exception as provided 16.33/5.33 * by Sun in the LICENSE file that accompanied this code. 16.33/5.33 * 16.33/5.33 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.33 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.33 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.33 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.33 * accompanied this code). 16.33/5.33 * 16.33/5.33 * You should have received a copy of the GNU General Public License version 16.33/5.33 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.33 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.33 * 16.33/5.33 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.33 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.33 * have any questions. 16.33/5.33 */ 16.33/5.33 16.33/5.33 package javaUtilEx; 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Marker interface used by List implementations to indicate that 16.33/5.33 * they support fast (generally constant time) random access. The primary 16.33/5.33 * purpose of this interface is to allow generic algorithms to alter their 16.33/5.33 * behavior to provide good performance when applied to either random or 16.33/5.33 * sequential access lists. 16.33/5.33 * 16.33/5.33 *

The best algorithms for manipulating random access lists (such as 16.33/5.33 * ArrayList) can produce quadratic behavior when applied to 16.33/5.33 * sequential access lists (such as LinkedList). Generic list 16.33/5.33 * algorithms are encouraged to check whether the given list is an 16.33/5.33 * instanceof this interface before applying an algorithm that would 16.33/5.33 * provide poor performance if it were applied to a sequential access list, 16.33/5.33 * and to alter their behavior if necessary to guarantee acceptable 16.33/5.33 * performance. 16.33/5.33 * 16.33/5.33 *

It is recognized that the distinction between random and sequential 16.33/5.33 * access is often fuzzy. For example, some List implementations 16.33/5.33 * provide asymptotically linear access times if they get huge, but constant 16.33/5.33 * access times in practice. Such a List implementation 16.33/5.33 * should generally implement this interface. As a rule of thumb, a 16.33/5.33 * List implementation should implement this interface if, 16.33/5.33 * for typical instances of the class, this loop: 16.33/5.33 *

16.33/5.33	 *     for (int i=0, n=list.size(); i < n; i++)
16.33/5.33	 *         list.get(i);
16.33/5.33	 * 
16.33/5.33 * runs faster than this loop: 16.33/5.33 *
16.33/5.33	 *     for (Iterator i=list.iterator(); i.hasNext(); )
16.33/5.33	 *         i.next();
16.33/5.33	 * 
16.33/5.33 * 16.33/5.33 *

This interface is a member of the 16.33/5.33 * 16.33/5.33 * Java Collections Framework. 16.33/5.33 * 16.33/5.33 * @since 1.4 16.33/5.33 */ 16.33/5.33 public interface RandomAccess { 16.33/5.33 } 16.33/5.33 16.33/5.33 16.33/5.33 package javaUtilEx; 16.33/5.33 16.33/5.33 public class Random { 16.33/5.33 static String[] args; 16.33/5.33 static int index = 0; 16.33/5.33 16.33/5.33 public static int random() { 16.33/5.33 String string = args[index]; 16.33/5.33 index++; 16.33/5.33 return string.length(); 16.33/5.33 } 16.33/5.33 } 16.33/5.33 16.33/5.33 16.33/5.33 /* 16.33/5.33 * Copyright 1997-2006 Sun Microsystems, Inc. All Rights Reserved. 16.33/5.33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 16.33/5.33 * 16.33/5.33 * This code is free software; you can redistribute it and/or modify it 16.33/5.33 * under the terms of the GNU General Public License version 2 only, as 16.33/5.33 * published by the Free Software Foundation. Sun designates this 16.33/5.33 * particular file as subject to the "Classpath" exception as provided 16.33/5.33 * by Sun in the LICENSE file that accompanied this code. 16.33/5.33 * 16.33/5.33 * This code is distributed in the hope that it will be useful, but WITHOUT 16.33/5.33 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 16.33/5.33 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 16.33/5.33 * version 2 for more details (a copy is included in the LICENSE file that 16.33/5.33 * accompanied this code). 16.33/5.33 * 16.33/5.33 * You should have received a copy of the GNU General Public License version 16.33/5.33 * 2 along with this work; if not, write to the Free Software Foundation, 16.33/5.33 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 16.33/5.33 * 16.33/5.33 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 16.33/5.33 * CA 95054 USA or visit www.sun.com if you need additional information or 16.33/5.33 * have any questions. 16.33/5.33 */ 16.33/5.33 16.33/5.33 package javaUtilEx; 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Thrown to indicate that the requested operation is not supported.

16.33/5.33 * 16.33/5.33 * This class is a member of the 16.33/5.33 * 16.33/5.33 * Java Collections Framework. 16.33/5.33 * 16.33/5.33 * @author Josh Bloch 16.33/5.33 * @since 1.2 16.33/5.33 */ 16.33/5.33 public class UnsupportedOperationException extends RuntimeException { 16.33/5.33 /** 16.33/5.33 * Constructs an UnsupportedOperationException with no detail message. 16.33/5.33 */ 16.33/5.33 public UnsupportedOperationException() { 16.33/5.33 } 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Constructs an UnsupportedOperationException with the specified 16.33/5.33 * detail message. 16.33/5.33 * 16.33/5.33 * @param message the detail message 16.33/5.33 */ 16.33/5.33 public UnsupportedOperationException(String message) { 16.33/5.33 super(message); 16.33/5.33 } 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Constructs a new exception with the specified detail message and 16.33/5.33 * cause. 16.33/5.33 * 16.33/5.33 *

Note that the detail message associated with cause is 16.33/5.33 * not automatically incorporated in this exception's detail 16.33/5.33 * message. 16.33/5.33 * 16.33/5.33 * @param message the detail message (which is saved for later retrieval 16.33/5.33 * by the {@link Throwable#getMessage()} method). 16.33/5.33 * @param cause the cause (which is saved for later retrieval by the 16.33/5.33 * {@link Throwable#getCause()} method). (A null value 16.33/5.33 * is permitted, and indicates that the cause is nonexistent or 16.33/5.33 * unknown.) 16.33/5.33 * @since 1.5 16.33/5.33 */ 16.33/5.33 public UnsupportedOperationException(String message, Throwable cause) { 16.33/5.33 super(message, cause); 16.33/5.33 } 16.33/5.33 16.33/5.33 /** 16.33/5.33 * Constructs a new exception with the specified cause and a detail 16.33/5.33 * message of (cause==null ? null : cause.toString()) (which 16.33/5.33 * typically contains the class and detail message of cause). 16.33/5.33 * This constructor is useful for exceptions that are little more than 16.33/5.33 * wrappers for other throwables (for example, {@link 16.33/5.33 * java.security.PrivilegedActionException}). 16.33/5.33 * 16.33/5.33 * @param cause the cause (which is saved for later retrieval by the 16.33/5.33 * {@link Throwable#getCause()} method). (A null value is 16.33/5.33 * permitted, and indicates that the cause is nonexistent or 16.33/5.33 * unknown.) 16.33/5.33 * @since 1.5 16.33/5.33 */ 16.33/5.33 public UnsupportedOperationException(Throwable cause) { 16.33/5.33 super(cause); 16.33/5.33 } 16.33/5.33 16.33/5.33 static final long serialVersionUID = -1242599979055084673L; 16.33/5.33 } 16.33/5.33 16.33/5.33 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (3) JBCToGraph (EQUIVALENT) 16.33/5.33 Constructed TerminationGraph. 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (4) 16.33/5.33 Obligation: 16.33/5.33 Termination Graph based on JBC Program: 16.33/5.33 javaUtilEx.juLinkedListCreateAddLast.main([Ljava/lang/String;)V: Graph of 358 nodes with 0 SCCs. 16.33/5.33 16.33/5.33 16.33/5.33 16.33/5.33 javaUtilEx.juLinkedListCreateAddLast.createList(I)LjavaUtilEx/LinkedList;: Graph of 250 nodes with 1 SCC. 16.33/5.33 16.33/5.33 16.33/5.33 16.33/5.33 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (5) TerminationGraphToSCCProof (SOUND) 16.33/5.33 Splitted TerminationGraph to 1 SCCs. 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (6) 16.33/5.33 Obligation: 16.33/5.33 SCC of termination graph based on JBC Program. 16.33/5.33 SCC contains nodes from the following methods: javaUtilEx.juLinkedListCreateAddLast.createList(I)LjavaUtilEx/LinkedList; 16.33/5.33 SCC calls the following helper methods: 16.33/5.33 Performed SCC analyses: 16.33/5.33 *Used field analysis yielded the following read fields: 16.33/5.33 *java.lang.String: [count] 16.33/5.33 *javaUtilEx.LinkedList: [header, size] 16.33/5.33 *javaUtilEx.LinkedList$Entry: [previous, next] 16.33/5.33 *javaUtilEx.AbstractList: [modCount] 16.33/5.33 *Marker field analysis yielded the following relations that could be markers: 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (7) SCCToIRSProof (SOUND) 16.33/5.33 Transformed FIGraph SCCs to intTRSs. Log: 16.33/5.33 Generated rules. Obtained 118 IRulesP rules: 16.33/5.33 f5217_0_createList_LE(EOS(STATIC_5217(java.lang.Object(o6893sub), i1220)), i1238, i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5221_0_createList_LE(EOS(STATIC_5221(java.lang.Object(o6893sub), i1220)), i1238, i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5221_0_createList_LE(EOS(STATIC_5221(java.lang.Object(o6893sub), i1220)), i1238, i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5224_0_createList_Load(EOS(STATIC_5224(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: i1238 > 0 16.33/5.33 f5224_0_createList_Load(EOS(STATIC_5224(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5227_0_createList_New(EOS(STATIC_5227(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5227_0_createList_New(EOS(STATIC_5227(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5230_0_createList_Duplicate(EOS(STATIC_5230(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5230_0_createList_Duplicate(EOS(STATIC_5230(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5231_0_createList_InvokeMethod(EOS(STATIC_5231(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5231_0_createList_InvokeMethod(EOS(STATIC_5231(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5233_0_random_FieldAccess(EOS(STATIC_5233(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5233_0_random_FieldAccess(EOS(STATIC_5233(java.lang.Object(o6893sub), i1220)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5234_0_random_FieldAccess(EOS(STATIC_5234(java.lang.Object(o6893sub), i1220)), i1238, java.lang.Object(o6893sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5234_0_random_FieldAccess(EOS(STATIC_5234(java.lang.Object(o6893sub), i1220)), i1238, java.lang.Object(o6893sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5235_0_random_ArrayAccess(EOS(STATIC_5235(java.lang.Object(o6893sub), i1220)), i1238, java.lang.Object(o6893sub), i1220, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5235_0_random_ArrayAccess(EOS(STATIC_5235(java.lang.Object(ARRAY(i1249)), i1220)), i1238, java.lang.Object(ARRAY(i1249)), i1220, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5236_0_random_ArrayAccess(EOS(STATIC_5236(java.lang.Object(ARRAY(i1249)), i1220)), i1238, java.lang.Object(ARRAY(i1249)), i1220, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: i1249 >= 0 16.33/5.33 f5236_0_random_ArrayAccess(EOS(STATIC_5236(java.lang.Object(ARRAY(i1249)), i1251)), i1238, java.lang.Object(ARRAY(i1249)), i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5238_0_random_ArrayAccess(EOS(STATIC_5238(java.lang.Object(ARRAY(i1249)), i1251)), i1238, java.lang.Object(ARRAY(i1249)), i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5238_0_random_ArrayAccess(EOS(STATIC_5238(java.lang.Object(ARRAY(i1249)), i1251)), i1238, java.lang.Object(ARRAY(i1249)), i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5240_0_random_ArrayAccess(EOS(STATIC_5240(java.lang.Object(ARRAY(i1249)), i1251)), i1238, java.lang.Object(ARRAY(i1249)), i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5240_0_random_ArrayAccess(EOS(STATIC_5240(java.lang.Object(ARRAY(i1249)), i1251)), i1238, java.lang.Object(ARRAY(i1249)), i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5242_0_random_Store(EOS(STATIC_5242(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: i1251 < i1249 16.33/5.33 f5242_0_random_Store(EOS(STATIC_5242(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5245_0_random_FieldAccess(EOS(STATIC_5245(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5245_0_random_FieldAccess(EOS(STATIC_5245(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5247_0_random_ConstantStackPush(EOS(STATIC_5247(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5247_0_random_ConstantStackPush(EOS(STATIC_5247(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, i1251, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5249_0_random_IntArithmetic(EOS(STATIC_5249(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, i1251, 1, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5249_0_random_IntArithmetic(EOS(STATIC_5249(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, i1251, matching1, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5252_0_random_FieldAccess(EOS(STATIC_5252(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, i1251 + 1, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: i1251 >= 0 && matching1 = 1 16.33/5.33 f5252_0_random_FieldAccess(EOS(STATIC_5252(java.lang.Object(ARRAY(i1249)), i1251)), i1238, o6950, i1252, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5254_0_random_Load(EOS(STATIC_5254(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5254_0_random_Load(EOS(STATIC_5254(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5256_0_random_InvokeMethod(EOS(STATIC_5256(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6950, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5256_0_random_InvokeMethod(EOS(STATIC_5256(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6952sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5259_0_random_InvokeMethod(EOS(STATIC_5259(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6952sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5259_0_random_InvokeMethod(EOS(STATIC_5259(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6953sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5262_0_random_InvokeMethod(EOS(STATIC_5262(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6953sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5262_0_random_InvokeMethod(EOS(STATIC_5262(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6953sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5265_0_length_Load(EOS(STATIC_5265(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6953sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5265_0_length_Load(EOS(STATIC_5265(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6953sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5270_0_length_FieldAccess(EOS(STATIC_5270(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(o6953sub), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5270_0_length_FieldAccess(EOS(STATIC_5270(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(java.lang.String(EOC, i1256)), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5273_0_length_FieldAccess(EOS(STATIC_5273(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(java.lang.String(EOC, i1256)), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5273_0_length_FieldAccess(EOS(STATIC_5273(java.lang.Object(ARRAY(i1249)), i1252)), i1238, java.lang.Object(java.lang.String(EOC, i1256)), o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5276_0_length_Return(EOS(STATIC_5276(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5276_0_length_Return(EOS(STATIC_5276(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5279_0_random_Return(EOS(STATIC_5279(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5279_0_random_Return(EOS(STATIC_5279(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5283_0_createList_InvokeMethod(EOS(STATIC_5283(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5283_0_createList_InvokeMethod(EOS(STATIC_5283(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5286_0__init__Load(EOS(STATIC_5286(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5286_0__init__Load(EOS(STATIC_5286(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5293_0__init__InvokeMethod(EOS(STATIC_5293(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5293_0__init__InvokeMethod(EOS(STATIC_5293(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5296_0__init__Load(EOS(STATIC_5296(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5296_0__init__Load(EOS(STATIC_5296(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5300_0__init__Load(EOS(STATIC_5300(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5300_0__init__Load(EOS(STATIC_5300(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5304_0__init__FieldAccess(EOS(STATIC_5304(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5304_0__init__FieldAccess(EOS(STATIC_5304(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5308_0__init__Return(EOS(STATIC_5308(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5308_0__init__Return(EOS(STATIC_5308(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5312_0_createList_InvokeMethod(EOS(STATIC_5312(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5312_0_createList_InvokeMethod(EOS(STATIC_5312(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5316_0_addLast_Load(EOS(STATIC_5316(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5316_0_addLast_Load(EOS(STATIC_5316(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5323_0_addLast_Load(EOS(STATIC_5323(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5323_0_addLast_Load(EOS(STATIC_5323(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5327_0_addLast_Load(EOS(STATIC_5327(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5327_0_addLast_Load(EOS(STATIC_5327(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5330_0_addLast_FieldAccess(EOS(STATIC_5330(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5330_0_addLast_FieldAccess(EOS(STATIC_5330(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5334_0_addLast_InvokeMethod(EOS(STATIC_5334(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5334_0_addLast_InvokeMethod(EOS(STATIC_5334(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5336_0_addBefore_New(EOS(STATIC_5336(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5336_0_addBefore_New(EOS(STATIC_5336(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5340_0_addBefore_Duplicate(EOS(STATIC_5340(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5340_0_addBefore_Duplicate(EOS(STATIC_5340(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5342_0_addBefore_Load(EOS(STATIC_5342(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5342_0_addBefore_Load(EOS(STATIC_5342(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5343_0_addBefore_Load(EOS(STATIC_5343(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5343_0_addBefore_Load(EOS(STATIC_5343(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5345_0_addBefore_Load(EOS(STATIC_5345(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5345_0_addBefore_Load(EOS(STATIC_5345(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5346_0_addBefore_FieldAccess(EOS(STATIC_5346(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5346_0_addBefore_FieldAccess(EOS(STATIC_5346(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5347_0_addBefore_FieldAccess(EOS(STATIC_5347(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: o6898[LinkedList$Entry.next]o6898 > 0 && o6898[LinkedList$Entry.next]o6896 > 0 && o6898[LinkedList$Entry.previous]o6896 > 0 && o6898[LinkedList$Entry.previous]o6898 > 0 16.33/5.33 f5347_0_addBefore_FieldAccess(EOS(STATIC_5347(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5349_0_addBefore_FieldAccess(EOS(STATIC_5349(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: o6897[LinkedList$Entry.previous]o6897 > 0 && o6897[LinkedList$Entry.previous]o6896 > 0 16.33/5.33 f5349_0_addBefore_FieldAccess(EOS(STATIC_5349(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5351_0_addBefore_FieldAccess(EOS(STATIC_5351(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: o6899[LinkedList$Entry.previous]o6896 > 0 && o6899[LinkedList$Entry.previous]o6899 > 0 16.33/5.33 f5351_0_addBefore_FieldAccess(EOS(STATIC_5351(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5353_0_addBefore_InvokeMethod(EOS(STATIC_5353(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5353_0_addBefore_InvokeMethod(EOS(STATIC_5353(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5354_0__init__Load(EOS(STATIC_5354(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5354_0__init__Load(EOS(STATIC_5354(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5355_0__init__InvokeMethod(EOS(STATIC_5355(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5355_0__init__InvokeMethod(EOS(STATIC_5355(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5356_0__init__Load(EOS(STATIC_5356(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5356_0__init__Load(EOS(STATIC_5356(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5357_0__init__Load(EOS(STATIC_5357(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5357_0__init__Load(EOS(STATIC_5357(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5358_0__init__FieldAccess(EOS(STATIC_5358(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5358_0__init__FieldAccess(EOS(STATIC_5358(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5359_0__init__Load(EOS(STATIC_5359(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5359_0__init__Load(EOS(STATIC_5359(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5360_0__init__Load(EOS(STATIC_5360(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5360_0__init__Load(EOS(STATIC_5360(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5361_0__init__FieldAccess(EOS(STATIC_5361(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5361_0__init__FieldAccess(EOS(STATIC_5361(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5362_0__init__Load(EOS(STATIC_5362(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5362_0__init__Load(EOS(STATIC_5362(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5363_0__init__Load(EOS(STATIC_5363(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5363_0__init__Load(EOS(STATIC_5363(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5364_0__init__FieldAccess(EOS(STATIC_5364(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5364_0__init__FieldAccess(EOS(STATIC_5364(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5365_0__init__Return(EOS(STATIC_5365(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5365_0__init__Return(EOS(STATIC_5365(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5366_0_addBefore_Store(EOS(STATIC_5366(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5366_0_addBefore_Store(EOS(STATIC_5366(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5367_0_addBefore_Load(EOS(STATIC_5367(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5367_0_addBefore_Load(EOS(STATIC_5367(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5368_0_addBefore_FieldAccess(EOS(STATIC_5368(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5368_0_addBefore_FieldAccess(EOS(STATIC_5368(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5369_0_addBefore_Load(EOS(STATIC_5369(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5369_0_addBefore_Load(EOS(STATIC_5369(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5370_0_addBefore_FieldAccess(EOS(STATIC_5370(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5370_0_addBefore_FieldAccess(EOS(STATIC_5370(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5371_0_addBefore_FieldAccess(EOS(STATIC_5371(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: o6898[LinkedList$Entry.next]o6898 > 0 && o6899[LinkedList$Entry.previous]o6898 > 0 && o6898[LinkedList$Entry.previous]o6898 > 0 && o6898[LinkedList$Entry.next]o6899 > 0 && o6898[LinkedList$Entry.previous]o6899 > 0 && o6899[LinkedList$Entry.previous]o6899 > 0 16.33/5.33 f5370_0_addBefore_FieldAccess(EOS(STATIC_5370(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.next]o6897, o6999[LinkedList$Entry.previous]o6897, o6999[LinkedList$Entry.previous]o6897, o6999[LinkedList$Entry.next]o6999, o6999[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.next]o6999, o6999[LinkedList$Entry.previous]o6999, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5372_0_addBefore_FieldAccess(EOS(STATIC_5372(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5371_0_addBefore_FieldAccess(EOS(STATIC_5371(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5373_0_addBefore_FieldAccess(EOS(STATIC_5373(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: o6899[LinkedList$Entry.previous]o6897 > 0 && o6897[LinkedList$Entry.previous]o6897 > 0 && o6897[LinkedList$Entry.previous]o6899 > 0 && o6899[LinkedList$Entry.previous]o6899 > 0 16.33/5.33 f5373_0_addBefore_FieldAccess(EOS(STATIC_5373(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5377_0_addBefore_Load(EOS(STATIC_5377(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5377_0_addBefore_Load(EOS(STATIC_5377(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5379_0_addBefore_FieldAccess(EOS(STATIC_5379(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5379_0_addBefore_FieldAccess(EOS(STATIC_5379(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5381_0_addBefore_Load(EOS(STATIC_5381(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5381_0_addBefore_Load(EOS(STATIC_5381(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5383_0_addBefore_FieldAccess(EOS(STATIC_5383(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5383_0_addBefore_FieldAccess(EOS(STATIC_5383(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5385_0_addBefore_Load(EOS(STATIC_5385(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5385_0_addBefore_Load(EOS(STATIC_5385(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5387_0_addBefore_Duplicate(EOS(STATIC_5387(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5387_0_addBefore_Duplicate(EOS(STATIC_5387(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5389_0_addBefore_FieldAccess(EOS(STATIC_5389(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5389_0_addBefore_FieldAccess(EOS(STATIC_5389(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5391_0_addBefore_ConstantStackPush(EOS(STATIC_5391(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5391_0_addBefore_ConstantStackPush(EOS(STATIC_5391(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5393_0_addBefore_IntArithmetic(EOS(STATIC_5393(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5393_0_addBefore_IntArithmetic(EOS(STATIC_5393(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5395_0_addBefore_FieldAccess(EOS(STATIC_5395(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5395_0_addBefore_FieldAccess(EOS(STATIC_5395(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5397_0_addBefore_Load(EOS(STATIC_5397(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5397_0_addBefore_Load(EOS(STATIC_5397(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5399_0_addBefore_Duplicate(EOS(STATIC_5399(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5399_0_addBefore_Duplicate(EOS(STATIC_5399(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5401_0_addBefore_FieldAccess(EOS(STATIC_5401(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5401_0_addBefore_FieldAccess(EOS(STATIC_5401(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5403_0_addBefore_ConstantStackPush(EOS(STATIC_5403(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5403_0_addBefore_ConstantStackPush(EOS(STATIC_5403(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5405_0_addBefore_IntArithmetic(EOS(STATIC_5405(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5405_0_addBefore_IntArithmetic(EOS(STATIC_5405(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5407_0_addBefore_FieldAccess(EOS(STATIC_5407(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5407_0_addBefore_FieldAccess(EOS(STATIC_5407(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5409_0_addBefore_Load(EOS(STATIC_5409(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5409_0_addBefore_Load(EOS(STATIC_5409(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5411_0_addBefore_Return(EOS(STATIC_5411(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5411_0_addBefore_Return(EOS(STATIC_5411(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5413_0_addLast_StackPop(EOS(STATIC_5413(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5413_0_addLast_StackPop(EOS(STATIC_5413(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5415_0_addLast_Return(EOS(STATIC_5415(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5415_0_addLast_Return(EOS(STATIC_5415(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5417_0_createList_Inc(EOS(STATIC_5417(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5417_0_createList_Inc(EOS(STATIC_5417(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5419_0_createList_JMP(EOS(STATIC_5419(java.lang.Object(ARRAY(i1249)), i1252)), i1238 + -1, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5419_0_createList_JMP(EOS(STATIC_5419(java.lang.Object(ARRAY(i1249)), i1252)), i1307, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5421_0_createList_Load(EOS(STATIC_5421(java.lang.Object(ARRAY(i1249)), i1252)), i1307, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5421_0_createList_Load(EOS(STATIC_5421(java.lang.Object(ARRAY(i1249)), i1252)), i1307, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899, o6898[LinkedList$Entry.previous]o6899) -> f5214_0_createList_Load(EOS(STATIC_5214(java.lang.Object(ARRAY(i1249)), i1252)), i1307, o6898[LinkedList$Entry.next]o6897, o6977[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6977[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6977[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6977, o6898[LinkedList$Entry.previous]o6977, o6897[LinkedList$Entry.previous]o6977, o6977[LinkedList$Entry.previous]o6977) :|: TRUE 16.33/5.33 f5214_0_createList_Load(EOS(STATIC_5214(java.lang.Object(o6893sub), i1220)), i1222, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) -> f5217_0_createList_LE(EOS(STATIC_5217(java.lang.Object(o6893sub), i1220)), i1222, i1222, o6898[LinkedList$Entry.next]o6897, o6899[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.previous]o6897, o6898[LinkedList$Entry.next]o6898, o6898[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6899[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6898, o6899[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.previous]o6896, o6898[LinkedList$Entry.previous]o6898, o6898[LinkedList$Entry.next]o6899, o6898[LinkedList$Entry.previous]o6899, o6897[LinkedList$Entry.previous]o6899, o6899[LinkedList$Entry.previous]o6899) :|: TRUE 16.33/5.33 f5372_0_addBefore_FieldAccess(EOS(STATIC_5372(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5375_0_addBefore_FieldAccess(EOS(STATIC_5375(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: o6999[LinkedList$Entry.previous]o6897 > 0 && o6897[LinkedList$Entry.previous]o6897 > 0 && o6897[LinkedList$Entry.previous]o6999 > 0 && o6999[LinkedList$Entry.previous]o6999 > 0 16.33/5.33 f5375_0_addBefore_FieldAccess(EOS(STATIC_5375(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5378_0_addBefore_Load(EOS(STATIC_5378(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5378_0_addBefore_Load(EOS(STATIC_5378(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5380_0_addBefore_FieldAccess(EOS(STATIC_5380(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5380_0_addBefore_FieldAccess(EOS(STATIC_5380(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5382_0_addBefore_Load(EOS(STATIC_5382(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5382_0_addBefore_Load(EOS(STATIC_5382(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5384_0_addBefore_FieldAccess(EOS(STATIC_5384(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5384_0_addBefore_FieldAccess(EOS(STATIC_5384(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5386_0_addBefore_Load(EOS(STATIC_5386(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5386_0_addBefore_Load(EOS(STATIC_5386(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5388_0_addBefore_Duplicate(EOS(STATIC_5388(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5388_0_addBefore_Duplicate(EOS(STATIC_5388(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5390_0_addBefore_FieldAccess(EOS(STATIC_5390(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5390_0_addBefore_FieldAccess(EOS(STATIC_5390(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5392_0_addBefore_ConstantStackPush(EOS(STATIC_5392(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5392_0_addBefore_ConstantStackPush(EOS(STATIC_5392(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5394_0_addBefore_IntArithmetic(EOS(STATIC_5394(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5394_0_addBefore_IntArithmetic(EOS(STATIC_5394(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5396_0_addBefore_FieldAccess(EOS(STATIC_5396(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5396_0_addBefore_FieldAccess(EOS(STATIC_5396(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5398_0_addBefore_Load(EOS(STATIC_5398(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5398_0_addBefore_Load(EOS(STATIC_5398(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5400_0_addBefore_Duplicate(EOS(STATIC_5400(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5400_0_addBefore_Duplicate(EOS(STATIC_5400(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5402_0_addBefore_FieldAccess(EOS(STATIC_5402(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5402_0_addBefore_FieldAccess(EOS(STATIC_5402(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5404_0_addBefore_ConstantStackPush(EOS(STATIC_5404(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5404_0_addBefore_ConstantStackPush(EOS(STATIC_5404(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5406_0_addBefore_IntArithmetic(EOS(STATIC_5406(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5406_0_addBefore_IntArithmetic(EOS(STATIC_5406(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5408_0_addBefore_FieldAccess(EOS(STATIC_5408(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5408_0_addBefore_FieldAccess(EOS(STATIC_5408(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5410_0_addBefore_Load(EOS(STATIC_5410(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5410_0_addBefore_Load(EOS(STATIC_5410(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5412_0_addBefore_Return(EOS(STATIC_5412(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5412_0_addBefore_Return(EOS(STATIC_5412(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5414_0_addLast_StackPop(EOS(STATIC_5414(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5414_0_addLast_StackPop(EOS(STATIC_5414(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5416_0_addLast_Return(EOS(STATIC_5416(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5416_0_addLast_Return(EOS(STATIC_5416(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5418_0_createList_Inc(EOS(STATIC_5418(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5418_0_createList_Inc(EOS(STATIC_5418(java.lang.Object(ARRAY(i1249)), i1252)), i1238, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5420_0_createList_JMP(EOS(STATIC_5420(java.lang.Object(ARRAY(i1249)), i1252)), i1238 + -1, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5420_0_createList_JMP(EOS(STATIC_5420(java.lang.Object(ARRAY(i1249)), i1252)), i1308, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5422_0_createList_Load(EOS(STATIC_5422(java.lang.Object(ARRAY(i1249)), i1252)), i1308, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) :|: TRUE 16.33/5.33 f5422_0_createList_Load(EOS(STATIC_5422(java.lang.Object(ARRAY(i1249)), i1252)), i1308, o6999[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6999) -> f5214_0_createList_Load(EOS(STATIC_5214(java.lang.Object(ARRAY(i1249)), i1252)), i1308, o6999[LinkedList$Entry.next]o6897, o6977[LinkedList$Entry.previous]o6897, o6999[LinkedList$Entry.previous]o6897, o6999[LinkedList$Entry.next]o6999, o6999[LinkedList$Entry.next]o6896, o6897[LinkedList$Entry.previous]o6897, o6897[LinkedList$Entry.previous]o6896, o6977[LinkedList$Entry.previous]o6896, o6897[LinkedList$Entry.previous]o6999, o6977[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.previous]o6896, o6999[LinkedList$Entry.previous]o6999, o6999[LinkedList$Entry.next]o6977, o6999[LinkedList$Entry.previous]o6977, o6897[LinkedList$Entry.previous]o6977, o6977[LinkedList$Entry.previous]o6977) :|: o6999[LinkedList$Entry.next]o6999 = 4 && o6977[LinkedList$Entry.previous]o6999 = 1 && o6999[LinkedList$Entry.next]o6977 = 1 16.33/5.33 Combined rules. Obtained 2 IRulesP rules: 16.33/5.33 f5217_0_createList_LE(EOS(STATIC_5217(java.lang.Object(ARRAY(i1249:0)), i1220:0)), i1238:0, i1238:0, o6898[LinkedList$Entry.next]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0) -> f5217_0_createList_LE(EOS(STATIC_5217(java.lang.Object(ARRAY(i1249:0)), i1220:0 + 1)), i1238:0 - 1, i1238:0 - 1, o6999[LinkedList$Entry.next]o6897:0, o6977[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, 4, o6999[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, 1, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, 1, o6999[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0) :|: i1238:0 > 0 && i1249:0 > -1 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6898:0 > 0 16.33/5.33 f5217_0_createList_LE(EOS(STATIC_5217(java.lang.Object(ARRAY(i1249:0)), i1220:0)), i1238:0, i1238:0, o6898[LinkedList$Entry.next]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.previous]o6896:0, o6898[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6899:0, o6898[LinkedList$Entry.previous]o6899:0, o6897[LinkedList$Entry.previous]o6899:0, o6899[LinkedList$Entry.previous]o6899:0) -> f5217_0_createList_LE(EOS(STATIC_5217(java.lang.Object(ARRAY(i1249:0)), i1220:0 + 1)), i1238:0 - 1, i1238:0 - 1, o6898[LinkedList$Entry.next]o6897:0, o6977[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6977[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.previous]o6896:0, o6898[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6977:0, o6898[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0) :|: i1238:0 > 0 && i1249:0 > -1 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6898[LinkedList$Entry.previous]o6896:0 > 0 && o6898[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6899[LinkedList$Entry.previous]o6899:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6898[LinkedList$Entry.next]o6899:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 && o6898[LinkedList$Entry.previous]o6899:0 > 0 && o6897[LinkedList$Entry.previous]o6899:0 > 0 16.33/5.33 Filtered duplicate arguments: 16.33/5.33 f5217_0_createList_LE(x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19) -> f5217_0_createList_LE(x1, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18, x19) 16.33/5.33 Filtered unneeded arguments: 16.33/5.33 f5217_0_createList_LE(x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18) -> f5217_0_createList_LE(x1, x2, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17, x18) 16.33/5.33 Finished conversion. Obtained 2 rules.P rules: 16.33/5.33 f5217_0_createList_LE(i1238:0, o6899[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, i1249:0, i1220:0) -> f5217_0_createList_LE(i1238:0 - 1, o6977[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, 4, o6999[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, 1, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, 1, o6999[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0, i1249:0, i1220:0 + 1) :|: i1249:0 > -1 && i1238:0 > 0 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 16.33/5.33 f5217_0_createList_LE(i1238:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.previous]o6896:0, o6898[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6899:0, o6898[LinkedList$Entry.previous]o6899:0, o6897[LinkedList$Entry.previous]o6899:0, o6899[LinkedList$Entry.previous]o6899:0, i1249:0, i1220:0) -> f5217_0_createList_LE(i1238:0 - 1, o6977[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6977[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.previous]o6896:0, o6898[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6977:0, o6898[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0, i1249:0, i1220:0 + 1) :|: i1249:0 > -1 && i1238:0 > 0 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6898[LinkedList$Entry.previous]o6896:0 > 0 && o6898[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6899[LinkedList$Entry.previous]o6899:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6898[LinkedList$Entry.next]o6899:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6899:0 > 0 && o6898[LinkedList$Entry.previous]o6899:0 > 0 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (8) 16.33/5.33 Obligation: 16.33/5.33 Rules: 16.33/5.33 f5217_0_createList_LE(i1238:0, o6899[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, i1249:0, i1220:0) -> f5217_0_createList_LE(i1238:0 - 1, o6977[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, 4, o6999[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, 1, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, 1, o6999[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0, i1249:0, i1220:0 + 1) :|: i1249:0 > -1 && i1238:0 > 0 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 16.33/5.33 f5217_0_createList_LE(x, x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17) -> f5217_0_createList_LE(x - 1, x18, x2, x3, x4, x5, x6, x19, x8, x20, x10, x11, x21, x22, x23, x24, x16, x17 + 1) :|: x16 > -1 && x > 0 && x16 > x17 && x17 > -1 && x4 > 0 && x3 > 0 && x10 > 0 && x11 > 0 && x6 > 0 && x5 > 0 && x15 > 0 && x7 > 0 && x9 > 0 && x12 > 0 && x1 > 0 && x14 > 0 && x13 > 0 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (9) IRSFormatTransformerProof (EQUIVALENT) 16.33/5.33 Reformatted IRS to match normalized format (transformed away non-linear left-hand sides, !=, / and %). 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (10) 16.33/5.33 Obligation: 16.33/5.33 Rules: 16.33/5.33 f5217_0_createList_LE(i1238:0, o6899[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, i1249:0, i1220:0) -> f5217_0_createList_LE(arith, o6977[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, 4, o6999[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, 1, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, 1, o6999[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0, i1249:0, arith1) :|: i1249:0 > -1 && i1238:0 > 0 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 && arith = i1238:0 - 1 && arith1 = i1220:0 + 1 16.33/5.33 f5217_0_createList_LE(x25, x26, x27, x28, x29, x30, x31, x32, x33, x34, x35, x36, x37, x38, x39, x40, x41, x42) -> f5217_0_createList_LE(x43, x44, x27, x28, x29, x30, x31, x45, x33, x46, x35, x36, x47, x48, x49, x50, x41, x51) :|: x41 > -1 && x25 > 0 && x41 > x42 && x42 > -1 && x29 > 0 && x28 > 0 && x35 > 0 && x36 > 0 && x31 > 0 && x30 > 0 && x40 > 0 && x32 > 0 && x34 > 0 && x37 > 0 && x26 > 0 && x39 > 0 && x38 > 0 && x43 = x25 - 1 && x51 = x42 + 1 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (11) IRSwTTerminationDigraphProof (EQUIVALENT) 16.33/5.33 Constructed termination digraph! 16.33/5.33 Nodes: 16.33/5.33 (1) f5217_0_createList_LE(i1238:0, o6899[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, i1249:0, i1220:0) -> f5217_0_createList_LE(arith, o6977[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, 4, o6999[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, 1, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, 1, o6999[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0, i1249:0, arith1) :|: i1249:0 > -1 && i1238:0 > 0 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 && arith = i1238:0 - 1 && arith1 = i1220:0 + 1 16.33/5.33 (2) f5217_0_createList_LE(x25, x26, x27, x28, x29, x30, x31, x32, x33, x34, x35, x36, x37, x38, x39, x40, x41, x42) -> f5217_0_createList_LE(x43, x44, x27, x28, x29, x30, x31, x45, x33, x46, x35, x36, x47, x48, x49, x50, x41, x51) :|: x41 > -1 && x25 > 0 && x41 > x42 && x42 > -1 && x29 > 0 && x28 > 0 && x35 > 0 && x36 > 0 && x31 > 0 && x30 > 0 && x40 > 0 && x32 > 0 && x34 > 0 && x37 > 0 && x26 > 0 && x39 > 0 && x38 > 0 && x43 = x25 - 1 && x51 = x42 + 1 16.33/5.33 16.33/5.33 Arcs: 16.33/5.33 (1) -> (2) 16.33/5.33 (2) -> (1), (2) 16.33/5.33 16.33/5.33 This digraph is fully evaluated! 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (12) 16.33/5.33 Obligation: 16.33/5.33 16.33/5.33 Termination digraph: 16.33/5.33 Nodes: 16.33/5.33 (1) f5217_0_createList_LE(i1238:0, o6899[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, o6898[LinkedList$Entry.next]o6898:0, o6898[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, o6898[LinkedList$Entry.next]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, o6897[LinkedList$Entry.previous]o6898:0, o6899[LinkedList$Entry.previous]o6898:0, i1249:0, i1220:0) -> f5217_0_createList_LE(arith, o6977[LinkedList$Entry.previous]o6897:0, o6899[LinkedList$Entry.previous]o6897:0, 4, o6999[LinkedList$Entry.next]o6896:0, o6897[LinkedList$Entry.previous]o6897:0, o6897[LinkedList$Entry.previous]o6896:0, o6977[LinkedList$Entry.previous]o6896:0, o6897[LinkedList$Entry.previous]o6898:0, 1, o6899[LinkedList$Entry.previous]o6896:0, o6899[LinkedList$Entry.previous]o6898:0, 1, o6999[LinkedList$Entry.previous]o6977:0, o6897[LinkedList$Entry.previous]o6977:0, o6977[LinkedList$Entry.previous]o6977:0, i1249:0, arith1) :|: i1249:0 > -1 && i1238:0 > 0 && i1249:0 > i1220:0 && i1220:0 > -1 && o6898[LinkedList$Entry.next]o6896:0 > 0 && o6898[LinkedList$Entry.next]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0 > 0 && o6897[LinkedList$Entry.previous]o6898:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0 > 0 && arith = i1238:0 - 1 && arith1 = i1220:0 + 1 16.33/5.33 (2) f5217_0_createList_LE(x25, x26, x27, x28, x29, x30, x31, x32, x33, x34, x35, x36, x37, x38, x39, x40, x41, x42) -> f5217_0_createList_LE(x43, x44, x27, x28, x29, x30, x31, x45, x33, x46, x35, x36, x47, x48, x49, x50, x41, x51) :|: x41 > -1 && x25 > 0 && x41 > x42 && x42 > -1 && x29 > 0 && x28 > 0 && x35 > 0 && x36 > 0 && x31 > 0 && x30 > 0 && x40 > 0 && x32 > 0 && x34 > 0 && x37 > 0 && x26 > 0 && x39 > 0 && x38 > 0 && x43 = x25 - 1 && x51 = x42 + 1 16.33/5.33 16.33/5.33 Arcs: 16.33/5.33 (1) -> (2) 16.33/5.33 (2) -> (1), (2) 16.33/5.33 16.33/5.33 This digraph is fully evaluated! 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (13) IntTRSCompressionProof (EQUIVALENT) 16.33/5.33 Compressed rules. 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (14) 16.33/5.33 Obligation: 16.33/5.33 Rules: 16.33/5.33 f5217_0_createList_LE(x25:0, x26:0, x27:0, x28:0, x29:0, x30:0, x31:0, x32:0, x33:0, x34:0, x35:0, x36:0, x37:0, x38:0, x39:0, x40:0, x41:0, x42:0) -> f5217_0_createList_LE(x25:0 - 1, x44:0, x27:0, x28:0, x29:0, x30:0, x31:0, x45:0, x33:0, x46:0, x35:0, x36:0, x47:0, x48:0, x49:0, x50:0, x41:0, x42:0 + 1) :|: x39:0 > 0 && x38:0 > 0 && x26:0 > 0 && x37:0 > 0 && x34:0 > 0 && x32:0 > 0 && x40:0 > 0 && x30:0 > 0 && x31:0 > 0 && x36:0 > 0 && x35:0 > 0 && x28:0 > 0 && x29:0 > 0 && x42:0 > -1 && x42:0 < x41:0 && x25:0 > 0 && x41:0 > -1 16.33/5.33 f5217_0_createList_LE(i1238:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6898[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, i1249:0:0, i1220:0:0) -> f5217_0_createList_LE(i1238:0:0 - 1, o6977[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, 4, o6999[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6977[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, 1, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, 1, o6999[LinkedList$Entry.previous]o6977:0:0, o6897[LinkedList$Entry.previous]o6977:0:0, o6977[LinkedList$Entry.previous]o6977:0:0, i1249:0:0, i1220:0:0 + 1) :|: o6897[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0:0 > 0 && o6898[LinkedList$Entry.next]o6898:0:0 > 0 && o6898[LinkedList$Entry.next]o6896:0:0 > 0 && i1220:0:0 > -1 && i1249:0:0 > i1220:0:0 && i1238:0:0 > 0 && i1249:0:0 > -1 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (15) TempFilterProof (SOUND) 16.33/5.33 Used the following sort dictionary for filtering: 16.33/5.33 f5217_0_createList_LE(INTEGER, VARIABLE, VARIABLE, VARIABLE, VARIABLE, INTEGER, INTEGER, VARIABLE, VARIABLE, VARIABLE, INTEGER, INTEGER, VARIABLE, VARIABLE, VARIABLE, VARIABLE, INTEGER, INTEGER) 16.33/5.33 Replaced non-predefined constructor symbols by 0. 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (16) 16.33/5.33 Obligation: 16.33/5.33 Rules: 16.33/5.33 f5217_0_createList_LE(x25:0, x26:0, x27:0, x28:0, x29:0, x30:0, x31:0, x32:0, x33:0, x34:0, x35:0, x36:0, x37:0, x38:0, x39:0, x40:0, x41:0, x42:0) -> f5217_0_createList_LE(c, x44:0, x27:0, x28:0, x29:0, x30:0, x31:0, x45:0, x33:0, x46:0, x35:0, x36:0, x47:0, x48:0, x49:0, x50:0, x41:0, c1) :|: c1 = x42:0 + 1 && c = x25:0 - 1 && (x39:0 > 0 && x38:0 > 0 && x26:0 > 0 && x37:0 > 0 && x34:0 > 0 && x32:0 > 0 && x40:0 > 0 && x30:0 > 0 && x31:0 > 0 && x36:0 > 0 && x35:0 > 0 && x28:0 > 0 && x29:0 > 0 && x42:0 > -1 && x42:0 < x41:0 && x25:0 > 0 && x41:0 > -1) 16.33/5.33 f5217_0_createList_LE(i1238:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6898[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, i1249:0:0, i1220:0:0) -> f5217_0_createList_LE(c2, o6977[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, c3, o6999[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6977[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, c4, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, c5, o6999[LinkedList$Entry.previous]o6977:0:0, o6897[LinkedList$Entry.previous]o6977:0:0, o6977[LinkedList$Entry.previous]o6977:0:0, i1249:0:0, c6) :|: c6 = i1220:0:0 + 1 && (c5 = 1 && (c4 = 1 && (c3 = 4 && c2 = i1238:0:0 - 1))) && (o6897[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0:0 > 0 && o6898[LinkedList$Entry.next]o6898:0:0 > 0 && o6898[LinkedList$Entry.next]o6896:0:0 > 0 && i1220:0:0 > -1 && i1249:0:0 > i1220:0:0 && i1238:0:0 > 0 && i1249:0:0 > -1) 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (17) PolynomialOrderProcessor (EQUIVALENT) 16.33/5.33 Found the following polynomial interpretation: 16.33/5.33 [f5217_0_createList_LE(x, x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17)] = 3*x + x3 16.33/5.33 16.33/5.33 The following rules are decreasing: 16.33/5.33 f5217_0_createList_LE(x25:0, x26:0, x27:0, x28:0, x29:0, x30:0, x31:0, x32:0, x33:0, x34:0, x35:0, x36:0, x37:0, x38:0, x39:0, x40:0, x41:0, x42:0) -> f5217_0_createList_LE(c, x44:0, x27:0, x28:0, x29:0, x30:0, x31:0, x45:0, x33:0, x46:0, x35:0, x36:0, x47:0, x48:0, x49:0, x50:0, x41:0, c1) :|: c1 = x42:0 + 1 && c = x25:0 - 1 && (x39:0 > 0 && x38:0 > 0 && x26:0 > 0 && x37:0 > 0 && x34:0 > 0 && x32:0 > 0 && x40:0 > 0 && x30:0 > 0 && x31:0 > 0 && x36:0 > 0 && x35:0 > 0 && x28:0 > 0 && x29:0 > 0 && x42:0 > -1 && x42:0 < x41:0 && x25:0 > 0 && x41:0 > -1) 16.33/5.33 The following rules are bounded: 16.33/5.33 f5217_0_createList_LE(x25:0, x26:0, x27:0, x28:0, x29:0, x30:0, x31:0, x32:0, x33:0, x34:0, x35:0, x36:0, x37:0, x38:0, x39:0, x40:0, x41:0, x42:0) -> f5217_0_createList_LE(c, x44:0, x27:0, x28:0, x29:0, x30:0, x31:0, x45:0, x33:0, x46:0, x35:0, x36:0, x47:0, x48:0, x49:0, x50:0, x41:0, c1) :|: c1 = x42:0 + 1 && c = x25:0 - 1 && (x39:0 > 0 && x38:0 > 0 && x26:0 > 0 && x37:0 > 0 && x34:0 > 0 && x32:0 > 0 && x40:0 > 0 && x30:0 > 0 && x31:0 > 0 && x36:0 > 0 && x35:0 > 0 && x28:0 > 0 && x29:0 > 0 && x42:0 > -1 && x42:0 < x41:0 && x25:0 > 0 && x41:0 > -1) 16.33/5.33 f5217_0_createList_LE(i1238:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6898[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, i1249:0:0, i1220:0:0) -> f5217_0_createList_LE(c2, o6977[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, c3, o6999[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6977[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, c4, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, c5, o6999[LinkedList$Entry.previous]o6977:0:0, o6897[LinkedList$Entry.previous]o6977:0:0, o6977[LinkedList$Entry.previous]o6977:0:0, i1249:0:0, c6) :|: c6 = i1220:0:0 + 1 && (c5 = 1 && (c4 = 1 && (c3 = 4 && c2 = i1238:0:0 - 1))) && (o6897[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0:0 > 0 && o6898[LinkedList$Entry.next]o6898:0:0 > 0 && o6898[LinkedList$Entry.next]o6896:0:0 > 0 && i1220:0:0 > -1 && i1249:0:0 > i1220:0:0 && i1238:0:0 > 0 && i1249:0:0 > -1) 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (18) 16.33/5.33 Obligation: 16.33/5.33 Rules: 16.33/5.33 f5217_0_createList_LE(i1238:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6898[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, i1249:0:0, i1220:0:0) -> f5217_0_createList_LE(c2, o6977[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, c3, o6999[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6977[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, c4, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, c5, o6999[LinkedList$Entry.previous]o6977:0:0, o6897[LinkedList$Entry.previous]o6977:0:0, o6977[LinkedList$Entry.previous]o6977:0:0, i1249:0:0, c6) :|: c6 = i1220:0:0 + 1 && (c5 = 1 && (c4 = 1 && (c3 = 4 && c2 = i1238:0:0 - 1))) && (o6897[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0:0 > 0 && o6898[LinkedList$Entry.next]o6898:0:0 > 0 && o6898[LinkedList$Entry.next]o6896:0:0 > 0 && i1220:0:0 > -1 && i1249:0:0 > i1220:0:0 && i1238:0:0 > 0 && i1249:0:0 > -1) 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (19) PolynomialOrderProcessor (EQUIVALENT) 16.33/5.33 Found the following polynomial interpretation: 16.33/5.33 [f5217_0_createList_LE(x, x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, x12, x13, x14, x15, x16, x17)] = x12 + 2*x17 - x3 16.33/5.33 16.33/5.33 The following rules are decreasing: 16.33/5.33 f5217_0_createList_LE(i1238:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6898[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, i1249:0:0, i1220:0:0) -> f5217_0_createList_LE(c2, o6977[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, c3, o6999[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6977[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, c4, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, c5, o6999[LinkedList$Entry.previous]o6977:0:0, o6897[LinkedList$Entry.previous]o6977:0:0, o6977[LinkedList$Entry.previous]o6977:0:0, i1249:0:0, c6) :|: c6 = i1220:0:0 + 1 && (c5 = 1 && (c4 = 1 && (c3 = 4 && c2 = i1238:0:0 - 1))) && (o6897[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0:0 > 0 && o6898[LinkedList$Entry.next]o6898:0:0 > 0 && o6898[LinkedList$Entry.next]o6896:0:0 > 0 && i1220:0:0 > -1 && i1249:0:0 > i1220:0:0 && i1238:0:0 > 0 && i1249:0:0 > -1) 16.33/5.33 The following rules are bounded: 16.33/5.33 f5217_0_createList_LE(i1238:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6898[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6898[LinkedList$Entry.next]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, i1249:0:0, i1220:0:0) -> f5217_0_createList_LE(c2, o6977[LinkedList$Entry.previous]o6897:0:0, o6899[LinkedList$Entry.previous]o6897:0:0, c3, o6999[LinkedList$Entry.next]o6896:0:0, o6897[LinkedList$Entry.previous]o6897:0:0, o6897[LinkedList$Entry.previous]o6896:0:0, o6977[LinkedList$Entry.previous]o6896:0:0, o6897[LinkedList$Entry.previous]o6898:0:0, c4, o6899[LinkedList$Entry.previous]o6896:0:0, o6899[LinkedList$Entry.previous]o6898:0:0, c5, o6999[LinkedList$Entry.previous]o6977:0:0, o6897[LinkedList$Entry.previous]o6977:0:0, o6977[LinkedList$Entry.previous]o6977:0:0, i1249:0:0, c6) :|: c6 = i1220:0:0 + 1 && (c5 = 1 && (c4 = 1 && (c3 = 4 && c2 = i1238:0:0 - 1))) && (o6897[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6897:0:0 > 0 && o6897[LinkedList$Entry.previous]o6896:0:0 > 0 && o6899[LinkedList$Entry.previous]o6898:0:0 > 0 && o6899[LinkedList$Entry.previous]o6896:0:0 > 0 && o6898[LinkedList$Entry.next]o6898:0:0 > 0 && o6898[LinkedList$Entry.next]o6896:0:0 > 0 && i1220:0:0 > -1 && i1249:0:0 > i1220:0:0 && i1238:0:0 > 0 && i1249:0:0 > -1) 16.33/5.33 16.33/5.33 ---------------------------------------- 16.33/5.33 16.33/5.33 (20) 16.33/5.33 YES 16.63/5.65 EOF