EnvironmentBuilder

Struct EnvironmentBuilder 

Source
pub struct EnvironmentBuilder<'a> { /* private fields */ }
Expand description

A builder for calling the CreateCoreWebView2EnvironmentWithOptions function.

Use Environment::builder() to create one.

Implementations§

Source§

impl<'a> EnvironmentBuilder<'a>

Source

pub fn with_browser_executable_folder( self, browser_executable_folder: &'a Path, ) -> Self

Source

pub fn with_user_data_folder(self, user_data_folder: &'a Path) -> Self

Source

pub fn with_additional_browser_arguments( self, additional_browser_arguments: &'a str, ) -> Self

Source

pub fn with_language(self, language: &'a str) -> Self

Source

pub fn with_target_compatible_browser_version(self, version: &'a str) -> Self

Source

pub fn with_allow_single_sign_on_using_osprimary_account( self, allow: bool, ) -> Self

Source

pub fn get_available_browser_version_string(&self) -> Result<String>

Get available browser version string (within the browser_executable_folder if it is specified.)

Source

pub fn compare_browser_versions( &self, version1: &str, version2: &str, ) -> Result<Ordering>

👎Deprecated: use webview2::compare_browser_versions instead
Source

pub fn build( &self, completed: impl FnOnce(Result<Environment>) -> Result<()> + 'static, ) -> Result<()>

Trait Implementations§

Source§

impl<'a> Default for EnvironmentBuilder<'a>

Source§

fn default() -> EnvironmentBuilder<'a>

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<'a> Freeze for EnvironmentBuilder<'a>

§

impl<'a> RefUnwindSafe for EnvironmentBuilder<'a>

§

impl<'a> Send for EnvironmentBuilder<'a>

§

impl<'a> Sync for EnvironmentBuilder<'a>

§

impl<'a> Unpin for EnvironmentBuilder<'a>

§

impl<'a> UnwindSafe for EnvironmentBuilder<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.