public void runCycle ( int ... valuesForMap ) { /// prepare the map Object array recycler for a new cycle. HeapFriendlyMapArrayRecycler . get ( ) . swapCycleObjectArrays ( ) ; try { makeDataAvailableToApplication ( valuesForMap ) ; } finally { // fill all of the Object arrays which were returned to the pool on this cycle with nulls, // so that the garbage collector can clean up any data which is no longer used. HeapFriendlyMapArrayRecycler . get ( ) . clearNextCycleObjectArrays ( ) ; } }
For each cycle we need to perform some administrative tasks .