rusty_time_core/lib.rs
1//! rusty_time-core — portable NTP protocol and clock-discipline algorithms.
2//!
3//! This crate knows bytes, timestamps, and estimates. It performs no I/O, reads no
4//! OS clock, and holds no product types: a developer who has never heard of the rest
5//! of the workspace can drive it. All platform work lives behind the seams in
6//! `rusty_time-clock`; all wire transport lives in the deliverables.
7//!
8//! Sign convention used everywhere: an offset is **the number of seconds to ADD to
9//! the local clock** to match the source (RFC 5905 θ). Positive offset = local is
10//! behind.
11
12pub mod client;
13pub mod config;
14pub mod discipline;
15pub mod filter;
16pub mod ntp;
17pub mod refclock;
18pub mod select;
19pub mod server;
20pub mod vclock;
21
22pub use discipline::{ClockCommand, Discipline, DisciplineConfig, Plan};
23pub use filter::{RegressEstimate, Sample, SampleRegister};
24pub use ntp::{LeapIndicator, Mode, NtpPacket, NtpShort, NtpTimestamp, ParseError};
25pub use select::{Selection, SourceEstimate};
26pub use server::{
27 ClientHandle, ClientRecord, ClientTable, Disposition, RateLimitConfig, ResponseMode,
28 ServerStats,
29};
30pub use vclock::VirtualClock;