Sha256: e37695c5d39862de6b2f4a520975f2b3b56d05a16c7374478b1a2697ca3ef21f

Contents?: true

Size: 874 Bytes

Versions: 40

Compression:

Stored size: 874 Bytes

Contents

# frozen_string_literal: true

# = Public Suffix
#
# Domain name parser based on the Public Suffix List.
#
# Copyright (c) 2009-2022 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

40 entries across 40 versions & 7 rubygems

Version Path
cloudsmith-api-2.0.7 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.6 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.5 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.4 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.3 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.2 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
fluent-plugin-google-cloud-logging-on-prem-0.1.0 vendor/ruby/3.1.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
postfinancecheckout-ruby-sdk-3.3.0 vendor/bundle/ruby/2.7.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
wallee-ruby-sdk-3.3.0 vendor/bundle/ruby/2.7.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.1 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
cloudsmith-api-2.0.0 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.1/lib/public_suffix/errors.rb
public_suffix-5.0.1 lib/public_suffix/errors.rb
tdiary-5.2.4 vendor/bundle/ruby/3.1.0/gems/public_suffix-5.0.0/lib/public_suffix/errors.rb
whitelabelmachinename-ruby-sdk-3.2.1 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/lib/public_suffix/errors.rb
wallee-ruby-sdk-3.2.0 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/lib/public_suffix/errors.rb
postfinancecheckout-ruby-sdk-3.2.0 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/lib/public_suffix/errors.rb
cloudsmith-api-1.142.3 vendor/bundle/ruby/2.6.0/gems/public_suffix-5.0.0/lib/public_suffix/errors.rb
wallee-ruby-sdk-3.1.5 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/lib/public_suffix/errors.rb
postfinancecheckout-ruby-sdk-3.1.5 vendor/bundle/ruby/2.4.0/gems/public_suffix-4.0.7/lib/public_suffix/errors.rb
tdiary-5.2.3 vendor/bundle/ruby/3.1.0/gems/public_suffix-5.0.0/lib/public_suffix/errors.rb