コード例 #1
0
ファイル: LocalJobRunner.cs プロジェクト: orf53975/hadoop.net
 /// <summary>
 /// Return the current values of the counters for this job,
 /// including tasks that are in progress.
 /// </summary>
 public virtual Counters GetCurrentCounters()
 {
     lock (this)
     {
         if (null == this.mapCounters)
         {
             // Counters not yet initialized for job.
             return(new Counters());
         }
         Counters current = new Counters();
         foreach (Counters c in this.mapCounters)
         {
             current = Counters.Sum(current, c);
         }
         if (null != this.reduceCounters && this.reduceCounters.Length > 0)
         {
             foreach (Counters c_1 in this.reduceCounters)
             {
                 current = Counters.Sum(current, c_1);
             }
         }
         return(current);
     }
 }