Class TimestampedValue<V>
- java.lang.Object
-
- io.streamthoughts.azkarra.api.model.TimestampedValue<V>
-
- All Implemented Interfaces:
Comparable<TimestampedValue>
public class TimestampedValue<V> extends Object implements Comparable<TimestampedValue>
-
-
Constructor Summary
Constructors Constructor Description TimestampedValue(long timestamp, V value)Creates a newTimestampedValueinstance.TimestampedValue(V value)Creates a newTimestampedValueinstance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(TimestampedValue that)booleanequals(Object o)inthashCode()longtimestamp()Returns the timestamp in milliseconds for this value.StringtoString()Vvalue()Returns this valueTimestampedValue.
-
-
-
Constructor Detail
-
TimestampedValue
public TimestampedValue(V value)
Creates a newTimestampedValueinstance.- Parameters:
value- the value.
-
TimestampedValue
public TimestampedValue(long timestamp, V value)Creates a newTimestampedValueinstance.- Parameters:
timestamp- the timestamp.value- the value.
-
-
Method Detail
-
timestamp
public long timestamp()
Returns the timestamp in milliseconds for this value.
-
value
public V value()
Returns this valueTimestampedValue.
-
compareTo
public int compareTo(TimestampedValue that)
- Specified by:
compareToin interfaceComparable<V>
-
-