public int getRegisteredResourceRequestCount ( K key ) { if ( requestQueueMap . containsKey ( key ) ) { Queue < AsyncResourceRequest < V >> requestQueue = getRequestQueueForExistingKey ( key ) ; // FYI: .size() is not constant time in the next call. ;) if ( requestQueue != null ) { return requestQueue . size ( ) ; } } return 0 ; }
Count the number of queued resource requests for a specific pool .