const classafBson::Timestamp

sys::Obj
  afBson::Timestamp

@Serializable

(BSON Type) - Timestamps are used internally by MongoDB's replication. You can see them in their natural habitat by querying local.main.$oplog.

increment

Source

const Int increment

The increment value.

makeTimestamp

Source

new makeTimestamp(Int seconds, Int increment)

Creates a BSON Timestamp instance.

now

Source

static Timestamp now()

Returns a unique Timestamp representing now.

seconds

Source

const Int seconds

The number of seconds since the UNIX epoch.

toJs

Source

Str toJs()

Returns a Mongo Shell compliant, JavaScript representation of the Timestamp. Example:

timestamp.toJs  // --> Timestamp(1476290079, 4)

See MongoDB Extended JSON.