public boolean canRun ( final ResourceList resources ) { try { return _withLock ( new Callable < Boolean > ( ) { @ Override public Boolean call ( ) { return ! inUse . isCollidingWith ( resources ) ; } } ) ; } catch ( Exception e ) { throw new IllegalStateException ( "Inner callable does not throw exception" ) ; } }
Checks if an activity that requires the given resource list can run immediately .