}
public long[] toArray(int sourceOffset, long[] dest, int destOffset, int length) {
int slices = mySlices.size();
for (int i = 0; i < slices && length > 0; i++) {
LongList list = mySlices.get(i);
int size = list.size();
if (sourceOffset >= size) {
sourceOffset -= size;
} else {
int x = Math.min(size - sourceOffset, length);
list.toArray(sourceOffset, dest, destOffset, x);
destOffset += x;
sourceOffset = 0;
length -= x;
}
}