pub struct AdvertisingParameters {
pub data: Option<AdvertisingData>,
pub scan_response: Option<AdvertisingData>,
pub mode_hint: Option<AdvertisingModeHint>,
pub connectable: Option<bool>,
pub connection_options: Option<ConnectionOptions>,
pub advertising_procedure: Option<AdvertisingProcedure>,
pub address_type: Option<AddressType>,
/* private fields */
}
Expand description
Represents the parameters for configuring advertisements.
Fields§
§data: Option<AdvertisingData>
The fields that will be encoded in the data section of advertising packets.
This field is required.
scan_response: Option<AdvertisingData>
The fields that are to be sent in a scan response packet. Clients may use this to send additional data that does not fit inside an advertising packet on platforms that do not support the advertising data length extensions.
If present advertisements will be configured to be scannable.
mode_hint: Option<AdvertisingModeHint>
The desired advertising frequency. See [fuchsia.bluetooth.le/AdvertisingModeHint
].
Defaults to [fuchsia.bluetooth.le/AdvertisingModeHint.SLOW
] if not present.
connectable: Option<bool>
If present and true then the controller will broadcast connectable advertisements which allows remote LE centrals to initiate a connection to the Peripheral. If false or otherwise not present then the advertisements will be non-connectable.
connection_options: Option<ConnectionOptions>
If present, the controller will broadcast connectable advertisements
which allow peers to initiate connections to the Peripheral. The fields
of ConnectionOptions
will configure any connections set up from
advertising.
advertising_procedure: Option<AdvertisingProcedure>
Specifies the advertising type to use (e.g. legacy, extended, etc).
If not present, we default to legacy advertising to maintain optimal compatibility with pre-Bluetooth 5.0 devices. See field descriptions within AdvertisingProcedure for more information.
address_type: Option<AddressType>
If privacy is not enabled, the address type will always be public.
If privacy is enabled and the client is not privileged, the address will be a random private address (either resolvable or non-resolvable). A non-privileged client requesting a public address will return an error.
If privacy is enabled and the client is privileged, they may request any address type, or will default to a random private address.
If this field is unset, the address type will be public or random depending on if privacy is enabled in the system.
Trait Implementations§
Source§impl Clone for AdvertisingParameters
impl Clone for AdvertisingParameters
Source§fn clone(&self) -> AdvertisingParameters
fn clone(&self) -> AdvertisingParameters
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for AdvertisingParameters
impl Debug for AdvertisingParameters
Source§impl<D: ResourceDialect> Decode<AdvertisingParameters, D> for AdvertisingParameters
impl<D: ResourceDialect> Decode<AdvertisingParameters, D> for AdvertisingParameters
Source§impl Default for AdvertisingParameters
impl Default for AdvertisingParameters
Source§fn default() -> AdvertisingParameters
fn default() -> AdvertisingParameters
Source§impl<D: ResourceDialect> Encode<AdvertisingParameters, D> for &AdvertisingParameters
impl<D: ResourceDialect> Encode<AdvertisingParameters, D> for &AdvertisingParameters
Source§impl PartialEq for AdvertisingParameters
impl PartialEq for AdvertisingParameters
Source§impl TypeMarker for AdvertisingParameters
impl TypeMarker for AdvertisingParameters
Source§type Owned = AdvertisingParameters
type Owned = AdvertisingParameters
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 AdvertisingParameters
impl ValueTypeMarker for AdvertisingParameters
Source§type Borrowed<'a> = &'a AdvertisingParameters
type Borrowed<'a> = &'a AdvertisingParameters
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read moreimpl Persistable for AdvertisingParameters
impl StructuralPartialEq for AdvertisingParameters
Auto Trait Implementations§
impl Freeze for AdvertisingParameters
impl RefUnwindSafe for AdvertisingParameters
impl Send for AdvertisingParameters
impl Sync for AdvertisingParameters
impl Unpin for AdvertisingParameters
impl UnwindSafe for AdvertisingParameters
Blanket Implementations§
§impl<T> Body for Twhere
T: Persistable,
impl<T> Body for Twhere
T: Persistable,
§type MarkerAtTopLevel = T
type MarkerAtTopLevel = T
§type MarkerInResultUnion = T
type MarkerInResultUnion = T
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)