public synchronized E remove(int index) {@SuppressWarnings("unchecked")E removed = (E) elements[index];removeRange(index, index + 1);return removed;}
public virtual E remove(int index){lock (this){E removed = (E)elements[index];removeRange(index, index + 1);return removed;}}