# File lib/dnsruby/resource/NSEC.rb, line 67 def self.get_types(t) if t.instance_of?(Array) # from the wire, already decoded types = t elsif t.instance_of?(String) if (index = t.index(/[;)]/)) # check for ; or ) t = t[0, index] end # List of mnemonics types = [] mnemonics = t.split(' ') mnemonics.each { |m| types << Types.new(m) } else raise DecodeError.new('Unknown format of types for Dnsruby::RR::NSEC') end types end