@Override
	public boolean add(E o) {
		// Shortcut for empty
		int size=size();
		if(size==0) {
			super.add(o);
		} else {
			int Ohash=o.hashCode();

			// Shortcut for adding to end (makes imports of already-sorted data operate at constant-time instead of logarithmic complexity)
			if(Ohash>=get(size-1).hashCode()) {
				super.add(o);
			} else {
				int index=binarySearchHashCode(Ohash);
				if(index<0) {
					// Not found in list
					super.add(-(index+1), o);
				} else {
					// Add after the last item with matching hashCodes
					while(index<(size-1) && get(index+1).hashCode()==Ohash) index++;
					super.add(index+1, o);
				}
			}
		}

		return true;
	}
@ Override public boolean add ( E o ) { int size = size ( ) ; if ( size == 0 ) { super . add ( o ) ; } else { int Ohash = o . hashCode ( ) ; if ( Ohash >= get ( size - 1 ) . hashCode ( ) ) { super . add ( o ) ; } else { int index = binarySearchHashCode ( Ohash ) ; if ( index < 0 ) { super . add ( - ( index + 1 ) , o ) ; } else { while ( index < ( size - 1 ) && get ( index + 1 ) . hashCode ( ) == Ohash ) index ++ ; super . add ( index + 1 , o ) ; } } } return true ; }
Adds the specified element in sorted position within this list.  When
two elements have the same hashCode, the new item is added at the end
of the list of matching hashCodes.

@param o element to be appended to this list.
@return <tt>true</tt> (as per the general contract of Collection.add).