use crate::timing::Duration;
#[derive(Debug, Clone, PartialEq)]
pub struct TimelineMarker {
name: String,
offset: Duration,
}
impl TimelineMarker {
#[must_use]
pub fn new(name: impl Into<String>, offset: impl Into<Duration>) -> Self {
Self {
name: name.into(),
offset: offset.into(),
}
}
#[must_use]
pub fn name(&self) -> &str {
&self.name
}
#[must_use]
pub const fn offset(&self) -> Duration {
self.offset
}
}