CEL timestamp type. Wraps an Elixir DateTime (UTC). Supports RFC3339 parsing, arithmetic with durations, and accessor methods.
Summary
Functions
Add a duration (in microseconds) to a timestamp.
Add a duration (total nanoseconds) to a timestamp, returning {timestamp, total_result_nanos_since_epoch}.
Difference between two timestamps in microseconds.
Difference between two timestamps in nanoseconds.
Get a component of the timestamp, optionally in a timezone.
Creates a timestamp from a DateTime.
Parses an RFC3339 timestamp string.
Subtract a duration (in microseconds) from a timestamp.
Convert to proto representation {seconds, nanos}.
Converts to RFC3339 string.
Returns Unix epoch seconds.
Types
@type t() :: %Celixir.Types.Timestamp{ datetime: DateTime.t(), nanos_remainder: integer() }
Functions
Add a duration (in microseconds) to a timestamp.
Add a duration (total nanoseconds) to a timestamp, returning {timestamp, total_result_nanos_since_epoch}.
Difference between two timestamps in microseconds.
Difference between two timestamps in nanoseconds.
Get a component of the timestamp, optionally in a timezone.
Creates a timestamp from a DateTime.
Parses an RFC3339 timestamp string.
Subtract a duration (in microseconds) from a timestamp.
Convert to proto representation {seconds, nanos}.
Converts to RFC3339 string.
Returns Unix epoch seconds.