Struct wayland_client::ProtocolError
source · pub struct ProtocolError {
pub code: u32,
pub object_id: u32,
pub object_interface: &'static str,
pub message: String,
}
Expand description
A protocol error
This kind of error is generated by the server if your client didn’t respect the protocol, after which the server will kill your connection.
If the dispatching methods of EventQueues
start to fail, you may want to
check Display::protocol_error()
to see if a protocol error was generated.
Fields§
§code: u32
The error code associated with the error
It should be interpreted as an instance of the Error
enum of the
associated interface.
object_id: u32
The id of the object that caused the error
object_interface: &'static str
The interface of the object that caused the error
message: String
The message sent by the server describing the error
Trait Implementations§
source§impl Clone for ProtocolError
impl Clone for ProtocolError
source§fn clone(&self) -> ProtocolError
fn clone(&self) -> ProtocolError
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ProtocolError
impl Debug for ProtocolError
source§impl Display for ProtocolError
impl Display for ProtocolError
source§impl Error for ProtocolError
impl Error for ProtocolError
source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
Auto Trait Implementations§
impl RefUnwindSafe for ProtocolError
impl Send for ProtocolError
impl Sync for ProtocolError
impl Unpin for ProtocolError
impl UnwindSafe for ProtocolError
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
Mutably borrows from an owned value. Read more