Sha256: 31e3406dd19f113e2e4fc9356b2fe1d4fc3a39e641e2d16a213edcb8974dd800

Contents?: true

Size: 793 Bytes

Versions: 2

Compression:

Stored size: 793 Bytes

Contents

#--
# Ruby Whois
#
# An intelligent pure Ruby WHOIS client and parser.
#
# Copyright (c) 2009-2018 Simone Carletti <weppos@weppos.net>
#++


require_relative 'base'


module Whois
  class Parsers

    # The Blank parser isn't a real parser. It's just a fake parser
    # that acts as a parser but doesn't provide any special capability.
    #
    # It doesn't register itself in the parser_registry,
    # it doesn't scan any string, it only exists to be initialized
    # in case a record needs to create a parser for a WHOIS server
    # not yet supported.
    #
    class Blank < Base

      Parser::PROPERTIES.each do |method|
        define_method(method) do
          raise ParserNotFound, "Unable to find a parser for the server `#{part.host}'"
        end
      end

    end

  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
whois-parser-1.2.0 lib/whois/parsers/blank.rb
whois-parser-1.1.0 lib/whois/parsers/blank.rb