Skip to content

Commit

Permalink
improve seek beyond end documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
dvdsk committed Oct 13, 2023
1 parent c0e4a3e commit afa1b76
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
6 changes: 4 additions & 2 deletions src/sink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,10 @@ impl Sink {
/// when you try to seek beyong the length of the source this function will seek
/// to the end of the source instead.
///
/// If the duration of the source is known and the seek position lies beyond
/// it the saturates, that is the position is then at the end of the source.
/// As long as the duration of the source is known seek is guarenteed to saturate
/// at the end of the source. For example given a source that reports a total duration
/// of 42 seconds calling `try_seek()` with 60 seconds as argument will seek to
/// 42 seconds.
///
/// # Errors
/// This function will return [`SeekError::NotSupported`] if one of the underlying
Expand Down
6 changes: 4 additions & 2 deletions src/source/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -363,8 +363,10 @@ where
/// when you seek beyong the sources length this function will seek to the
/// end of the source instead.
///
/// If the duration of the source is known and the seek position lies beyond
/// it the saturates, that is the position is then at the end of the source.
/// As long as the duration of the source is known seek is guarenteed to saturate
/// at the end of the source. For example given a source that reports a total duration
/// of 42 seconds calling `try_seek()` with 60 seconds as argument will seek to
/// 42 seconds.
///
/// # Errors
/// This function will return [`SeekError::NotSupported`] if one of the underlying
Expand Down
6 changes: 4 additions & 2 deletions src/spatial_sink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,10 @@ impl SpatialSink {
/// when you try to seek beyong the length of the source this function will seek
/// to the end of the source instead.
///
/// If the duration of the source is known and the seek position lies beyond
/// it the saturates, that is the position is then at the end of the source.
/// As long as the duration of the source is known seek is guarenteed to saturate
/// at the end of the source. For example given a source that reports a total duration
/// of 42 seconds calling `try_seek()` with 60 seconds as argument will seek to
/// 42 seconds.
///
/// # Errors
/// This function will return [`SeekError::NotSupported`] if one of the underlying
Expand Down

0 comments on commit afa1b76

Please sign in to comment.