pub fn from_u8(u: u8) -> Result<Permissions> {
        match u {
            0x00 => Ok(Permissions::User),
            0x01 => Ok(Permissions::Admin),
            _ => Err(Error::from_str("invalid permission Byte")),
        }
    }
/// Converts a Byte value to the corresponding `Permissions` variant.
Converts a Byte value to the corresponding `Permissions` variant.
Converts a Byte value to the corresponding ` Permissions ` variant .
pub fn from_u8(u: u8) -> Result<Permissions> {
        match u {
            0x00 => Ok(Permissions::User),
            0x01 => Ok(Permissions::Admin),
            _ => Err(Error::from_str("invalid permission Byte")),
        }
    }
pub fn from_u8 ( u : u8 ) -> Result < Permissions > { match u { 0x00 => Ok ( Permissions :: User ) , 0x01 => Ok ( Permissions :: Admin ) , _ => Err ( Error :: from_str ( " " ) ) , } }
Converts a Byte value to the corresponding `Permissions` variant.
Converts a Byte value to the corresponding ` Permissions ` variant .
u
u8
u
u8