pub struct StreamMatch {
pub id: ExpressionIndex,
pub range: Range,
}
stream
only.Expand description
Match objects returned when searching streaming data.
This is returned by e.g.
Scratch::scan_sync_stream()
,
Scratch::scan_sync_vectored_stream()
, or
Scratch::flush_eod_sync()
.
Fields§
§id: ExpressionIndex
ID of matched expression, or 0
if unspecified.
range: Range
The start (if Flags::SOM_LEFTMOST
is provided) and end offsets of the match, with reference to the entire
history of string data that has been provided to this
LiveStream
object.
Note that LiveStream::reset()
will reset the stream automaton to
its start state and cause match offsets reported to the callback after
the reset to start once again from 0.
See the crate::stream
module for a further discussion of how and
when to effectively use the streaming interface, especially how to work
around not being able to reference the contents of the original data
stream.
Trait Implementations§
Source§impl Clone for StreamMatch
impl Clone for StreamMatch
Source§fn clone(&self) -> StreamMatch
fn clone(&self) -> StreamMatch
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for StreamMatch
impl Debug for StreamMatch
Source§impl Hash for StreamMatch
impl Hash for StreamMatch
Source§impl Ord for StreamMatch
impl Ord for StreamMatch
Source§fn cmp(&self, other: &StreamMatch) -> Ordering
fn cmp(&self, other: &StreamMatch) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for StreamMatch
impl PartialEq for StreamMatch
Source§impl PartialOrd for StreamMatch
impl PartialOrd for StreamMatch
impl Copy for StreamMatch
impl Eq for StreamMatch
impl StructuralPartialEq for StreamMatch
Auto Trait Implementations§
impl Freeze for StreamMatch
impl RefUnwindSafe for StreamMatch
impl Send for StreamMatch
impl Sync for StreamMatch
impl Unpin for StreamMatch
impl UnwindSafe for StreamMatch
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.