add a little documentation re: soft buffer limits
This commit is contained in:
parent
32cf6dd2ef
commit
0e370556a2
3 changed files with 10 additions and 4 deletions
|
@ -15,7 +15,10 @@ pub struct EbmlStreamingParser<S> {
|
|||
}
|
||||
|
||||
impl<S> EbmlStreamingParser<S> {
|
||||
pub fn with_buffer_limit(mut self, limit: usize) -> Self {
|
||||
/// add a "soft" buffer size limit; if the input buffer exceeds this size,
|
||||
/// error the stream instead of resuming. It's still possible for the buffer
|
||||
/// to exceed this size *after* a fill, so ensure input sizes are reasonable.
|
||||
pub fn with_soft_limit(mut self, limit: usize) -> Self {
|
||||
self.buffer_size_limit = Some(limit);
|
||||
self
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue