pub struct UserAgentMetadataBuilder { /* private fields */ }Expand description
Builder for UserAgentMetadata.
Implementations§
Source§impl UserAgentMetadataBuilder
impl UserAgentMetadataBuilder
Sourcepub fn brands<VALUE: Into<Vec<UserAgentBrandVersion>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn brands<VALUE: Into<Vec<UserAgentBrandVersion>>>( &mut self, value: VALUE, ) -> &mut Self
Brands appearing in Sec-CH-UA.
Sourcepub fn full_version_list<VALUE: Into<Vec<UserAgentBrandVersion>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn full_version_list<VALUE: Into<Vec<UserAgentBrandVersion>>>( &mut self, value: VALUE, ) -> &mut Self
Brands appearing in Sec-CH-UA-Full-Version-List.
pub fn full_version<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn platform<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn platform_version<VALUE: Into<String>>( &mut self, value: VALUE, ) -> &mut Self
pub fn architecture<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn model<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn mobile<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn bitness<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn wow_64<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Sourcepub fn form_factors<VALUE: Into<Vec<String>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn form_factors<VALUE: Into<Vec<String>>>( &mut self, value: VALUE, ) -> &mut Self
Used to specify User Agent form-factor values. See https://wicg.github.io/ua-client-hints/#sec-ch-ua-form-factors
Sourcepub fn build(&self) -> Result<UserAgentMetadata, UserAgentMetadataBuilderError>
pub fn build(&self) -> Result<UserAgentMetadata, UserAgentMetadataBuilderError>
Trait Implementations§
Source§impl Clone for UserAgentMetadataBuilder
impl Clone for UserAgentMetadataBuilder
Source§fn clone(&self) -> UserAgentMetadataBuilder
fn clone(&self) -> UserAgentMetadataBuilder
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for UserAgentMetadataBuilder
impl RefUnwindSafe for UserAgentMetadataBuilder
impl Send for UserAgentMetadataBuilder
impl Sync for UserAgentMetadataBuilder
impl Unpin for UserAgentMetadataBuilder
impl UnsafeUnpin for UserAgentMetadataBuilder
impl UnwindSafe for UserAgentMetadataBuilder
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