SPL File epochms.spl
Set of functionality supporting a time represented in number of milliseconds since 1970-01-01 00:00:00.000. This matches the epoch for Java and Javascript.
Content
- Functions
-
- toTimeMillis(timestamp): Get a TimeMillis value from a SPL timestamp value.
- toTimestamp(TimeMillis): Get a SPL timestamp from a TimeMillis.
- toTimestamp(TimeMillis, int32): Get a SPL timestamp from a TimeMillis and a machine identifier.
- Types
-
- TimeMillis: Milliseconds since epoch (1970-01-01 00:00:00.000). Useful when interfacing to Java and Javascript.
Functions
TimeMillis toTimeMillis(timestamp ts)
Get a TimeMillis value from a SPL timestamp value.
Parameters
- ts: timestamp value to be converted.
Returns
- Value of ts in milliseconds since the epoch.
timestamp toTimestamp(TimeMillis ms, int32 mid)
Get a SPL timestamp from a TimeMillis and a machine identifier.
Parameters
- ms: Milliseconds since the epoch.
- mid: Machine identifer for returned timestamp.
Returns
- timestamp representing ms and mid
timestamp toTimestamp(TimeMillis ms)
Get a SPL timestamp from a TimeMillis. The machine identifier is set to zero in the returned timestamp.
Parameters
- ms: Milliseconds since the epoch.
Returns
- timestamp representing ms with machine identfier set to zero.
Types
TimeMillis
Milliseconds since epoch (1970-01-01 00:00:00.000). Useful when interfacing to Java and Javascript.
TimeMillis = int64;