Class: DNS::ResourceRecord::IN::NS

Inherits:
Data
  • Object
show all
Defined in:
lib/faildns/resourcerecord/IN/NS.rb

Overview

+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
/                   NSDNAME                     /
/                                               /
+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+

where:

NSDNAME A <domain-name> which specifies a host which should be

authoritative for the specified class and domain.

NS records cause both the usual additional section processing to locate a type A record, and, when used in a referral, a special search of the zone in which they reside for glue information.

The NS RR states that the named host should be expected to have a zone starting at owner name of the specified class. Note that the class may not indicate the protocol family which should be used to communicate with the host, although it is typically a strong hint. For example, hosts which are name servers for either Internet (IN) or Hesiod (HS) class information are normally queried using IN class protocols. ++

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Data

parse

Constructor Details

#initialize(domain) ⇒ NS

Returns a new instance of NS.



60
61
62
# File 'lib/faildns/resourcerecord/IN/NS.rb', line 60

def initialize (domain)
  @domain = domain
end

Instance Attribute Details

#domainObject (readonly)

Returns the value of attribute domain.



58
59
60
# File 'lib/faildns/resourcerecord/IN/NS.rb', line 58

def domain
  @domain
end

Class Method Details

._parse(string, original) ⇒ Object



54
55
56
# File 'lib/faildns/resourcerecord/IN/NS.rb', line 54

def self._parse (string, original)
  NS.new(DomainName.parse(string.clone, original))
end

Instance Method Details

#packObject



64
65
66
# File 'lib/faildns/resourcerecord/IN/NS.rb', line 64

def pack
  @domain.pack
end

#to_sObject



68
69
70
# File 'lib/faildns/resourcerecord/IN/NS.rb', line 68

def to_s
  @domain.to_s
end