Skip to main content

Operation

Enum Operation 

Source
pub enum Operation {
Show 80 variants InsertText { path: Option<PathBuf>, cursor: Position, text: String, }, PasteText { path: Option<PathBuf>, text: String, }, DeleteText { path: Option<PathBuf>, cursor: Position, len: usize, }, DeleteForward { path: Option<PathBuf>, cursor: Position, }, DeleteWordBackward { path: Option<PathBuf>, }, DeleteWordForward { path: Option<PathBuf>, }, IndentLines { path: Option<PathBuf>, }, UnindentLines { path: Option<PathBuf>, }, DeleteLine { path: Option<PathBuf>, }, ReplaceRange { path: Option<PathBuf>, start: Position, end: Position, text: String, }, MoveCursor { path: Option<PathBuf>, cursor: Position, }, Undo { path: Option<PathBuf>, }, Redo { path: Option<PathBuf>, }, ToggleFold { path: Option<PathBuf>, line: usize, }, ToggleMarker { path: Option<PathBuf>, line: usize, }, ToggleWordWrap, OpenFile { path: PathBuf, }, OpenUrl { url: String, }, SaveFile { path: PathBuf, }, ReloadFromDisk { path: PathBuf, accept_external: bool, }, SwitchScreen { to: ScreenKind, }, CloseModal, Quit, Focus(FocusOp), NavigateUp, NavigateDown, NavigatePageUp, NavigatePageDown, NavigateHome, NavigateEnd, FileSelectorLocal(FileSelectorOp), CommandSelectorLocal(CommandSelectorOp), LogViewLocal(LogViewOp), CommitLocal(CommitOp), GitHistoryLocal(GitHistoryOp), ExtensionConfig(ExtensionConfigOp), LspTriggerCompletion { path: Option<PathBuf>, }, LspTriggerHover { path: Option<PathBuf>, }, LspGoToDefinition { path: Option<PathBuf>, }, LspGoToDefinitionResult(Vec<LspLocation>), LspLocal(LspOp), SearchLocal(SearchOp), GoToLineLocal(GoToLineOp), SelectionLocal(SelectionOp), ClipboardLocal(ClipOp), SearchReplaceLocal(SearchReplaceOp), RunCommand { id: CommandId, args: HashMap<String, ArgValue>, }, OpenContextMenu { items: Vec<(String, CommandId, Option<bool>)>, x: u16, y: u16, }, CloseContextMenu, Generic { source: Cow<'static, str>, name: Cow<'static, str>, payload: HashMap<String, ArgValue>, }, ExtensionEvent { name: String, payload: HashMap<String, String>, }, ShowNotification { message: String, level: NotificationLevel, }, UpdateStatusBar { text: String, slot: StatusSlot, }, CreateTerminal { command: String, }, TerminalInput { id: u64, data: Vec<u8>, }, TerminalLocal(TerminalOp), ShowPicker { title: String, items: Vec<PickerItem>, }, SetEditorHighlights { path: Option<PathBuf>, version: Version, start_line: usize, generation: u64, spans: Vec<Vec<StyledSpan>>, }, SetEditorHighlightsChunk { path: Option<PathBuf>, version: Version, generation: u64, spans: Vec<(usize, Vec<StyledSpan>)>, }, AddIssue { issue: NewIssue, }, RemoveIssue { id: IssueId, }, ResolveIssue { id: IssueId, }, DismissIssue { id: IssueId, }, ClearIssuesByMarker { marker: String, }, PersistentIssueLocal(PersistentIssueOp), IssueAdded { id: IssueId, }, IssueRemoved { id: IssueId, }, IssueUpdated { id: IssueId, }, TaskScheduled(TaskId), TaskStarted(TaskId), TaskFinished { id: TaskId, status: TaskStatus, }, TaskCancelled(TaskId), ScheduleTask { key: TaskKey, trigger: TaskTrigger, command: String, }, CancelTask(TaskId), OpenLogForTask { task_id: TaskId, }, OpenTaskArchive, ShowTaskOutput { task_id: TaskId, title: String, status: TaskStatus, lines: Vec<String>, }, TaskArchiveLocal(TaskArchiveOp), OpenIssueList, IssueViewLocal(IssueViewOp),
}

