Module: Ethon::Easy::Operations
- Included in:
- Ethon::Easy
- Defined in:
- lib/ethon/easy/operations.rb
Overview
This module contains the logic to prepare and perform an easy.
Instance Method Summary collapse
-
#handle ⇒ FFI::Pointer
Returns a pointer to the curl easy handle.
-
#perform ⇒ Integer
Perform the easy request.
-
#prepare ⇒ Object
deprecated
Deprecated.
It is no longer necessary to call prepare.
Instance Method Details
#handle ⇒ FFI::Pointer
Returns a pointer to the curl easy handle.
13 14 15 |
# File 'lib/ethon/easy/operations.rb', line 13 def handle @handle ||= Curl.easy_init end |
#perform ⇒ Integer
Perform the easy request.
23 24 25 26 27 28 |
# File 'lib/ethon/easy/operations.rb', line 23 def perform @return_code = Curl.easy_perform(handle) complete Ethon.logger.debug("ETHON: performed #{self.log_inspect}") @return_code end |
#prepare ⇒ Object
Deprecated.
It is no longer necessary to call prepare.
Prepare the easy. Options, headers and callbacks were set.
37 38 39 40 41 42 43 |
# File 'lib/ethon/easy/operations.rb', line 37 def prepare Ethon.logger.warn( "ETHON: It is no longer necessay to call "+ "Easy#prepare. Its going to be removed "+ "in future versions." ) end |