/** * @param timestamp milliseconds since Unix epoch * @return */ private static long fromUnixTimestamp(long timestamp) { return fromUnixTimestamp(timestamp, 0L); }
/** * @param timestamp milliseconds since Unix epoch * @return */ private static long fromUnixTimestamp(long timestamp) { return fromUnixTimestamp(timestamp, 0L); }
/** * @param timestamp milliseconds since Unix epoch * @return */ private static long fromUnixTimestamp(long timestamp) { return fromUnixTimestamp(timestamp, 0L); }
/** * @param timestamp milliseconds since Unix epoch * @return */ private static long fromUnixTimestamp(long timestamp) { return fromUnixTimestamp(timestamp, 0L); }
/** * @param timestamp milliseconds since Unix epoch * @return */ private static long fromUnixTimestamp(long timestamp) { return fromUnixTimestamp(timestamp, 0L); }
/** * @param timestamp milliseconds since Unix epoch * @return */ private static long fromUnixTimestamp(long timestamp) { return fromUnixTimestamp(timestamp, 0L); }
@VisibleForTesting public static UUID getTimeUUID(long when, long nanos, long clockSeqAndNode) { return new UUID(createTime(fromUnixTimestamp(when, nanos)), clockSeqAndNode); }
/** * Returns the smaller possible type 1 UUID having the provided timestamp. * * <b>Warning:</b> this method should only be used for querying as this * doesn't at all guarantee the uniqueness of the resulting UUID. */ public static UUID minTimeUUID(long timestamp) { return new UUID(createTime(fromUnixTimestamp(timestamp)), MIN_CLOCK_SEQ_AND_NODE); }
/** * Creates a type 1 UUID (time-based UUID) with the timestamp of @param when, in milliseconds. * * @return a UUID instance */ public static UUID getTimeUUID(long when) { return new UUID(createTime(fromUnixTimestamp(when)), clockSeqAndNode); }
/** * Creates a type 1 UUID (time-based UUID) with the timestamp of @param when, in milliseconds. * * @return a UUID instance */ public static UUID getTimeUUID(long when) { return new UUID(createTime(fromUnixTimestamp(when)), clockSeqAndNode); }
/** * Returns the smaller possible type 1 UUID having the provided timestamp. * * <b>Warning:</b> this method should only be used for querying as this * doesn't at all guarantee the uniqueness of the resulting UUID. */ public static UUID minTimeUUID(long timestamp) { return new UUID(createTime(fromUnixTimestamp(timestamp)), MIN_CLOCK_SEQ_AND_NODE); }
@VisibleForTesting public static UUID getTimeUUID(long when, long nanos, long clockSeqAndNode) { return new UUID(createTime(fromUnixTimestamp(when, nanos)), clockSeqAndNode); }
@VisibleForTesting public static UUID getTimeUUID(long when, long nanos, long clockSeqAndNode) { return new UUID(createTime(fromUnixTimestamp(when, nanos)), clockSeqAndNode); }
/** * Creates a type 1 UUID (time-based UUID) with the timestamp of @param when, in milliseconds. * * @return a UUID instance */ public static UUID getTimeUUID(long when) { return new UUID(createTime(fromUnixTimestamp(when)), clockSeqAndNode); }
/** * Returns the smaller possible type 1 UUID having the provided timestamp. * * <b>Warning:</b> this method should only be used for querying as this * doesn't at all guarantee the uniqueness of the resulting UUID. */ public static UUID minTimeUUID(long timestamp) { return new UUID(createTime(fromUnixTimestamp(timestamp)), MIN_CLOCK_SEQ_AND_NODE); }
/** * Creates a type 1 UUID (time-based UUID) with the timestamp of @param when, in milliseconds. * * @return a UUID instance */ public static UUID getTimeUUID(long when) { return new UUID(createTime(fromUnixTimestamp(when)), clockSeqAndNode); }
public static UUID getTimeUUID(long when, long nanos) { return new UUID(createTime(fromUnixTimestamp(when, nanos)), clockSeqAndNode); }
/** * Returns the smaller possible type 1 UUID having the provided timestamp. * * <b>Warning:</b> this method should only be used for querying as this * doesn't at all guarantee the uniqueness of the resulting UUID. */ public static UUID minTimeUUID(long timestamp) { return new UUID(createTime(fromUnixTimestamp(timestamp)), MIN_CLOCK_SEQ_AND_NODE); }
/** * Creates a type 1 UUID (time-based UUID) with the timestamp of @param when, in milliseconds. * * @return a UUID instance */ public static UUID getTimeUUID(long when) { return new UUID(createTime(fromUnixTimestamp(when)), clockSeqAndNode); }
/** * Returns the smaller possible type 1 UUID having the provided timestamp. * * <b>Warning:</b> this method should only be used for querying as this * doesn't at all guarantee the uniqueness of the resulting UUID. */ public static UUID minTimeUUID(long timestamp) { return new UUID(createTime(fromUnixTimestamp(timestamp)), MIN_CLOCK_SEQ_AND_NODE); }