pub struct SearchMatch {
pub range: Range<usize>,
}Expand description
One non-overlapping search result expressed as a UTF-8 byte range.
§Examples
use ailloli_ui_editor::SearchMatch;
let found = SearchMatch { range: 2..5 };
assert_eq!(found.range.len(), 3);Fields§
§range: Range<usize>Half-open UTF-8 byte range in the searched text.
Trait Implementations§
Source§impl Clone for SearchMatch
impl Clone for SearchMatch
Source§fn clone(&self) -> SearchMatch
fn clone(&self) -> SearchMatch
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SearchMatch
impl Debug for SearchMatch
Source§impl PartialEq for SearchMatch
impl PartialEq for SearchMatch
impl Eq for SearchMatch
impl StructuralPartialEq for SearchMatch
Auto Trait Implementations§
impl Freeze for SearchMatch
impl RefUnwindSafe for SearchMatch
impl Send for SearchMatch
impl Sync for SearchMatch
impl Unpin for SearchMatch
impl UnwindSafe for SearchMatch
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.