pub struct DocumentSearchImpl { /* private fields */ }Expand description
Document search implementation with optional FST indexing
Implementations§
Trait Implementations§
Source§impl Debug for DocumentSearchImpl
impl Debug for DocumentSearchImpl
Source§impl Default for DocumentSearchImpl
impl Default for DocumentSearchImpl
Source§impl DocumentSearch for DocumentSearchImpl
impl DocumentSearch for DocumentSearchImpl
Source§fn build_index(&mut self, document: &EditorDocument) -> Result<()>
fn build_index(&mut self, document: &EditorDocument) -> Result<()>
Build or rebuild the search index for the document
Source§fn update_index(
&mut self,
document: &EditorDocument,
changes: &[Range],
) -> Result<()>
fn update_index( &mut self, document: &EditorDocument, changes: &[Range], ) -> Result<()>
Update the search index incrementally after document changes
Source§fn search(
&self,
pattern: &str,
options: &SearchOptions,
) -> Result<Vec<SearchResult<'_>>>
fn search( &self, pattern: &str, options: &SearchOptions, ) -> Result<Vec<SearchResult<'_>>>
Search for a pattern in the document
Source§fn find_replace(
&self,
document: &mut EditorDocument,
pattern: &str,
replacement: &str,
options: &SearchOptions,
) -> Result<Vec<SearchResult<'_>>>
fn find_replace( &self, document: &mut EditorDocument, pattern: &str, replacement: &str, options: &SearchOptions, ) -> Result<Vec<SearchResult<'_>>>
Find and replace text in the document
Source§fn stats(&self) -> SearchStats
fn stats(&self) -> SearchStats
Get search statistics
Source§fn clear_index(&mut self)
fn clear_index(&mut self)
Clear the search index to free memory
Auto Trait Implementations§
impl Freeze for DocumentSearchImpl
impl RefUnwindSafe for DocumentSearchImpl
impl Send for DocumentSearchImpl
impl Sync for DocumentSearchImpl
impl Unpin for DocumentSearchImpl
impl UnwindSafe for DocumentSearchImpl
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