Open in-memory dex files into a single DexFile object

Refactor the logic of opening dex from ByteBuffers so that all buffers
are opened at once into the same DexFile/Element object. This effectively
enables multidex in InMemoryDexClassLoader and will make it possible to
generate a single vdex file for the whole class loader instead of one
vdex per dex ByteBuffer.

Bug: 72131483
Test: art/tools/run-libcore-tests.sh
Change-Id: I5fb939072812745a2df0f323c502a1cf92069ed5
1 file changed