pub struct CursorContext {
pub line: usize,
pub column: usize,
pub selected_text: Option<String>,
pub surrounding_lines: Vec<String>,
pub current_function: Option<String>,
pub current_class: Option<String>,
}
Expand description
Cursor position and surrounding context
Fields§
§line: usize
§column: usize
§selected_text: Option<String>
§surrounding_lines: Vec<String>
§current_function: Option<String>
§current_class: Option<String>
Trait Implementations§
Source§impl Clone for CursorContext
impl Clone for CursorContext
Source§fn clone(&self) -> CursorContext
fn clone(&self) -> CursorContext
Returns a duplicate 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 CursorContext
impl Debug for CursorContext
Source§impl<'de> Deserialize<'de> for CursorContext
impl<'de> Deserialize<'de> for CursorContext
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for CursorContext
impl RefUnwindSafe for CursorContext
impl Send for CursorContext
impl Sync for CursorContext
impl Unpin for CursorContext
impl UnwindSafe for CursorContext
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