pub struct BrowserContext { /* private fields */ }Expand description
An isolated browser context.
Browser contexts are similar to incognito windows - they have their own cookies, cache, and storage that are isolated from other contexts.
Implementations§
Source§impl BrowserContext
impl BrowserContext
Sourcepub async fn new_page(&self) -> Result<Page, ContextError>
pub async fn new_page(&self) -> Result<Page, ContextError>
Sourcepub async fn close(&mut self) -> Result<(), ContextError>
pub async fn close(&mut self) -> Result<(), ContextError>
Sourcepub fn connection(&self) -> &Arc<CdpConnection>
pub fn connection(&self) -> &Arc<CdpConnection>
Get a reference to the CDP connection.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for BrowserContext
impl !RefUnwindSafe for BrowserContext
impl Send for BrowserContext
impl Sync for BrowserContext
impl Unpin for BrowserContext
impl !UnwindSafe for BrowserContext
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