struct TreeStore {
states: FxHashMap<SyntaxNode, TreeState>,
}Expand description
Owns all evolving trees involved in executing an edit plan.
Fields§
§states: FxHashMap<SyntaxNode, TreeState>Implementations§
Source§impl TreeStore
impl TreeStore
Sourcefn with_annotations(
annotations: Vec<(SyntaxElement, SyntaxAnnotation)>,
mappings: &SyntaxMapping,
) -> Self
fn with_annotations( annotations: Vec<(SyntaxElement, SyntaxAnnotation)>, mappings: &SyntaxMapping, ) -> Self
Creates per tree state for annotations after following factory mapping.
Sourcefn execute(&mut self, plan: EditPlan)
fn execute(&mut self, plan: EditPlan)
Execute an already ordered plan without performing further analysis.
Sourcefn prepare_element(&self, element: &SyntaxElement) -> PreparedElement
fn prepare_element(&self, element: &SyntaxElement) -> PreparedElement
Captures the source element and annotations used by a replacement.
Sourcefn finish(self, old_root: SyntaxNode) -> SyntaxEdit
fn finish(self, old_root: SyntaxNode) -> SyntaxEdit
Resolves the editor roots tracked paths and constructs the public edit.
Auto Trait Implementations§
impl !RefUnwindSafe for TreeStore
impl !Send for TreeStore
impl !Sync for TreeStore
impl !UnwindSafe for TreeStore
impl Freeze for TreeStore
impl Unpin for TreeStore
impl UnsafeUnpin for TreeStore
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more