Struct ProxyRpcHandler

Source
pub struct ProxyRpcHandler { /* private fields */ }

Implementations§

Source§

impl ProxyRpcHandler

Source

pub fn new() -> Self

Source

pub fn rx(&self) -> &Receiver<ProxyRpc>

Source

pub fn mainloop<H>(&self, handler: &mut H)
where H: ProxyHandler,

Source

pub fn request_async( &self, request: ProxyRequest, f: impl ProxyCallback + 'static, )

Source

pub fn handle_response( &self, id: RequestId, result: Result<ProxyResponse, RpcError>, )

Source

pub fn notification(&self, notification: ProxyNotification)

Source

pub fn git_init(&self)

Source

pub fn git_commit(&self, message: String, diffs: Vec<FileDiff>)

Source

pub fn git_checkout(&self, branch: String)

Source

pub fn install_volt(&self, volt: VoltInfo)

Source

pub fn reload_volt(&self, volt: VoltMetadata)

Source

pub fn remove_volt(&self, volt: VoltMetadata)

Source

pub fn disable_volt(&self, volt: VoltInfo)

Source

pub fn enable_volt(&self, volt: VoltInfo)

Source

pub fn shutdown(&self)

Source

pub fn initialize( &self, workspace: Option<PathBuf>, disabled_volts: Vec<String>, plugin_configurations: HashMap<String, HashMap<String, Value>>, window_id: usize, tab_id: usize, )

Source

pub fn completion( &self, request_id: usize, path: PathBuf, input: String, position: Position, )

Source

pub fn new_terminal(&self, term_id: TermId, cwd: Option<PathBuf>, shell: String)

Source

pub fn terminal_close(&self, term_id: TermId)

Source

pub fn terminal_resize(&self, term_id: TermId, width: usize, height: usize)

Source

pub fn terminal_write(&self, term_id: TermId, content: &str)

Source

pub fn new_buffer( &self, buffer_id: BufferId, path: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn get_buffer_head( &self, _buffer_id: BufferId, path: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn create_file(&self, path: PathBuf, f: impl ProxyCallback + 'static)

Source

pub fn create_directory(&self, path: PathBuf, f: impl ProxyCallback + 'static)

Source

pub fn trash_path(&self, path: PathBuf, f: impl ProxyCallback + 'static)

Source

pub fn rename_path( &self, from: PathBuf, to: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn save_buffer_as( &self, buffer_id: BufferId, path: PathBuf, rev: u64, content: String, f: impl ProxyCallback + 'static, )

Source

pub fn save(&self, rev: u64, path: PathBuf, f: impl ProxyCallback + 'static)

Source

pub fn get_files(&self, f: impl ProxyCallback + 'static)

Source

pub fn get_open_files_content(&self) -> Result<ProxyResponse, RpcError>

Source

pub fn read_dir(&self, path: PathBuf, f: impl ProxyCallback + 'static)

Source

pub fn completion_resolve( &self, plugin_id: PluginId, completion_item: CompletionItem, f: impl ProxyCallback + 'static, )

Source

pub fn code_action_resolve( &self, action_item: CodeAction, plugin_id: PluginId, f: impl ProxyCallback + 'static, )

Source

pub fn get_hover( &self, request_id: usize, path: PathBuf, position: Position, f: impl ProxyCallback + 'static, )

Source

pub fn get_definition( &self, request_id: usize, path: PathBuf, position: Position, f: impl ProxyCallback + 'static, )

Source

pub fn get_type_definition( &self, request_id: usize, path: PathBuf, position: Position, f: impl ProxyCallback + 'static, )

Source

pub fn get_references( &self, path: PathBuf, position: Position, f: impl ProxyCallback + 'static, )

Source

pub fn get_code_actions( &self, path: PathBuf, position: Position, f: impl ProxyCallback + 'static, )

Source

pub fn get_document_formatting( &self, path: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn get_semantic_tokens( &self, path: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn get_document_symbols( &self, path: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn get_workspace_symbols( &self, query: String, f: impl ProxyCallback + 'static, )

Source

pub fn prepare_rename( &self, path: PathBuf, position: Position, f: impl ProxyCallback + 'static, )

Source

pub fn git_get_remote_file_url( &self, file: PathBuf, f: impl ProxyCallback + 'static, )

Source

pub fn rename( &self, path: PathBuf, position: Position, new_name: String, f: impl ProxyCallback + 'static, )

Source

pub fn get_inlay_hints(&self, path: PathBuf, f: impl ProxyCallback + 'static)

Source

pub fn update(&self, path: PathBuf, delta: RopeDelta, rev: u64)

Source

pub fn update_plugin_configs( &self, configs: HashMap<String, HashMap<String, Value>>, )

Source

pub fn git_discard_files_changes(&self, files: Vec<PathBuf>)

Source

pub fn git_discard_workspace_changes(&self)

Source

pub fn get_selection_range( &self, path: PathBuf, positions: Vec<Position>, f: impl ProxyCallback + 'static, )

Trait Implementations§

Source§

impl Clone for ProxyRpcHandler

Source§

fn clone(&self) -> ProxyRpcHandler

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 Default for ProxyRpcHandler

Source§

fn default() -> Self

Returns the “default value” for a type. 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> 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> 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.
Source§

impl<T> ErasedDestructor for T
where T: 'static,