Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -479,19 +479,27 @@ impl StreamInstant {
Self::new(s, ns)
}

fn new(secs: i64, nanos: u32) -> Self {
pub fn new(secs: i64, nanos: u32) -> Self {
StreamInstant { secs, nanos }
}
}

impl InputCallbackInfo {
pub fn new(timestamp: InputStreamTimestamp) -> Self {
Self { timestamp }
}

/// The timestamp associated with the call to an input stream's data callback.
pub fn timestamp(&self) -> InputStreamTimestamp {
self.timestamp
}
}

impl OutputCallbackInfo {
pub fn new(timestamp: OutputStreamTimestamp) -> Self {
Self { timestamp }
}

/// The timestamp associated with the call to an output stream's data callback.
pub fn timestamp(&self) -> OutputStreamTimestamp {
self.timestamp
Expand Down
Loading