File: RR.rb [dnsruby-1.58.0 Documentation]

Last Modified
  2015-08-10 17:41:22 +0000
Requires
  - dnsruby/code_mappers

## Description

Superclass for all Dnsruby resource records.

Represents a DNS RR (resource record) [RFC1035, section 3.2]

Use Dnsruby::RR::create(...) to create a new RR record.

    mx = Dnsruby::RR.create("example.com. 7200 MX 10 mailhost.example.com.")

    rr = Dnsruby::RR.create({:name => "example.com", :type => "MX", :ttl => 7200,
                                   :preference => 10, :exchange => "mailhost.example.com"})

    s = rr.to_s # Get a String representation of the RR (in zone file format)
    rr_again = Dnsruby::RR.create(s)