Skip to main content

IntoStatusU16

Trait IntoStatusU16 

Source
pub trait IntoStatusU16 {
    // Required method
    fn into_status_u16(self) -> u16;
}
Expand description

Helper trait to convert various types to u16 for status code comparison.

This enables the assert_status! macro to accept both u16 literals and StatusCode values.

Required Methods§

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl IntoStatusU16 for i32

Source§

impl IntoStatusU16 for u16

Implementors§