Timestamp Class

A Timestamp represents a point in time independent of any time zone or calendar, represented as seconds and fractions of seconds at nanosecond resolution in UTC Epoch time.

Definition

Namespace: GenerativeAI.Types
Assembly: GenerativeAI (in GenerativeAI.dll) Version: 2.0.2+aa51399cad6d90cc71158d589a6268608b3c1893
C#
public class Timestamp
Inheritance
Object    Timestamp

Constructors

TimestampInitializes a new instance of the Timestamp class

Properties

Nanos Non-negative fractions of a second at nanosecond resolution. Negative second values with fractions must still have non-negative nanos values that count forward in time. Must be from 0 to 999,999,999 inclusive.
Seconds Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z inclusive.

Methods

EqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
FinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
FromDateTime Creates a new Timestamp object from a DateTime object.
GetHashCodeServes as the default hash function.
(Inherited from Object)
GetTypeGets the Type of the current instance.
(Inherited from Object)
MemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
ToDateTime Converts this Timestamp object to a DateTime object.
ToStringReturns a string that represents the current object.
(Inherited from Object)

Operators

(DateTime to Timestamp) Implicitly converts a DateTime object to a Timestamp object.
(Timestamp to DateTime) Implicitly converts a Timestamp object to a DateTime object.

See Also