PeerClock class abstract final

A process-local monotonic clock, mirroring the contract of LSL's lsl_local_clock().

The epoch is arbitrary — it is whenever this library was first touched in this process — so a reading is only comparable with other readings from the same process. Comparing across peers requires a clock-offset estimate, in exactly the same way lsl_time_correction() is needed to compare two LSL nodes' lsl_local_clock() readings.

Transports that have no native sender clock (WebSocket, in-memory) use this to stamp outgoing messages. The LSL transport does not: an LSL sample already carries the sender's lsl_local_clock() reading as its timestamp, and inventing a second one would only add a redundant, less accurate number.

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

now() → double
Monotonic seconds since this library was first used in this process.
nowMicros() → int
Monotonic microseconds since this library was first used in this process.