pub struct RealBrowserOptions {Show 18 fields
pub engine: EngineType,
pub channel: String,
pub executable_path: Option<PathBuf>,
pub user_data_dir: Option<PathBuf>,
pub remote_debugging_port: u16,
pub headless: bool,
pub args: Vec<String>,
pub extra_args: Vec<String>,
pub ignore_default_args: Vec<String>,
pub ignore_all_default_args: bool,
pub startup_timeout: Duration,
pub slow_mo: u64,
pub timeout: Option<Duration>,
pub protocol_timeout: Option<Duration>,
pub seed_cookies: Vec<Value>,
pub verbose: bool,
pub node_executable: Option<PathBuf>,
pub node_working_dir: Option<PathBuf>,
}Expand description
Options for launching an installed browser and attaching over CDP.
Fields§
§engine: EngineTypeBrowser Commander engine used after the browser starts.
channel: StringInstalled Chrome-family channel to discover.
executable_path: Option<PathBuf>Explicit installed-browser executable, bypassing channel discovery.
user_data_dir: Option<PathBuf>Dedicated, non-default browser profile.
remote_debugging_port: u16Loopback CDP port. Zero lets Chrome choose an available port.
headless: boolRun the installed browser headlessly.
args: Vec<String>Additional browser arguments.
extra_args: Vec<String>Additional browser arguments appended after the compatibility args.
ignore_default_args: Vec<String>Browser Commander default arguments to omit.
ignore_all_default_args: boolOmit every Browser Commander default argument.
startup_timeout: DurationMaximum time to wait for Chrome’s /json/version endpoint.
slow_mo: u64Delay Playwright/Puppeteer operations by this many milliseconds.
timeout: Option<Duration>Optional connection timeout.
protocol_timeout: Option<Duration>Optional Puppeteer timeout for individual CDP calls.
Cookies to seed immediately after attaching.
verbose: boolEnable browser and connector logging.
node_executable: Option<PathBuf>Node.js executable for Playwright/Puppeteer bridge engines.
node_working_dir: Option<PathBuf>Directory where Node resolves Playwright/Puppeteer.
Implementations§
Source§impl RealBrowserOptions
impl RealBrowserOptions
Sourcepub fn chromiumoxide() -> Self
pub fn chromiumoxide() -> Self
Create native Chromiumoxide options.
Sourcepub fn playwright() -> Self
pub fn playwright() -> Self
Create Playwright bridge options.
Sourcepub fn executable_path(self, executable_path: impl Into<PathBuf>) -> Self
pub fn executable_path(self, executable_path: impl Into<PathBuf>) -> Self
Select an explicit installed-browser executable.
Sourcepub fn user_data_dir(self, user_data_dir: impl Into<PathBuf>) -> Self
pub fn user_data_dir(self, user_data_dir: impl Into<PathBuf>) -> Self
Select a dedicated browser profile.
Sourcepub fn remote_debugging_port(self, port: u16) -> Self
pub fn remote_debugging_port(self, port: u16) -> Self
Select a loopback CDP port. Zero asks Chrome to allocate one.
Sourcepub fn with_extra_args(self, args: Vec<String>) -> Self
pub fn with_extra_args(self, args: Vec<String>) -> Self
Add browser arguments after the compatibility args field.
Sourcepub fn ignore_default_args(self, args: Vec<String>) -> Self
pub fn ignore_default_args(self, args: Vec<String>) -> Self
Omit selected Browser Commander defaults.
Sourcepub fn ignore_all_default_args(self) -> Self
pub fn ignore_all_default_args(self) -> Self
Omit every Browser Commander default argument.
Sourcepub fn startup_timeout(self, timeout: Duration) -> Self
pub fn startup_timeout(self, timeout: Duration) -> Self
Set the CDP readiness timeout.
Sourcepub fn protocol_timeout(self, timeout: Duration) -> Self
pub fn protocol_timeout(self, timeout: Duration) -> Self
Set Puppeteer’s timeout for individual CDP calls.
Seed cookies after attaching.
Sourcepub fn node_executable(self, executable: impl Into<PathBuf>) -> Self
pub fn node_executable(self, executable: impl Into<PathBuf>) -> Self
Override the Node.js executable for bridge engines.
Sourcepub fn node_working_dir(self, directory: impl Into<PathBuf>) -> Self
pub fn node_working_dir(self, directory: impl Into<PathBuf>) -> Self
Set the directory where Node resolves Playwright/Puppeteer.
Sourcepub fn get_user_data_dir(&self) -> PathBuf
pub fn get_user_data_dir(&self) -> PathBuf
Resolve the configured or managed dedicated profile path.
Trait Implementations§
Source§impl Clone for RealBrowserOptions
impl Clone for RealBrowserOptions
Source§fn clone(&self) -> RealBrowserOptions
fn clone(&self) -> RealBrowserOptions
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RealBrowserOptions
impl Debug for RealBrowserOptions
Auto Trait Implementations§
impl Freeze for RealBrowserOptions
impl RefUnwindSafe for RealBrowserOptions
impl Send for RealBrowserOptions
impl Sync for RealBrowserOptions
impl Unpin for RealBrowserOptions
impl UnsafeUnpin for RealBrowserOptions
impl UnwindSafe for RealBrowserOptions
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more