Parent

Included Modules

Class Index [+]

Quicksearch

Dnsruby::Name::Label

Dnsruby::Label class

(RFC1035, section 3.1)

Constants

MaxLabelLength

Attributes

string[R]
downcase[R]

Public Class Methods

new(string) click to toggle source
     # File lib/Dnsruby/name.rb, line 380
380:       def initialize(string)
381:         if (string.length > @@max_length)
382:           raise ResolvError.new("Label too long (#{string.length}, max length=#{MaxLabelLength}). Label = #{string}")
383:         end
384:         @downcase = string.downcase
385:         @string = string
386:         @string_length = string.length
387:       end
set_max_length(l) click to toggle source
     # File lib/Dnsruby/name.rb, line 376
376:       def self.set_max_length(l)
377:         @@max_length=l
378:       end
split(arg) click to toggle source

Split a Name into its component Labels

     # File lib/Dnsruby/name.rb, line 372
372:       def self.split(arg)
373:         return Name.split(arg)
374:       end

Public Instance Methods

<=>(other) click to toggle source
     # File lib/Dnsruby/name.rb, line 402
402:       def <=>(other)
403:         return (@downcase <=> other.downcase)
404:       end
==(other) click to toggle source
     # File lib/Dnsruby/name.rb, line 407
407:       def ==(other)
408:         return @downcase == other.downcase
409:       end
eql?(other) click to toggle source
     # File lib/Dnsruby/name.rb, line 411
411:       def eql?(other)
412:         return self == other
413:       end
hash() click to toggle source
     # File lib/Dnsruby/name.rb, line 415
415:       def hash
416:         return @downcase.hash
417:       end
inspect() click to toggle source
     # File lib/Dnsruby/name.rb, line 398
398:       def inspect
399:         return "#<#{self.class} #{self.to_s}>"
400:       end
length() click to toggle source
     # File lib/Dnsruby/name.rb, line 394
394:       def length
395:         return @string_length
396:       end
to_s() click to toggle source
     # File lib/Dnsruby/name.rb, line 390
390:       def to_s
391:         return @string.to_s # + "."
392:       end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.