void bulkEnqueueFirst(@NotNull ObjectArrayList<? extends @NotNull T> elements) {
    int insertSize = elements.size();
    int oldCapacity = myQueue.length;
    int emptySpace = oldCapacity - size() - 1;
    if (insertSize > emptySpace) {
      growAndUnwrap(insertSize);
    }
    int firstChunkSize = head <= tail ? Math.min(insertSize, head) : Math.min(insertSize, head - tail - 1);
    elements.getElements(0, myQueue, head - firstChunkSize, firstChunkSize);
    head -= firstChunkSize;
    if (firstChunkSize != insertSize) {
      int secondChunkSize = insertSize - firstChunkSize;
      // wraparound
      elements.getElements(firstChunkSize, myQueue, oldCapacity - secondChunkSize, secondChunkSize);
      head = oldCapacity - secondChunkSize;
    }
  }
void bulkEnqueueFirst(@NotNull ObjectArrayList<? extends @NotNull T> elements)