Sha256: 6a26ccc3475c5c108edbe438f533746fee16b1d49305d51a6cf9f3dd6cb17280

Contents?: true

Size: 564 Bytes

Versions: 6

Compression:

Stored size: 564 Bytes

Contents

# frozen_string_literal: true

require 'excon'
class TyphoeusAdapter < HTTPBaseAdapter
  def send_get_request
    Typhoeus.get(parse_uri.to_s, headers: @headers)
  end

  def send_head_request
    Typhoeus.head(parse_uri.to_s, headers: @headers)
  end

  def send_post_request
    Typhoeus.post(parse_uri.to_s, body: @data, headers: @headers)
  end

  def send_post_form_request
    Typhoeus.post(parse_uri.to_s, body: @params, headers: @headers)
  end

  def send_multipart_post_request
    send_post_form_request
  end

  def self.is_libcurl?
    true
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
httplog-1.2.2 spec/adapters/typhoeus_adapter.rb
httplog-1.2.1 spec/adapters/typhoeus_adapter.rb
httplog-1.2.0 spec/adapters/typhoeus_adapter.rb
httplog-1.1.1 spec/adapters/typhoeus_adapter.rb
httplog-1.1.0 spec/adapters/typhoeus_adapter.rb
httplog-1.0.3 spec/adapters/typhoeus_adapter.rb