Expand description
The dummy handler defaults to doing nothing with a notification, and returning a generic error for a request. It can be used if a plugin only wants to send requests to neovim and get responses, but not handle any notifications or requests.
Implementations
Trait Implementations
sourceimpl<Q> Handler for Dummy<Q> where
Q: AsyncWrite + Send + Sync + Unpin + 'static,
impl<Q> Handler for Dummy<Q> where
Q: AsyncWrite + Send + Sync + Unpin + 'static,
type Writer = Q
type Writer = Q
The type where we write our responses to requests. Handling of incoming requests/notifications is done on the io loop, which passes the parsed messages to the handler. Read more
sourcefn handle_request<'life0, 'async_trait>(
&'life0 self,
_name: String,
_args: Vec<Value>,
_neovim: Neovim<Self::Writer>
) -> Pin<Box<dyn Future<Output = Result<Value, Value>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
fn handle_request<'life0, 'async_trait>(
&'life0 self,
_name: String,
_args: Vec<Value>,
_neovim: Neovim<Self::Writer>
) -> Pin<Box<dyn Future<Output = Result<Value, Value>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
sourcefn handle_notify<'life0, 'async_trait>(
&'life0 self,
_name: String,
_args: Vec<Value>,
_neovim: Neovim<<Self as Handler>::Writer>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
fn handle_notify<'life0, 'async_trait>(
&'life0 self,
_name: String,
_args: Vec<Value>,
_neovim: Neovim<<Self as Handler>::Writer>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
Handling an rpc notification. Notifications are handled one at a time in the order in which they were received, and will block new requests from being received until handle_notify returns. Read more
Auto Trait Implementations
impl<Q> RefUnwindSafe for Dummy<Q> where
Q: RefUnwindSafe,
impl<Q> Send for Dummy<Q>
impl<Q> Sync for Dummy<Q>
impl<Q> Unpin for Dummy<Q>
impl<Q> UnwindSafe for Dummy<Q> where
Q: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more