sclass ManagedObjectCollector { // notify collector that there is an object in a location public void noteObject(int start, int size); // notify collector that there is a pointer in a location public void notePointer(int addr); // notify collector that there is a pointer array in a location public void notePointerArray(int start); // call after collectAndCompact to get new location of objects int getNewLocation(int addr); }