Struct playwright::api::browser_context::BrowserContext [−][src]
Implementations
impl BrowserContext
[src]
pub fn pages(&self) -> Result<Vec<Page>, Error>
[src]
pub fn browser(&self) -> Result<Option<Browser>, Error>
[src]
pub async fn new_page(&self) -> Result<Page, Arc<Error>>
[src]
pub async fn set_default_navigation_timeout(
&self,
timeout: u32
) -> Result<(), Arc<Error>>
[src]
&self,
timeout: u32
) -> Result<(), Arc<Error>>
pub async fn set_default_timeout(&self, timeout: u32) -> Result<(), Arc<Error>>
[src]
pub async fn cookies(&self, urls: &[String]) -> Result<Vec<Cookie>, Arc<Error>>
[src]
pub async fn add_cookies(&self, cookies: &[Cookie]) -> Result<(), Arc<Error>>
[src]
pub async fn clear_cookies(&self) -> Result<(), Arc<Error>>
[src]
pub async fn grant_permission(
&self,
permissions: &[String],
origin: Option<&str>
) -> Result<(), Arc<Error>>
[src]
&self,
permissions: &[String],
origin: Option<&str>
) -> Result<(), Arc<Error>>
pub async fn clear_permissions(&self) -> Result<(), Arc<Error>>
[src]
pub async fn set_geolocation(
&self,
geolocation: Option<&Geolocation>
) -> Result<(), Arc<Error>>
[src]
&self,
geolocation: Option<&Geolocation>
) -> Result<(), Arc<Error>>
pub async fn set_offline(&self, offline: bool) -> Result<(), Arc<Error>>
[src]
pub async fn add_init_script(&self, script: &str) -> Result<(), Arc<Error>>
[src]
pub async fn set_extra_http_headers<T>(
&self,
headers: T
) -> Result<(), Arc<Error>> where
T: IntoIterator<Item = (String, String)>,
[src]
&self,
headers: T
) -> Result<(), Arc<Error>> where
T: IntoIterator<Item = (String, String)>,
pub async fn expect_event(&self, evt: EventType) -> Result<Event, Error>
[src]
pub async fn storage_state(&self) -> Result<StorageState, Arc<Error>>
[src]
pub async fn close(&self) -> Result<(), Arc<Error>>
[src]
All temporary browsers will be closed when the connection is terminated, but this struct has no Drop. it needs to be called explicitly to close it at any given time.
pub async fn pause(&self) -> Result<(), Arc<Error>>
[src]
Auto Trait Implementations
impl !RefUnwindSafe for BrowserContext
impl Send for BrowserContext
impl Sync for BrowserContext
impl Unpin for BrowserContext
impl !UnwindSafe for BrowserContext
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut Tⓘ
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,