Sha256: ed0f060425d0e3b9e84263760f158c024e38558b9f22fc5a6f1c6459b270facf

Contents?: true

Size: 1.38 KB

Versions: 16

Compression:

Stored size: 1.38 KB

Contents

module HTTPX
  type ipaddr = IPAddr | String

  module Resolver
    RESOLVE_TIMEOUT: Array[Integer]

    @lookup_mutex: Thread::Mutex

    type dns_resource = singleton(Resolv::DNS::Resource)

    type dns_result = { "name" => String, "TTL" => Numeric, "alias" => String }
                    | { "name" => String, "TTL" => Numeric, "data" => String }

    type dns_decoding_response = [:ok, Array[dns_result]] | [:decode_error, Resolv::DNS::DecodeError] | [:dns_error, Integer] | Symbol

    def nolookup_resolve: (String hostname) -> Array[IPAddr]

    def ip_resolve: (String hostname) -> Array[IPAddr]?

    def system_resolve: (String hostname) -> Array[IPAddr]?

    def self?.resolver_for: (:native resolver_type) -> singleton(Native) |
                            (:system resolver_type) -> singleton(System) |
                            (:https resolver_type) -> singleton(HTTPS) |
                            [U] (U resolver_type) -> U

    def self?.cached_lookup: (String hostname) -> Array[IPAddr]?

    def self?.cached_lookup_set: (String hostname, ip_family family, Array[dns_result] addresses) -> void

    def self?.lookup: (String hostname, Numeric ttl) -> Array[IPAddr]?

    def self?.generate_id: () -> Integer

    def self?.encode_dns_query: (String hostname, ?type: dns_resource, ?message_id: Integer) -> String

    def self?.decode_dns_answer: (String) -> dns_decoding_response
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
httpx-1.3.4 sig/resolver.rbs
httpx-1.3.3 sig/resolver.rbs
httpx-1.3.2 sig/resolver.rbs
httpx-1.3.1 sig/resolver.rbs
httpx-1.3.0 sig/resolver.rbs
httpx-1.2.6 sig/resolver.rbs
httpx-1.2.4 sig/resolver.rbs
httpx-1.2.3 sig/resolver.rbs
httpx-1.2.2 sig/resolver.rbs
httpx-1.2.1 sig/resolver.rbs
httpx-1.2.0 sig/resolver.rbs
httpx-1.1.5 sig/resolver.rbs
httpx-1.1.4 sig/resolver.rbs
httpx-1.1.3 sig/resolver.rbs
httpx-1.1.2 sig/resolver.rbs
httpx-1.1.1 sig/resolver.rbs