public void done ( ) { engine . execute ( ) ; while ( deferred != null ) { final List < Runnable > runme = deferred ; deferred = null ; // reset this because it might get filled with more for ( final Runnable run : runme ) { log . trace ( "Executing {}" , run ) ; run . run ( ) ; } } }
Call this when a load process completes . Executes anything in the batch and then executes any delayed operations .