public int getCount ( final int state ) { int count = 0 ; for ( IConcurrentBagEntry e : sharedList ) { if ( e . getState ( ) == state ) { count ++ ; } } return count ; }
Get a count of the number of items in the specified state at the time of this call .