Google Cloud Dataflow SDK for Java, version 1.9.1
com.google.cloud.dataflow.sdk.values
Class TimestampedValue<V>
- java.lang.Object
-
- com.google.cloud.dataflow.sdk.values.TimestampedValue<V>
-
- Type Parameters:
V
- the type of the value
public class TimestampedValue<V> extends Object
An immutable pair of a value and a timestamp.The timestamp of a value determines many properties, such as its assignment to windows and whether the value is late (with respect to the watermark of a
PCollection
).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static class
TimestampedValue.TimestampedValueCoder<T>
ACoder
forTimestampedValue
.
-
Constructor Summary
Constructors Modifier Constructor and Description protected
TimestampedValue(V value, Instant timestamp)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description boolean
equals(Object other)
Instant
getTimestamp()
V
getValue()
int
hashCode()
static <V> TimestampedValue<V>
of(V value, Instant timestamp)
Returns a newTimestampedValue
with the given value and timestamp.String
toString()
-
-
-
Method Detail
-
of
public static <V> TimestampedValue<V> of(V value, Instant timestamp)
Returns a newTimestampedValue
with the given value and timestamp.
-
getValue
public V getValue()
-
getTimestamp
public Instant getTimestamp()
-
-