Struct rustable::UUID[][src]

pub struct UUID(pub u128);

Represents a UUID used for GATT attributes.

Implementations

impl UUID[src]

pub const fn short(&self) -> Option<u16>[src]

Get the 16-bit Bluetooth UUID alias for this UUID if it is in the proper range.

pub const fn uint(&self) -> Option<u32>[src]

Get the 32-bit Bluetooth UUID alias for this UUID if it is in the proper range.

Trait Implementations

impl Clone for UUID[src]

impl Debug for UUID[src]

impl Display for UUID[src]

impl From<UUID> for u128[src]

impl From<u128> for UUID[src]

impl From<u16> for UUID[src]

fn from(u: u16) -> Self[src]

Creates a UUID from a 16-bit Bluetooth UUID aliases.

The actual conversion done is ((u16_val as u128) << 96) + BT_BASE_UUID

impl From<u32> for UUID[src]

fn from(u: u32) -> Self[src]

Creates a UUID from a 32-bit Bluetooth UUID aliases.

The actual conversion done is ((u32_val as u128) << 96) + BT_BASE_UUID

impl FromStr for UUID[src]

type Err = IDParseError

The associated error which can be returned from parsing.

impl Hash for UUID[src]

impl Marshal for UUID[src]

impl Ord for UUID[src]

impl PartialEq<UUID> for UUID[src]

impl PartialOrd<UUID> for UUID[src]

impl Signature for UUID[src]

impl TryFrom<UUID> for u16[src]

type Error = OutOfRange

The type returned in the event of a conversion error.

impl TryFrom<UUID> for u32[src]

type Error = OutOfRange

The type returned in the event of a conversion error.

impl<'buf> Unmarshal<'buf, '_> for UUID[src]

impl Copy for UUID[src]

impl Eq for UUID[src]

impl StructuralEq for UUID[src]

impl StructuralPartialEq for UUID[src]

Auto Trait Implementations

impl RefUnwindSafe for UUID

impl Send for UUID

impl Sync for UUID

impl Unpin for UUID

impl UnwindSafe for UUID

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.