Sha256: 7859738ff992117f760670a8d834488c0672fa85fe8425f7200bf289d7c5cd51

Contents?: true

Size: 874 Bytes

Versions: 17

Compression:

Stored size: 874 Bytes

Contents

# frozen_string_literal: true

# = Public Suffix
#
# Domain name parser based on the Public Suffix List.
#
# Copyright (c) 2009-2019 Simone Carletti <weppos@weppos.net>

module PublicSuffix

  class Error < StandardError
  end

  # Raised when trying to parse an invalid name.
  # A name is considered invalid when no rule is found in the definition list.
  #
  # @example
  #
  #   PublicSuffix.parse("nic.test")
  #   # => PublicSuffix::DomainInvalid
  #
  #   PublicSuffix.parse("http://www.nic.it")
  #   # => PublicSuffix::DomainInvalid
  #
  class DomainInvalid < Error
  end

  # Raised when trying to parse a name that matches a suffix.
  #
  # @example
  #
  #   PublicSuffix.parse("nic.do")
  #   # => PublicSuffix::DomainNotAllowed
  #
  #   PublicSuffix.parse("www.nic.do")
  #   # => PublicSuffix::Domain
  #
  class DomainNotAllowed < DomainInvalid
  end

end

Version data entries

17 entries across 16 versions & 6 rubygems

Version Path
tdiary-5.1.2 vendor/bundle/ruby/2.6.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
tdiary-5.1.1 vendor/bundle/ruby/2.6.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
vagrant-unbundled-2.2.7.0 vendor/bundle/ruby/2.6.0/gems/public_suffix-3.1.0/lib/public_suffix/errors.rb
vagrant-unbundled-2.2.7.0 vendor/bundle/ruby/2.7.0/gems/public_suffix-3.1.0/lib/public_suffix/errors.rb
public_suffix-4.0.2 lib/public_suffix/errors.rb
honeybadger-4.5.3 vendor/bundle/ruby/2.6.0/gems/public_suffix-3.1.0/lib/public_suffix/errors.rb
tdiary-5.1.0 vendor/bundle/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
vagrant-unbundled-2.2.6.2 vendor/bundle/ruby/2.6.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
chatops-rpc-0.0.2 fixtures/chatops-controller-example/vendor/bundle/ruby/2.5.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
chatops-rpc-0.0.1 fixtures/chatops-controller-example/vendor/bundle/ruby/2.5.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
vagrant-unbundled-2.2.6.1 vendor/bundle/ruby/2.6.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
vagrant-unbundled-2.2.6.0 vendor/bundle/ruby/2.6.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
cloudsmith-api-0.44.4 vendor/bundle/ruby/2.3.0/gems/public_suffix-4.0.1/lib/public_suffix/errors.rb
public_suffix-4.0.1 lib/public_suffix/errors.rb
public_suffix-4.0.0 lib/public_suffix/errors.rb
public_suffix-3.1.1 lib/public_suffix/errors.rb
public_suffix-3.1.0 lib/public_suffix/errors.rb