Interns (Apache Hadoop Common 3.5.0 API)
Description: declaration: package: org.apache.hadoop.metrics2.lib, class: Interns

Package org.apache.hadoop.metrics2.lib

# Class Interns

java.lang.Object
org.apache.hadoop.metrics2.lib.Interns

@Public @Evolving public class Interns extends Object
Helpers to create interned metrics info.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `Interns()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static MetricsInfo`
  `info(String name, String description)`
  Get a metric info object.
  `static MetricsTag`
  `tag(String name, String description, String value)`
  Get a metrics tag.
  `static MetricsTag`
  `tag(MetricsInfo info, String value)`
  Get a metrics tag.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### Interns

    public Interns()

- ## Method Details

  - ### info

    public static MetricsInfo info(String name, String description)
    Get a metric info object.
    Parameters:
      `name` - Name of metric info object
      `description` - Description of metric info object
    Returns:
      an interned metric info object

  - ### tag

    public static MetricsTag tag(MetricsInfo info, String value)
    Get a metrics tag.
    Parameters:
      `info` - of the tag
      `value` - of the tag
    Returns:
      an interned metrics tag

  - ### tag

    public static MetricsTag tag(String name, String description, String value)
    Get a metrics tag.
    Parameters:
      `name` - of the tag
      `description` - of the tag
      `value` - of the tag
    Returns:
      an interned metrics tag