org.apache.solr.common.util

## Class TimeSource.CurrentTimeSource

- java.lang.Object
- - org.apache.solr.common.util.TimeSource
  - - org.apache.solr.common.util.TimeSource.CurrentTimeSource

Enclosing class:
  TimeSource

    public static final class TimeSource.CurrentTimeSource
    extends TimeSource

Implementation that uses `System.currentTimeMillis()`.

### Nested Class Summary

### Nested classes/interfaces inherited from class org.apache.solr.common.util.TimeSource

`TimeSource.CurrentTimeSource, TimeSource.NanoTimeSource, TimeSource.SimTimeSource`

### Field Summary

### Fields inherited from class org.apache.solr.common.util.TimeSource

`CURRENT_TIME, NANO_TIME`

### Constructor Summary

Constructors
Constructor and Description
`CurrentTimeSource()`

### Method Summary

All Methods Instance Methods Concrete Methods
`long` `convertDelay(TimeUnit fromUnit, long value, TimeUnit toUnit)`
`long` `getTime()` Return a time value, in nanosecond unit.
`void` `sleep(long ms)`

### Methods inherited from class org.apache.solr.common.util.TimeSource

`get`

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

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

### Constructor Detail

#### CurrentTimeSource

    public CurrentTimeSource()

### Method Detail

#### getTime

    public long getTime()

Description copied from class: `TimeSource`
Return a time value, in nanosecond unit.

Specified by:
  `getTime` in class `TimeSource`

#### sleep

    public void sleep(long ms)
               throws InterruptedException

Specified by:
  `sleep` in class `TimeSource`
Throws:
  `InterruptedException`

#### convertDelay

    public long convertDelay(TimeUnit fromUnit,
                             long value,
                             TimeUnit toUnit)

Specified by:
  `convertDelay` in class `TimeSource`