pub struct PeerService { /* private fields */ }Trait Implementations§
Source§impl PeerService<FuchsiaTypes> for PeerService
impl PeerService<FuchsiaTypes> for PeerService
Source§fn discover_characteristics(
&self,
uuid: Option<Uuid>,
) -> CharacteristicResultFut ⓘ
fn discover_characteristics( &self, uuid: Option<Uuid>, ) -> CharacteristicResultFut ⓘ
Discover characteristics on this service.
If
uuid is provided, only the characteristics matching uuid will be
returned. This operation may use either the Discovery All
Characteristics of a Service or Discovery Characteristic by UUID
procedures, regardless of uuid.Source§fn read_characteristic<'a>(
&self,
handle: &Handle,
offset: u16,
buf: &'a mut [u8],
) -> <FuchsiaTypes as GattTypes>::ReadFut<'a>
fn read_characteristic<'a>( &self, handle: &Handle, offset: u16, buf: &'a mut [u8], ) -> <FuchsiaTypes as GattTypes>::ReadFut<'a>
Read a characteristic into a buffer, given the handle within the
service. On success, returns the size read and whether the value may
have been truncated. By default this will try to use a long read if
the
buf is larger than a normal read will allow (22 bytes) or if
the offset is non-zero.fn write_characteristic<'a>( &self, handle: &Handle, mode: WriteMode, offset: u16, buf: &'a [u8], ) -> <FuchsiaTypes as GattTypes>::WriteFut<'a>
fn read_descriptor<'a>( &self, handle: &Handle, offset: u16, buf: &'a mut [u8], ) -> <FuchsiaTypes as GattTypes>::ReadFut<'a>
fn write_descriptor<'a>( &self, handle: &Handle, offset: u16, buf: &'a [u8], ) -> <FuchsiaTypes as GattTypes>::WriteFut<'a>
Source§fn subscribe(
&self,
handle: &Handle,
) -> <FuchsiaTypes as GattTypes>::NotificationStream
fn subscribe( &self, handle: &Handle, ) -> <FuchsiaTypes as GattTypes>::NotificationStream
Subscribe to updates on a Characteristic.
Either notifications or indications will be enabled depending on the
properties available, with indications preferred if they are
supported. Fails if the Characteristic doesn’t support indications
or notifications. Errors are delivered through an Err item in the
stream. This will often write to the Client Characteristic
Configuration descriptor for the Characteristic subscribed to.
Updates sent from the peer will be delivered to the Stream returned.
Auto Trait Implementations§
impl Freeze for PeerService
impl !RefUnwindSafe for PeerService
impl Send for PeerService
impl Sync for PeerService
impl Unpin for PeerService
impl UnsafeUnpin for PeerService
impl !UnwindSafe for PeerService
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
Source§impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
Source§impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more