public int countMapTasks ( ) { int mapCount = 0 ; for ( Iterator < TaskStatus > it = taskReports . iterator ( ) ; it . hasNext ( ) ; ) { TaskStatus ts = ( TaskStatus ) it . next ( ) ; if ( ts . getIsMap ( ) && isTaskRunning ( ts ) ) { mapCount ++ ; } } return mapCount ; }
Get the number of running map tasks .