Enum buttplug::client::ButtplugClientEvent
source · pub enum ButtplugClientEvent {
ScanningFinished,
DeviceAdded(Arc<ButtplugClientDevice>),
DeviceRemoved(Arc<ButtplugClientDevice>),
PingTimeout,
ServerConnect,
ServerDisconnect,
Error(ButtplugError),
}Expand description
Enum representing different events that can be emitted by a client.
These events are created by the server and sent to the client, and represent unrequested actions that the client will need to respond to, or that applications using the client may be interested in.
Variants§
ScanningFinished
Emitted when a scanning session (started via a StartScanning call on ButtplugClient) has finished.
DeviceAdded(Arc<ButtplugClientDevice>)
Emitted when a device has been added to the server. Includes a ButtplugClientDevice object representing the device.
DeviceRemoved(Arc<ButtplugClientDevice>)
Emitted when a device has been removed from the server. Includes a ButtplugClientDevice object representing the device.
PingTimeout
Emitted when a client has not pinged the server in a sufficient amount of time.
ServerConnect
Emitted when the client successfully connects to a server.
ServerDisconnect
Emitted when a client connector detects that the server has disconnected.
Error(ButtplugError)
Emitted when an error that cannot be matched to a request is received from the server.
Trait Implementations§
source§impl Clone for ButtplugClientEvent
impl Clone for ButtplugClientEvent
source§fn clone(&self) -> ButtplugClientEvent
fn clone(&self) -> ButtplugClientEvent
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more