public void setAll(int index, Collection<? extends E> coll) {
    	int collSize = coll.size();
        checkRange(index, collSize);

    	if (coll instanceof List) {
    		doReplaceAll(index, collSize, new IReadOnlyListFromList<E>((List<? extends E>) coll));
    	} else {
    		doReplaceAll(index, collSize, new IReadOnlyListFromCollection<E>(coll));
    	}
    }
Sets the specified elements.

@param index index of first element to set
@param coll  collection with elements to set
jphp-runtime/src/php/runtime/memory/support/IList.java