pub struct EmulateNetworkConditionsByRuleParams {
pub offline: bool,
pub matched_network_conditions: Vec<NetworkConditions>,
}Expand description
Activates emulation of network conditions for individual requests using URL match patterns. Unlike the deprecated
Network.emulateNetworkConditions this method does not affect navigator state. Use Network.overrideNetworkState to
explicitly modify navigator behavior.
emulateNetworkConditionsByRule
Fields§
§offline: boolTrue to emulate internet disconnection.
matched_network_conditions: Vec<NetworkConditions>Configure conditions for matching requests. If multiple entries match a request, the first entry wins. Global conditions can be configured by leaving the urlPattern for the conditions empty. These global conditions are also applied for throttling of p2p connections.
Implementations§
Trait Implementations§
Source§impl Clone for EmulateNetworkConditionsByRuleParams
impl Clone for EmulateNetworkConditionsByRuleParams
Source§fn clone(&self) -> EmulateNetworkConditionsByRuleParams
fn clone(&self) -> EmulateNetworkConditionsByRuleParams
Returns a duplicate 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<'de> Deserialize<'de> for EmulateNetworkConditionsByRuleParams
impl<'de> Deserialize<'de> for EmulateNetworkConditionsByRuleParams
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for EmulateNetworkConditionsByRuleParams
impl PartialEq for EmulateNetworkConditionsByRuleParams
Source§fn eq(&self, other: &EmulateNetworkConditionsByRuleParams) -> bool
fn eq(&self, other: &EmulateNetworkConditionsByRuleParams) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for EmulateNetworkConditionsByRuleParams
Auto Trait Implementations§
impl Freeze for EmulateNetworkConditionsByRuleParams
impl RefUnwindSafe for EmulateNetworkConditionsByRuleParams
impl Send for EmulateNetworkConditionsByRuleParams
impl Sync for EmulateNetworkConditionsByRuleParams
impl Unpin for EmulateNetworkConditionsByRuleParams
impl UnsafeUnpin for EmulateNetworkConditionsByRuleParams
impl UnwindSafe for EmulateNetworkConditionsByRuleParams
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