fun clone(): ArrayDeque<E>? { return try { val result: ArrayDeque<E> = super.clone() as ArrayDeque<E> result.elements = Arrays.copyOf(elements, elements.length) result } catch (e: CloneNotSupportedException) { throw AssertionError() } }
Returns a copy of this deque .