Class SourceWrappedStatistics

java.lang.Object
org.apache.hadoop.fs.statistics.impl.SourceWrappedStatistics
All Implemented Interfaces:
IOStatisticsSource

public class SourceWrappedStatistics extends Object implements IOStatisticsSource
Wrap a statistics instance with an IOStatisticsSource instance which will then serve up the statistics when asked.
  • Constructor Details

    • SourceWrappedStatistics

      public SourceWrappedStatistics(IOStatistics source)
      Constructor.
      Parameters:
      source - source of statistics.
  • Method Details

    • getIOStatistics

      public IOStatistics getIOStatistics()
      Description copied from interface: IOStatisticsSource
      Return a statistics instance.

      It is not a requirement that the same instance is returned every time. IOStatisticsSource.

      If the object implementing this is Closeable, this method may return null if invoked on a closed object, even if it returns a valid instance when called earlier.

      Specified by:
      getIOStatistics in interface IOStatisticsSource
      Returns:
      an IOStatistics instance or null