[][src]Struct adblock::filters::network::NetworkFilter

pub struct NetworkFilter {
    pub mask: NetworkFilterMask,
    pub filter: FilterPart,
    pub opt_domains: Option<Vec<Hash>>,
    pub opt_not_domains: Option<Vec<Hash>>,
    pub redirect: Option<String>,
    pub hostname: Option<String>,
    pub csp: Option<String>,
    pub bug: Option<u32>,
    pub tag: Option<String>,
    pub raw_line: Option<String>,
    pub id: Hash,
    pub fuzzy_signature: Option<Vec<Hash>>,
    pub opt_domains_union: Option<Hash>,
    pub opt_not_domains_union: Option<Hash>,
    // some fields omitted
}

Fields

mask: NetworkFilterMaskfilter: FilterPartopt_domains: Option<Vec<Hash>>opt_not_domains: Option<Vec<Hash>>redirect: Option<String>hostname: Option<String>csp: Option<String>bug: Option<u32>tag: Option<String>raw_line: Option<String>id: Hashfuzzy_signature: Option<Vec<Hash>>opt_domains_union: Option<Hash>opt_not_domains_union: Option<Hash>

Methods

impl NetworkFilter[src]

pub fn parse(line: &str, debug: bool) -> Result<NetworkFilter, FilterError>[src]

pub fn to_string(&self) -> String[src]

pub fn get_id_without_badfilter(&self) -> Hash[src]

pub fn get_id(&self) -> Hash[src]

pub fn get_fuzzy_signature(&mut self) -> &Vec<Hash>[src]

pub fn get_tokens(&self) -> Vec<Vec<Hash>>[src]

pub fn is_fuzzy(&self) -> bool[src]

pub fn is_exception(&self) -> bool[src]

pub fn is_hostname_anchor(&self) -> bool[src]

pub fn is_right_anchor(&self) -> bool[src]

pub fn is_left_anchor(&self) -> bool[src]

pub fn is_important(&self) -> bool[src]

pub fn is_redirect(&self) -> bool[src]

pub fn is_explicit_cancel(&self) -> bool[src]

pub fn is_badfilter(&self) -> bool[src]

pub fn is_regex(&self) -> bool[src]

pub fn is_complete_regex(&self) -> bool[src]

pub fn is_csp(&self) -> bool[src]

pub fn has_bug(&self) -> bool[src]

Trait Implementations

impl NetworkMatchable for NetworkFilter[src]

impl Clone for NetworkFilter[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for NetworkFilter[src]

impl Serialize for NetworkFilter[src]

impl<'de> Deserialize<'de> for NetworkFilter[src]

Auto Trait Implementations

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]