C - the type of the Counter for the group@InterfaceAudience.Private public abstract class FileSystemCounterGroup<C extends TezCounter> extends Object implements CounterGroupBase<C>
| Modifier and Type | Class and Description | 
|---|---|
static class  | 
FileSystemCounterGroup.FSCounter  | 
| Constructor and Description | 
|---|
FileSystemCounterGroup()  | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
addCounter(C counter)
Add a counter to this group. 
 | 
C | 
addCounter(String name,
          String displayName,
          long value)
Add a counter to this group 
 | 
boolean | 
equals(Object genericRight)  | 
C | 
findCounter(String counterName)
Find a counter in the group. 
 | 
C | 
findCounter(String counterName,
           boolean create)
Find a counter in the group 
 | 
C | 
findCounter(String scheme,
           FileSystemCounter key)  | 
C | 
findCounter(String counterName,
           String displayName)
Find a counter in the group. 
 | 
String | 
getDisplayName()
Get the display name of the group. 
 | 
String | 
getName()
Get the internal name of the group 
 | 
int | 
hashCode()  | 
void | 
incrAllCounters(CounterGroupBase<C> other)
Increment all counters by a group of counters 
 | 
Iterator<C> | 
iterator()  | 
protected abstract C | 
newCounter(String scheme,
          FileSystemCounter key)
Abstract factory method to create a file system counter 
 | 
void | 
readFields(DataInput in)  | 
void | 
setDisplayName(String displayName)
Set the display name of the group 
 | 
int | 
size()  | 
void | 
write(DataOutput out)
FileSystemGroup ::= #scheme (scheme #counter (key value)*)* 
 | 
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitgetUnderlyingGrouppublic String getName()
CounterGroupBasegetName in interface CounterGroupBase<C extends TezCounter>public String getDisplayName()
CounterGroupBasegetDisplayName in interface CounterGroupBase<C extends TezCounter>public void setDisplayName(String displayName)
CounterGroupBasesetDisplayName in interface CounterGroupBase<C extends TezCounter>displayName - of the grouppublic void addCounter(C counter)
CounterGroupBaseaddCounter in interface CounterGroupBase<C extends TezCounter>counter - to addpublic C addCounter(String name, String displayName, long value)
CounterGroupBaseaddCounter in interface CounterGroupBase<C extends TezCounter>name - of the counterdisplayName - of the countervalue - of the counterpublic C findCounter(String counterName, String displayName)
CounterGroupBasefindCounter in interface CounterGroupBase<C extends TezCounter>counterName - the name of the counterdisplayName - the display name of the counterpublic C findCounter(String counterName, boolean create)
CounterGroupBasefindCounter in interface CounterGroupBase<C extends TezCounter>counterName - the name of the countercreate - create the counter if not found if truepublic C findCounter(String counterName)
CounterGroupBasefindCounter in interface CounterGroupBase<C extends TezCounter>counterName - the name of the counterpublic C findCounter(String scheme, FileSystemCounter key)
protected abstract C newCounter(String scheme, FileSystemCounter key)
scheme - of the file systemkey - the enum of the file system counterpublic int size()
size in interface CounterGroupBase<C extends TezCounter>public void incrAllCounters(CounterGroupBase<C> other)
CounterGroupBaseincrAllCounters in interface CounterGroupBase<C extends TezCounter>other - the group to be added to this grouppublic void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.WritableIOExceptionpublic void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.WritableIOExceptionpublic Iterator<C> iterator()
iterator in interface Iterable<C extends TezCounter>Copyright © 2016 Apache Software Foundation. All rights reserved.