Struct webbrowser::BrowserOptions
source · pub struct BrowserOptions { /* private fields */ }
Expand description
BrowserOptions to override certain default behaviour. Any option named as a hint
is
not guaranteed to be honoured. Use BrowserOptions::new() to create.
e.g. by default, we suppress stdout/stderr, but that behaviour can be overridden here
Implementations§
source§impl BrowserOptions
impl BrowserOptions
sourcepub fn with_suppress_output(&mut self, suppress_output: bool) -> &mut Self
pub fn with_suppress_output(&mut self, suppress_output: bool) -> &mut Self
Determines whether stdout/stderr of the appropriate browser command is suppressed or not
sourcepub fn with_target_hint(&mut self, target_hint: &str) -> &mut Self
pub fn with_target_hint(&mut self, target_hint: &str) -> &mut Self
Hint to the browser to open the url in the corresponding target. Note that this is just a hint, it may or may not be honoured (currently guaranteed only in wasm).
sourcepub fn with_dry_run(&mut self, dry_run: bool) -> &mut Self
pub fn with_dry_run(&mut self, dry_run: bool) -> &mut Self
Do not do an actual execution, just return true if this would’ve likely succeeded. Note the “likely” here - it’s still indicative than guaranteed.
Trait Implementations§
source§impl Clone for BrowserOptions
impl Clone for BrowserOptions
source§fn clone(&self) -> BrowserOptions
fn clone(&self) -> BrowserOptions
Returns a copy 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 moresource§impl Debug for BrowserOptions
impl Debug for BrowserOptions
source§impl Default for BrowserOptions
impl Default for BrowserOptions
source§impl Display for BrowserOptions
impl Display for BrowserOptions
source§impl Hash for BrowserOptions
impl Hash for BrowserOptions
source§impl PartialEq for BrowserOptions
impl PartialEq for BrowserOptions
source§fn eq(&self, other: &BrowserOptions) -> bool
fn eq(&self, other: &BrowserOptions) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for BrowserOptions
impl StructuralPartialEq for BrowserOptions
Auto Trait Implementations§
impl Freeze for BrowserOptions
impl RefUnwindSafe for BrowserOptions
impl Send for BrowserOptions
impl Sync for BrowserOptions
impl Unpin for BrowserOptions
impl UnwindSafe for BrowserOptions
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