Struct
UserPresenceOptions
pub struct UserPresenceOptions {
pub security_key_index: Option<usize>,
pub authentication: bool,
pub rp_id: Option<String>,
pub rp_name: Option<String>,
pub user_name: Option<String>,
pub user_display_name: Option<String>,
}Expand description
Options for the User Presence navigation request.
ⓘ
let options = UserPresenceOptions::authentication(Some(0)).with_rp_id("foundation.xyz".to_string());Fields
security_key_index: Option<usize>The security key index to use, or None to allow the user to select one.
authentication: boolrp_id: Option<String>rp_name: Option<String>user_name: Option<String>user_display_name: Option<String>Implementations
impl UserPresenceOptions
impl UserPresenceOptions
pub fn registration(security_key_index: Option<usize>) -> Self
pub fn authentication(security_key_index: Option<usize>) -> Self
pub fn with_rp_id(self, rp_id: String) -> Self
pub fn with_rp_name(self, rp_name: String) -> Self
pub fn with_user_name(self, user_name: String) -> Self
pub fn with_user_display_name(self, user_display_name: String) -> Self
pub fn from_slice(data: &[u8]) -> Option<Self>
pub fn serialize(&self) -> Vec<u8> ⓘ
Trait Implementations
impl Archive for UserPresenceOptionswhere
Option<usize>: Archive,
bool: Archive,
Option<String>: Archive,
impl Archive for UserPresenceOptionswhere
Option<usize>: Archive,
bool: Archive,
Option<String>: Archive,
const COPY_OPTIMIZATION: CopyOptimization<Self>
const COPY_OPTIMIZATION: CopyOptimization<Self>
An optimization flag that allows the bytes of this type to be copied
directly to a writer instead of calling
serialize. Read moretype Archived = ArchivedUserPresenceOptions
type Archived = ArchivedUserPresenceOptions
The archived representation of this type. Read more
type Resolver = UserPresenceOptionsResolver
type Resolver = UserPresenceOptionsResolver
The resolver for this type. It must contain all the additional
information from serializing needed to make the archived type from
the normal type.
impl Clone for UserPresenceOptions
impl Clone for UserPresenceOptions
fn clone(&self) -> UserPresenceOptions
fn clone(&self) -> UserPresenceOptions
Returns a duplicate of the value. Read more
1.0.0fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Debug for UserPresenceOptions
impl Debug for UserPresenceOptions
impl<__D: Fallible + ?Sized> Deserialize<UserPresenceOptions, __D> for Archived<UserPresenceOptions>where
Option<usize>: Archive,
<Option<usize> as Archive>::Archived: Deserialize<Option<usize>, __D>,
bool: Archive,
<bool as Archive>::Archived: Deserialize<bool, __D>,
Option<String>: Archive,
<Option<String> as Archive>::Archived: Deserialize<Option<String>, __D>,
impl<__D: Fallible + ?Sized> Deserialize<UserPresenceOptions, __D> for Archived<UserPresenceOptions>where
Option<usize>: Archive,
<Option<usize> as Archive>::Archived: Deserialize<Option<usize>, __D>,
bool: Archive,
<bool as Archive>::Archived: Deserialize<bool, __D>,
Option<String>: Archive,
<Option<String> as Archive>::Archived: Deserialize<Option<String>, __D>,
fn deserialize(
&self,
deserializer: &mut __D,
) -> Result<UserPresenceOptions, <__D as Fallible>::Error>
fn deserialize( &self, deserializer: &mut __D, ) -> Result<UserPresenceOptions, <__D as Fallible>::Error>
Deserializes using the given deserializer
impl<__S: Fallible + ?Sized> Serialize<__S> for UserPresenceOptionswhere
Option<usize>: Serialize<__S>,
bool: Serialize<__S>,
Option<String>: Serialize<__S>,
impl<__S: Fallible + ?Sized> Serialize<__S> for UserPresenceOptionswhere
Option<usize>: Serialize<__S>,
bool: Serialize<__S>,
Option<String>: Serialize<__S>,
fn serialize(
&self,
serializer: &mut __S,
) -> Result<<Self as Archive>::Resolver, <__S as Fallible>::Error>
fn serialize( &self, serializer: &mut __S, ) -> Result<<Self as Archive>::Resolver, <__S as Fallible>::Error>
Writes the dependencies for the object and returns a resolver that can
create the archived type.