Module: Wrest
- Defined in:
- lib/wrest/uri.rb,
lib/wrest.rb,
lib/wrest/curl.rb,
lib/wrest_no_ext.rb,
lib/wrest/native.rb,
lib/wrest/version.rb,
lib/wrest/caching.rb,
lib/wrest/callback.rb,
lib/wrest/multipart.rb,
lib/wrest/components.rb,
lib/wrest/exceptions.rb,
lib/wrest/http_codes.rb,
lib/wrest/cache_proxy.rb,
lib/wrest/http_shared.rb,
lib/wrest/uri_template.rb,
lib/wrest/uri/builders.rb,
lib/wrest/curl/request.rb,
lib/wrest/async_request.rb,
lib/wrest/curl/response.rb,
lib/wrest/native/response.rb,
lib/wrest/native/redirection.rb,
lib/wrest/components/mutators.rb,
lib/wrest/http_shared/headers.rb,
lib/wrest/components/container.rb,
lib/wrest/components/translators.rb,
lib/wrest/components/mutators/base.rb,
lib/wrest/core_ext/hash/conversions.rb,
lib/wrest/components/translators/xml.rb,
lib/wrest/core_ext/string/conversions.rb,
lib/wrest/http_shared/standard_tokens.rb,
lib/wrest/components/translators/json.rb,
lib/wrest/http_shared/standard_headers.rb,
lib/wrest/async_request/thread_backend.rb,
lib/wrest/components/container/typecaster.rb,
lib/wrest/hash_with_case_insensitive_access.rb,
lib/wrest/async_request/event_machine_backend.rb,
lib/wrest/components/container/alias_accessors.rb,
lib/wrest/components/translators/content_types.rb,
lib/wrest/components/mutators/camel_to_snake_case.rb,
lib/wrest/components/mutators/xml_mini_type_caster.rb,
lib/wrest/components/mutators/xml_simple_type_caster.rb
Overview
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Defined Under Namespace
Modules: AsyncRequest, Caching, Components, CoreExt, Curl, Exceptions, HttpCodes, HttpShared, Multipart, Native Classes: CacheProxy, Callback, HashWithCaseInsensitiveAccess, Uri, UriTemplate
Constant Summary
- Root =
File.dirname(__FILE__)
- NoStringExtensions =
true- VERSION =
"1.4.3"
Class Method Summary (collapse)
- + (Object) enable_evented_requests!
- + (Object) logger
- + (Object) logger=(logger)
-
+ (Object) use_curl!
Switch Wrest to using libcurl.
-
+ (Object) use_native!
Switch Wrest to using Net::HTTP.
Class Method Details
+ (Object) enable_evented_requests!
39 40 41 |
# File 'lib/wrest.rb', line 39 def self.enable_evented_requests! require "#{Wrest::Root}/wrest/event_machine_backend" end |
+ (Object) logger
35 36 37 |
# File 'lib/wrest.rb', line 35 def self.logger @logger end |
+ (Object) logger=(logger)
31 32 33 |
# File 'lib/wrest.rb', line 31 def self.logger=(logger) @logger = logger end |
+ (Object) use_curl!
Switch Wrest to using libcurl.
49 50 51 52 |
# File 'lib/wrest.rb', line 49 def self.use_curl! require "#{Wrest::Root}/wrest/curl" silence_warnings{ Wrest.const_set('Http', Wrest::Curl) } end |
+ (Object) use_native!
Switch Wrest to using Net::HTTP.
44 45 46 |
# File 'lib/wrest.rb', line 44 def self.use_native! silence_warnings{ Wrest.const_set('Http', Wrest::Native) } end |