Class RecoveryState.Timer
- java.lang.Object
-
- org.elasticsearch.indices.recovery.RecoveryState.Timer
-
- All Implemented Interfaces:
Writeable
- Direct Known Subclasses:
RecoveryState.Index
,RecoveryState.Translog
,RecoveryState.VerifyIndex
- Enclosing class:
- RecoveryState
public static class RecoveryState.Timer extends java.lang.Object implements Writeable
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
Fields Modifier and Type Field Description protected long
startNanoTime
protected long
startTime
protected long
stopTime
protected long
time
-
Constructor Summary
Constructors Constructor Description Timer()
Timer(StreamInput in)
-
Method Summary
Modifier and Type Method Description void
reset()
void
start()
long
startTime()
Returns start time in millisvoid
stop()
long
stopTime()
Returns stop time in millislong
time()
Returns elapsed time in millis, or 0 if timer was not startedvoid
writeTo(StreamOutput out)
Write this into the StreamOutput.
-
-
-
Constructor Detail
-
Timer
public Timer()
-
Timer
public Timer(StreamInput in) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
writeTo
public void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:Writeable
Write this into the StreamOutput.
-
start
public void start()
-
startTime
public long startTime()
Returns start time in millis
-
time
public long time()
Returns elapsed time in millis, or 0 if timer was not started
-
stopTime
public long stopTime()
Returns stop time in millis
-
stop
public void stop()
-
reset
public void reset()
-
-