123456789_123456789_123456789_123456789_123456789_

Class: Gem::Resolv::DNS::Resource::HINFO

Relationships & Source Files
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
Instance Chain:
Inherits: Gem::Resolv::DNS::Resource
Defined in: lib/rubygems/vendor/resolv/lib/resolv.rb

Overview

Host Information resource.

Constant Summary

::Gem::Resolv::DNS::Resource - Inherited

ClassHash, ClassInsensitiveTypes, ClassValue

Class Method Summary

::Gem::Resolv::DNS::Resource - Inherited

::Gem::Resolv::DNS::Query - Inherited

Instance Attribute Summary

  • #cpu readonly

    CPU architecture for this resource.

  • #os readonly

    Operating system for this resource.

::Gem::Resolv::DNS::Resource - Inherited

#ttl

Remaining Time To Live for this ::Gem::Resolv::DNS::Resource.

Instance Method Summary

Constructor Details

.new(cpu, os) ⇒ HINFO

Creates a new HINFO running #os on #cpu.

[ GitHub ]

  
# File 'lib/rubygems/vendor/resolv/lib/resolv.rb', line 2310

def initialize(cpu, os)
  @cpu = cpu
  @os = os
end

Class Method Details

.decode_rdata(msg)

This method is for internal use only.
[ GitHub ]

  
# File 'lib/rubygems/vendor/resolv/lib/resolv.rb', line 2330

def self.decode_rdata(msg) # :nodoc:
  cpu = msg.get_string
  os = msg.get_string
  return self.new(cpu, os)
end

Instance Attribute Details

#cpu (readonly)

CPU architecture for this resource.

[ GitHub ]

  
# File 'lib/rubygems/vendor/resolv/lib/resolv.rb', line 2318

attr_reader :cpu

#os (readonly)

Operating system for this resource.

[ GitHub ]

  
# File 'lib/rubygems/vendor/resolv/lib/resolv.rb', line 2323

attr_reader :os

Instance Method Details

#encode_rdata(msg)

This method is for internal use only.
[ GitHub ]

  
# File 'lib/rubygems/vendor/resolv/lib/resolv.rb', line 2325

def encode_rdata(msg) # :nodoc:
  msg.put_string(@cpu)
  msg.put_string(@os)
end