Variants§

§

InsertText

Fields

§cursor: Position
§text: String
§

PasteText

Bracketed paste (or fallback-heuristic detected paste) delivered to the active editor. Unlike InsertText, the full multi-line string is inserted at once via insert_text_raw and also pushed to the clipboard register.

Fields

§text: String
§

DeleteText

Fields

§cursor: Position
§len: usize
§

DeleteForward

Fields

§cursor: Position
§

DeleteWordBackward

Fields

§

DeleteWordForward

Fields

§

IndentLines

Fields

§

UnindentLines

Fields

§

DeleteLine

Fields

§

ReplaceRange

Replace the text from start to end (same line, byte offsets) with text. Used by CompletionConfirm to delete the filter prefix before inserting.

Fields

§start: Position
§text: String
§

MoveCursor

Fields

§cursor: Position
§

Undo

Fields

§

Redo

Fields

§

ToggleFold

Fields

§line: usize
§

ToggleMarker

Fields

§line: usize
§

ToggleWordWrap

§

OpenFile

Fields

§path: PathBuf
§

OpenUrl

Open an external URL in the system default browser.

Fields

§

SaveFile

Fields

§path: PathBuf
§

ReloadFromDisk

Fields

§path: PathBuf
§accept_external: bool
§

SwitchScreen

Fields

§

CloseModal

Close the currently open modal/temporary view.

If the current view is already primary, this is a no-op.

§

Quit

§

Focus(FocusOp)

§

NavigateUp

§

NavigateDown

§

NavigatePageUp

§

NavigatePageDown

§

NavigateHome

§

NavigateEnd

§

FileSelectorLocal(FileSelectorOp)

§

CommandSelectorLocal(CommandSelectorOp)

§

LogViewLocal(LogViewOp)

§

CommitLocal(CommitOp)

§

GitHistoryLocal(GitHistoryOp)

§

ExtensionConfig(ExtensionConfigOp)

§

LspTriggerCompletion

Fields

§

LspTriggerHover

Fields

§

LspGoToDefinition

Fields

§

LspGoToDefinitionResult(Vec<LspLocation>)

Result from a go-to-definition request, dispatched back into the queue.

§

LspLocal(LspOp)

LSP editor-local ops (dropdown navigation, response delivery).

§

SearchLocal(SearchOp)

Search/replace bar ops (editor-local).

§

GoToLineLocal(GoToLineOp)

Go-to-line bar ops (editor-local).

§

SelectionLocal(SelectionOp)

Selection management ops (editor-local).

§

ClipboardLocal(ClipOp)

Clipboard ops (editor-local).

§

SearchReplaceLocal(SearchReplaceOp)

Project-wide search & replace ops.

§

RunCommand

Execute a registered command by id (with pre-filled args).

§

OpenContextMenu

Open a generic context menu at (x, y) with the given items.

Items are (label, command_id) pairs. app.rs stores the menu on crate::app_state::AppState, intercepts input, and dispatches the selected command.

Fields

§

CloseContextMenu

Close the currently open context menu without selecting any item.

§

Generic

Fields

§source: Cow<'static, str>
§name: Cow<'static, str>
§

ExtensionEvent

Broadcast a named event to all active extensions.

Fields

§name: String
§

ShowNotification

Display a user-visible notification (shown in status bar).

Fields

§message: String
§

UpdateStatusBar

Update the IDE status bar slot with custom text.

Fields

§text: String
§

CreateTerminal

Request a terminal be created running the given command.

Fields

§command: String
§

TerminalInput

Send raw bytes to the PTY of the terminal tab with the given ID.

Fields

§id: u64
§data: Vec<u8>
§

TerminalLocal(TerminalOp)

Terminal view-local operations.

§

ShowPicker

Show a picker (like command palette) populated with arbitrary items.

Fields

§title: String
§

SetEditorHighlights

Deliver pre-computed syntax-highlight spans for an editor buffer.

