Class: Ethon::Multi
- Inherits:
-
Object
- Object
- Ethon::Multi
- Includes:
- Operations, Options, Stack
- Defined in:
- lib/ethon/multi.rb,
lib/ethon/multi/stack.rb,
lib/ethon/multi/options.rb,
lib/ethon/multi/operations.rb
Overview
:nodoc
Defined Under Namespace
Modules: Operations, Options, Stack
Class Method Summary collapse
-
.finalizer(multi) ⇒ Object
private
Frees the libcurl multi handle.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Multi
constructor
Create a new multi.
-
#set_attributes(options) ⇒ Object
private
Set given options.
Methods included from Options
#maxconnects=, #pipelining=, #socketdata=, #socketfunction=, #timerdata=, #timerfunction=
Methods included from Operations
#handle, #init_vars, #perform, #prepare
Methods included from Stack
Constructor Details
Class Method Details
.finalizer(multi) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Frees the libcurl multi handle.
24 25 26 27 28 |
# File 'lib/ethon/multi.rb', line 24 def finalizer(multi) proc { Curl.multi_cleanup(multi.handle) } end |
Instance Method Details
#set_attributes(options) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Set given options.
100 101 102 103 104 105 106 107 |
# File 'lib/ethon/multi.rb', line 100 def set_attributes() .each_pair do |key, value| unless respond_to?("#{key}=") raise Errors::InvalidOption.new(key) end method("#{key}=").call(value) end end |