public abstract class JobBase extends Object implements Mapper, Reducer
Modifier and Type | Field and Description |
---|---|
static org.apache.commons.logging.Log |
LOG |
Constructor and Description |
---|
JobBase() |
Modifier and Type | Method and Description |
---|---|
protected Double |
addDoubleValue(Object name,
double inc)
Increment the given counter by the given incremental value If the counter
does not exist, one is created with value 0.
|
protected Long |
addLongValue(Object name,
long inc)
Increment the given counter by the given incremental value If the counter
does not exist, one is created with value 0.
|
void |
configure(JobConf job)
Initializes a new instance from a
JobConf . |
protected Double |
getDoubleValue(Object name) |
protected Long |
getLongValue(Object name) |
protected String |
getReport()
log the counters
|
protected void |
report()
log the counters
|
protected void |
setDoubleValue(Object name,
double value)
Set the given counter to the given value
|
protected void |
setLongValue(Object name,
long value)
Set the given counter to the given value
|
protected void setLongValue(Object name, long value)
name
- the counter namevalue
- the value for the counterprotected void setDoubleValue(Object name, double value)
name
- the counter namevalue
- the value for the counterprotected Long getLongValue(Object name)
name
- the counter nameprotected Double getDoubleValue(Object name)
name
- the counter nameprotected Long addLongValue(Object name, long inc)
name
- the counter nameinc
- the incremental valueprotected Double addDoubleValue(Object name, double inc)
name
- the counter nameinc
- the incremental valueprotected void report()
protected String getReport()
public void configure(JobConf job)
JobConf
.configure
in interface JobConfigurable
job
- the configurationCopyright © 2010 The Apache Software Foundation