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. 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§
Source§impl EmulateNetworkConditionsByRuleParams
impl EmulateNetworkConditionsByRuleParams
pub fn new( offline: impl Into<bool>, matched_network_conditions: Vec<NetworkConditions>, ) -> EmulateNetworkConditionsByRuleParams
Source§impl EmulateNetworkConditionsByRuleParams
impl EmulateNetworkConditionsByRuleParams
pub const IDENTIFIER: &'static str = "Network.emulateNetworkConditionsByRule"
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<EmulateNetworkConditionsByRuleParams, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<EmulateNetworkConditionsByRuleParams, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Method for EmulateNetworkConditionsByRuleParams
impl Method for EmulateNetworkConditionsByRuleParams
Source§fn identifier(&self) -> Cow<'static, str>
fn identifier(&self) -> Cow<'static, str>
The whole string identifier for this method like:
DOM.removeNodeSource§fn domain_name(&self) -> Cow<'static, str>
fn domain_name(&self) -> Cow<'static, str>
The name of the domain this method belongs to:
DOMSource§fn method_name(&self) -> Cow<'static, str>
fn method_name(&self) -> Cow<'static, str>
The standalone identifier of the method inside the domain:
removeNodeSource§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 ==.Source§impl Serialize for EmulateNetworkConditionsByRuleParams
impl Serialize for EmulateNetworkConditionsByRuleParams
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
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 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