Struct adblock::lists::FilterListMetadata
source · pub struct FilterListMetadata {
pub homepage: Option<String>,
pub title: Option<String>,
pub expires: Option<ExpiresInterval>,
pub redirect: Option<String>,
}
Expand description
Includes information about any “special comments” as described by https://help.eyeo.com/adblockplus/how-to-write-filters#special-comments
Fields§
§homepage: Option<String>
! Homepage: http://example.com
- This comment determines which webpage should be linked
as filter list homepage.
title: Option<String>
! Title: FooList
- This comment sets a fixed title for the filter list. If this comment
is present, the user is no longer able to change the title.
expires: Option<ExpiresInterval>
! Expires: 5 days
- This comment sets the update interval for the filter list. The value
can be given in days (e.g. 5 days) or hours (e.g. 8 hours). Any value between 1 hour and 14
days is possible. Note that the update will not necessarily happen after this time
interval. The actual update time is slightly randomized and depends on some additional
factors to reduce server load.
redirect: Option<String>
! Redirect: http://example.com/list.txt
- This comment indicates that the filter list has
moved to a new download address. Adblock Plus ignores any file content beyond that comment
and immediately tries downloading from the new address. In case of success, the address of
the filter list is updated in the settings. This comment is ignored if the new address is
the same as the current address, meaning that it can be used to enforce the “canonical”
address of the filter list.