pub enum WcpCommand {
Show 13 variants
get_item_list,
get_item_info {
ids: Vec<DisplayedItemRef>,
},
set_item_color {
id: DisplayedItemRef,
color: String,
},
add_variables {
variables: Vec<String>,
},
add_scope {
scope: String,
recursive: bool,
},
reload,
set_viewport_to {
timestamp: BigInt,
},
remove_items {
ids: Vec<DisplayedItemRef>,
},
focus_item {
id: DisplayedItemRef,
},
clear,
load {
source: String,
},
zoom_to_fit {
viewport_idx: usize,
},
shutdowmn,
}
Variants§
get_item_list
Responds with WcpResponse::get_item_list which contains a list of the items in the currently loaded waveforms
get_item_info
Responds with WcpResponse::get_item_info which contains information about
each item specified in ids
in the same order as in the ids
array.
Responds with an error if any of the specified IDs are not items in the currently loaded
waveform.
Fields
ids: Vec<DisplayedItemRef>
set_item_color
Changes the color of the specified item to the specified color.
Responds with WcpResponse::ack
Responds with an error if the id
does not exist in the currently loaded waveform.
add_variables
Adds the specified variables to the view. Responds with WcpResponse::add_variables which contains a list of the item references that can be used to reference the added items later Responds with an error if no waveforms are loaded
add_scope
Adds all variables in the specified scope to the view. Does so recursively if specified Responds with WcpResponse::add_variables which contains a list of the item references that can be used to reference the added items later Responds with an error if no waveforms are loaded
reload
Reloads the waveform from disk if this is possible for the current waveform format. If it is not possible, this has no effect. Responds instantly with WcpResponse::ack Once the waveforms have been loaded, a separate event is triggered
set_viewport_to
Moves the viewport to center it on the specified timestamp. Does not affect the zoom level. Responds with WcpResponse::ack
remove_items
Removes the specified items from the view. Responds with WcpResponse::ack Does not error if some of the IDs do not exist
Fields
ids: Vec<DisplayedItemRef>
focus_item
Sets the specified ID as the focused item. Responds with WcpResponse::ack Responds with an error if no waveforms are loaded or if the item reference does not exist
Fields
clear
Removes all currently displayed items Responds with WcpResponse::ack
load
Loads a waveform from the specified file. Responds instantly with WcpResponse::ack Once the file is loaded, a WcpEvent::waveforms_loaded is emitted.
zoom_to_fit
Zooms out fully to fit the whole waveform in the view Responds instantly with WcpResponse::ack
shutdowmn
Shut down the WCP server.
Trait Implementations§
Source§impl Debug for WcpCommand
impl Debug for WcpCommand
Source§impl<'de> Deserialize<'de> for WcpCommand
impl<'de> Deserialize<'de> for WcpCommand
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>,
Source§impl PartialEq for WcpCommand
impl PartialEq for WcpCommand
Source§impl Serialize for WcpCommand
impl Serialize for WcpCommand
impl StructuralPartialEq for WcpCommand
Auto Trait Implementations§
impl Freeze for WcpCommand
impl RefUnwindSafe for WcpCommand
impl Send for WcpCommand
impl Sync for WcpCommand
impl Unpin for WcpCommand
impl UnwindSafe for WcpCommand
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
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
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>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
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)
fn as_any(&self) -> &(dyn Any + 'static)
&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)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&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
impl<T> DowncastSync for T
Source§impl<T> GetSetFdFlags for T
impl<T> GetSetFdFlags for T
Source§fn get_fd_flags(&self) -> Result<FdFlags, Error>where
T: AsFilelike,
fn get_fd_flags(&self) -> Result<FdFlags, Error>where
T: AsFilelike,
self
file descriptor.Source§fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error>where
T: AsFilelike,
fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error>where
T: AsFilelike,
Source§fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error>where
T: AsFilelike,
fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error>where
T: AsFilelike,
self
file descriptor. Read moreSource§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> 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>
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>
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