# Resolv::DNS::Resource::IN::WKS (Class)

In: | resolv.rb
Parent: | Resource

## Methods

decode_rdata encode_rdata new

## Constants

TypeValue | = | 11, ClassValue = ClassValue]] = self

## Attributes

address | [R] |
bitmap | [R] |
protocol | [R] |

## Public Class methods

new(address, protocol, bitmap)

[Source]

    # File resolv.rb, line 1499
              def initialize(address, protocol, bitmap)
                @address = IPv4.create(address)
                @protocol = protocol
                @bitmap = bitmap
              end

decode_rdata(msg)

[Source]

    # File resolv.rb, line 1512
              def self.decode_rdata(msg)
                address = IPv4.new(msg.get_bytes(4))
                protocol, = msg.get_unpack("n")
                bitmap = msg.get_bytes
                return self.new(address, protocol, bitmap)
              end

## Public Instance methods

encode_rdata(msg)

[Source]

    # File resolv.rb, line 1506
              def encode_rdata(msg)
                msg.put_bytes(@address.address)
                msg.put_pack("n", @protocol)
                msg.put_bytes(@bitmap)
              end

[Validate]