Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.hadoop.metrics2.impl
Class MetricsRecordImpl

    java.lang.Object
      org.apache.hadoop.metrics2.impl.MetricsRecordImpl

All Implemented Interfaces:
  MetricsRecord

    public class MetricsRecordImpl

extends Object
implements MetricsRecord

Field Summary
`protected static String` | `CONTEXT_KEY`
`protected static String` | `DEFAULT_CONTEXT`

Constructor Summary
`MetricsRecordImpl(String name, long timestamp, Iterable<MetricsTag> tags, Iterable<Metric> metrics)` Construct a metrics record

Method Summary
`String` | `context()` Get the context name of the metrics
`boolean` | `equals(Object obj)`
`int` | `hashCode()`
`Iterable<Metric>` | `metrics()` Get the metrics of the record
`String` | `name()` Get the record name of the metrics
`Iterable<MetricsTag>` | `tags()` Get the tags of the record
`long` | `timestamp()` Get the timestamp of the metrics
`String` | `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### CONTEXT_KEY

    protected static final String CONTEXT_KEY

See Also:
  Constant Field Values

### DEFAULT_CONTEXT

    protected static final String DEFAULT_CONTEXT

See Also:
  Constant Field Values

Constructor Detail

### MetricsRecordImpl

    public MetricsRecordImpl(String name,
                             long timestamp,
                             Iterable<MetricsTag> tags,
                             Iterable<Metric> metrics)

  Construct a metrics record

  Parameters:
    `name` - of the record
    `timestamp` - of the record
    `tags` - of the record
    `metrics` - of the record

Method Detail

### timestamp

    public long timestamp()

  Description copied from interface: `MetricsRecord`
  Get the timestamp of the metrics

  Specified by:
    `timestamp` in interface `MetricsRecord`
  Returns:
    the timestamp

### name

    public String name()

  Description copied from interface: `MetricsRecord`
  Get the record name of the metrics

  Specified by:
    `name` in interface `MetricsRecord`
  Returns:
    the record name

### context

    public String context()

  Description copied from interface: `MetricsRecord`
  Get the context name of the metrics

  Specified by:
    `context` in interface `MetricsRecord`
  Returns:
    the context name

### tags

    public Iterable<MetricsTag> tags()

  Description copied from interface: `MetricsRecord`
  Get the tags of the record

  Specified by:
    `tags` in interface `MetricsRecord`
  Returns:
    the tags

### metrics

    public Iterable<Metric> metrics()

  Description copied from interface: `MetricsRecord`
  Get the metrics of the record

  Specified by:
    `metrics` in interface `MetricsRecord`
  Returns:
    the metrics

### equals

    public boolean equals(Object obj)

  Overrides:
    `equals` in class `Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `Object`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 The Apache Software Foundation