pub struct ServiceInfo {
pub handle: Option<ServiceHandle>,
pub kind: Option<ServiceKind>,
pub type_: Option<Uuid>,
pub characteristics: Option<Vec<Characteristic>>,
pub includes: Option<Vec<ServiceHandle>>,
/* private fields */
}
Expand description
Represents a local or remote GATT service.
Fields§
§handle: Option<ServiceHandle>
Unique identifier for this GATT service.
Always present if this represents a remote service, in which case this is unique across the
Client that returned this ServiceInfo.
Required for local services, in which case this must be unique across all services published
to a single Server instance. Can be used in the ServiceInfo.includes
of other
PublishService calls to the Server where this service is published.
kind: Option<ServiceKind>
Indicates whether this is a primary or secondary service. Always present for remote services. Optional for local services Default: ServiceKind::PRIMARY
type_: Option<Uuid>
The UUID that identifies the type of this service. There may be multiple services with the same UUID. Always present for remote services. Required for local services.
characteristics: Option<Vec<Characteristic>>
The characteristics of this service. Required for local services. Never present for remote services.
includes: Option<Vec<ServiceHandle>>
Handles of other services that are included by this service. Optional for local services. Never present for remote services. TODO(https://fxbug.dev/42147529): This is not currently supported for local services.
Trait Implementations§
Source§impl Clone for ServiceInfo
impl Clone for ServiceInfo
Source§fn clone(&self) -> ServiceInfo
fn clone(&self) -> ServiceInfo
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for ServiceInfo
impl Debug for ServiceInfo
Source§impl<D: ResourceDialect> Decode<ServiceInfo, D> for ServiceInfo
impl<D: ResourceDialect> Decode<ServiceInfo, D> for ServiceInfo
Source§impl Default for ServiceInfo
impl Default for ServiceInfo
Source§fn default() -> ServiceInfo
fn default() -> ServiceInfo
Source§impl<D: ResourceDialect> Encode<ServiceInfo, D> for &ServiceInfo
impl<D: ResourceDialect> Encode<ServiceInfo, D> for &ServiceInfo
Source§impl PartialEq for ServiceInfo
impl PartialEq for ServiceInfo
Source§impl TypeMarker for ServiceInfo
impl TypeMarker for ServiceInfo
Source§type Owned = ServiceInfo
type Owned = ServiceInfo
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.Source§impl ValueTypeMarker for ServiceInfo
impl ValueTypeMarker for ServiceInfo
Source§type Borrowed<'a> = &'a ServiceInfo
type Borrowed<'a> = &'a ServiceInfo
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read more