struct PublicSuffix::Rule::Exception
- PublicSuffix::Rule::Exception
- PublicSuffix::Rule::Base
- Struct
- Value
- Object
Overview
Exception represents an exception rule (e.g. !parliament.uk).
Defined in:
public_suffix/rule.crClass Method Summary
-
.build(content, _private = false)
Initializes a new rule from the content.
Instance Method Summary
-
#decompose(domain : String) : Tuple(String | Nil, String | Nil)
Decomposes the domain name according to rule properties.
-
#parts
dot-split rule value and returns all rule parts in the order they appear in the value.
-
#rule
Gets the original rule definition.
- #tail
Instance methods inherited from struct PublicSuffix::Rule::Base
_private : Bool
_private,
decompose(domain : String) : Tuple(String | Nil, String | Nil)
decompose,
length : Int32
length,
match?(name)
match?,
parts
parts,
value : String
value
Constructor methods inherited from struct PublicSuffix::Rule::Base
new(value : String, length : Int32 | Nil = nil, _private : Bool = false)
new
Class methods inherited from struct PublicSuffix::Rule::Base
build(content, _private = false)
build
Class Method Detail
Initializes a new rule from the content.
@param content [String] the content of the rule @param private [Boolean]
Instance Method Detail
Decomposes the domain name according to rule properties.
@param [String, #to_s] name The domain name to decompose
@return [Array
dot-split rule value and returns all rule parts in the order they appear in the value. The leftmost label is not considered a label.
See http://publicsuffix.org/format/: If the prevailing rule is a exception rule, modify it by removing the leftmost label.
@return [Array