public function addTransaction(TransactionInterface $transaction, $handle)
    {
        if (isset($this->handles[$transaction])) {
            throw new AdapterException('Transaction already registered');
        }

        $code = curl_multi_add_handle($this->multi, $handle);
        if ($code != CURLM_OK) {
            MultiAdapter::throwMultiError($code);
        }

        $this->handles[$transaction] = $handle;
    }
public function addTransaction(TransactionInterface $transaction, $handle)
    {
        if (isset($this->handles[$transaction])) {
            throw new AdapterException('Transaction already registered');
        }

        $code = curl_multi_add_handle($this->multi, $handle);
        if ($code != CURLM_OK) {
            MultiAdapter::throwMultiError($code);
        }

        $this->handles[$transaction] = $handle;
    }
public function addTransaction ( TransactionInterface $ transaction , $ handle ) { if ( isset ( $ this -> handles [ $ transaction ] ) ) { throw new AdapterException ( 'Transaction already registered' ) ; } $ code = curl_multi_add_handle ( $ this -> multi , $ handle ) ; if ( $ code != CURLM_OK ) { MultiAdapter :: throwMultiError ( $ code ) ; } $ this -> handles [ $ transaction ] = $ handle ; }
Add a transaction to the multi handle

@param TransactionInterface $transaction Transaction to add
@param resource             $handle      Resource to use with the handle

@throws AdapterException If the handle is already registered
Add a transaction to the multi handle