jeffchannell.com

BulkLoader resumeAllLoaders

Posted in ActionScript 3
2009-06-13 03:41:56 +0000 UTC

During a recent project, I had an issue with BulkLoader. I wanted to pause all of the loaders running, then resume them later. Pausing them was easy, as BulkLoader has a static method 'pauseAllLoaders'. But resuming them was another issue. I could resume individual items with resume(), or a whole instance with resumeAll(), but there was no method for resuming all instances.

I took a peek under the hood and found exactly what I was hoping to find: a static Object housing all the named BulkLoader instances! So here's a short snippet I wrote to resume all BulkLoader LoaderItems:

for( var ldr:String in BulkLoader._allLoaders )
{
	BulkLoader.getLoader( ldr ).resumeAll();
}