Class: DomainSanity::Name::Normalized
- Inherits:
-
Struct
- Object
- Struct
- DomainSanity::Name::Normalized
- Defined in:
- lib/domain_sanity/name.rb
Overview
The one-pass normalized view of a subject. kind is always set; the
remaining fields are populated only for the :hostname kind (the other
kinds fail fast with a single reason and need no structural analysis).
input - the original string (or nil)
name - input with a single trailing "root" dot removed
ascii - punycode form of name, or nil if unconvertible
unicode - Unicode form of name (falls back to name)
labels - ascii split on ".", preserving empty edge labels
psl - PublicSuffix::Domain, or nil if not registrable
Instance Attribute Summary collapse
-
#ascii ⇒ Object
Returns the value of attribute ascii.
-
#input ⇒ Object
Returns the value of attribute input.
-
#kind ⇒ Object
Returns the value of attribute kind.
-
#labels ⇒ Object
Returns the value of attribute labels.
-
#name ⇒ Object
Returns the value of attribute name.
-
#psl ⇒ Object
Returns the value of attribute psl.
-
#unicode ⇒ Object
Returns the value of attribute unicode.
Instance Attribute Details
#ascii ⇒ Object
Returns the value of attribute ascii
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def ascii @ascii end |
#input ⇒ Object
Returns the value of attribute input
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def input @input end |
#kind ⇒ Object
Returns the value of attribute kind
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def kind @kind end |
#labels ⇒ Object
Returns the value of attribute labels
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def labels @labels end |
#name ⇒ Object
Returns the value of attribute name
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def name @name end |
#psl ⇒ Object
Returns the value of attribute psl
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def psl @psl end |
#unicode ⇒ Object
Returns the value of attribute unicode
65 66 67 |
# File 'lib/domain_sanity/name.rb', line 65 def unicode @unicode end |