Sent by the background highlight task; handled in app.rs, which stores the result in crate::views::editor::EditorView::highlight_cache when the version still matches the live buffer. The next frame then renders without blocking.

Fields

§version: Version
§start_line: usize
§generation: u64
§

SetEditorHighlightsChunk

Incremental highlight update for multiple lines.

Unlike SetEditorHighlights, this operation updates individual lines without clearing existing highlights. This prevents highlights from disappearing while typing or scrolling.

Fields

§version: Version
§generation: u64
§

AddIssue

Add an issue to the registry (registry-only, no disk write).

issue.marker = Some(m) → ephemeral (cleared via ClearIssuesByMarker). issue.marker = None → used only for startup loads by the Persistent Component. User-initiated persistent issues must go through PersistentIssueLocal(Add).

Fields

§issue: NewIssue
§

RemoveIssue

Remove an issue by ID (registry-only). Emits IssueRemoved on success.

Fields

§

ResolveIssue

Mark an issue as resolved (registry-only). Emits IssueUpdated on success.

Fields

§

DismissIssue

Mark an issue as dismissed (registry-only). Emits IssueUpdated on success.

Fields

§

ClearIssuesByMarker

Remove all ephemeral issues belonging to marker. Emits one IssueRemoved per removed issue.

Fields

§marker: String
§

PersistentIssueLocal(PersistentIssueOp)

Persistent-issue commands: each variant updates the in-memory IssueRegistry and atomically rewrites .oo/issues.yaml.

§

IssueAdded

An issue was added.

Fields

§

IssueRemoved

An issue was removed.

Fields

§

IssueUpdated

An issue’s resolved or dismissed flag was toggled.

Fields

§

TaskScheduled(TaskId)

A task was created and either started immediately or added to its queue.

§

TaskStarted(TaskId)

A task transitioned from Pending to Running.

§

TaskFinished

A task reached a terminal status (Success, Warning, or Error).

Sent by crate::task_executor::TaskExecutor when the spawned process exits. Handled by apply_operation in app.rs, which calls crate::task_registry::TaskRegistry::mark_finished and starts the next queued task if one exists.

Fields

§status: TaskStatus
§

TaskCancelled(TaskId)

A task was cancelled (running or queued).

§

ScheduleTask

Schedule a new task. Handled by apply_operation, which calls crate::task_registry::TaskRegistry::schedule_task and immediately spawns the executor if the queue was idle.

Fields

§trigger: TaskTrigger
§command: String

The shell command to execute (passed through to the process).

§

CancelTask(TaskId)

Cancel a running or queued task by its ID. Handled by apply_operation, which calls crate::task_registry::TaskRegistry::cancel and starts the next queued task if one exists.

§

OpenLogForTask

Open the log view and pre-populate its filter with the task’s label so the user can quickly inspect task-related entries.

Fields

§task_id: TaskId
§

OpenTaskArchive

Open the Task Archive View.

§

ShowTaskOutput

Delivered by app.rs after it asynchronously loads task output from the log store. Switches to TaskOutputView and populates it with the lines.

Fields

§task_id: TaskId
§title: String
§status: TaskStatus
§lines: Vec<String>
§

TaskArchiveLocal(TaskArchiveOp)

View-local ops for crate::views::task_archive::TaskArchiveView.

§

OpenIssueList

Open the Issue List View.

§

IssueViewLocal(IssueViewOp)

View-local ops for crate::views::issue_view::IssueView.

Trait Implementations§

Source§

impl Clone for Operation

Source§

fn clone(&self) -> Operation

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Operation

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> Downcast for T
where T: Any,

Source§

fn into_any(self: Box<T>) -> Box<dyn Any>

Convert Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.
Source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
Source§

fn as_any(&self) -> &(dyn Any + 'static)

Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
Source§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
Source§

impl<T> DowncastSync for T
where T: Any + Send + Sync,

Source§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Send + Sync>

Convert Arc<Trait> (where Trait: Downcast) to Arc<Any>. Arc<Any> can then be further downcast into Arc<ConcreteType> where ConcreteType implements Trait.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.