Module: Faraday

Extended by:
AutoloadHelper
Defined in:
lib/faraday.rb,
lib/faraday/error.rb,
lib/faraday/utils.rb,
lib/faraday/adapter.rb,
lib/faraday/request.rb,
lib/faraday/builder.rb,
lib/faraday/response.rb,
lib/faraday/upload_io.rb,
lib/faraday/middleware.rb,
lib/faraday/connection.rb,
lib/faraday/adapter/test.rb,
lib/faraday/request/json.rb,
lib/faraday/adapter/excon.rb,
lib/faraday/adapter/patron.rb,
lib/faraday/response/logger.rb,
lib/faraday/adapter/typhoeus.rb,
lib/faraday/adapter/net_http.rb,
lib/faraday/request/multipart.rb,
lib/faraday/request/url_encoded.rb,
lib/faraday/response/raise_error.rb,
lib/faraday/adapter/em_synchrony.rb,
lib/faraday/adapter/action_dispatch.rb

Defined Under Namespace

Modules: AutoloadHelper, Error, Utils Classes: Adapter, Builder, CompositeReadIO, Connection, Middleware, Request, Response

Constant Summary

VERSION =
"0.7.0"
UploadIO =
::UploadIO
Parts =
::Parts

Class Attribute Summary collapse

Class Method Summary collapse

Methods included from AutoloadHelper

all_loaded_constants, autoload_all, load_autoloaded_constants, lookup_module, register_lookup_modules

Class Attribute Details

.default_adapterObject

Returns the value of attribute default_adapter



5
6
7
# File 'lib/faraday.rb', line 5

def default_adapter
  @default_adapter
end

.default_connectionObject



21
22
23
# File 'lib/faraday.rb', line 21

def self.default_connection
  @default_connection ||= Connection.new
end

Class Method Details

.new(url = nil, options = {}) ⇒ Object



8
9
10
11
# File 'lib/faraday.rb', line 8

def new(url = nil, options = {})
  block = block_given? ? Proc.new : nil
  Faraday::Connection.new(url, options, &block)
end