protected function populateRequest (CAS_Request_RequestInterface $request)
    {
        if (empty($this->_contentType) && !empty($this->_body)) {
            throw new CAS_ProxiedService_Exception(
                "If you pass a POST body, you must specify a content type via "
                .get_class($this).'->setContentType($contentType).'
            );
        }

        $request->makePost();
        if (!empty($this->_body)) {
            $request->addHeader('Content-Type: '.$this->_contentType);
            $request->addHeader('Content-Length: '.strlen($this->_body));
            $request->setPostBody($this->_body);
        }
    }
protected function populateRequest (CAS_Request_RequestInterface $request)
    {
        if (empty($this->_contentType) && !empty($this->_body)) {
            throw new CAS_ProxiedService_Exception(
                "If you pass a POST body, you must specify a content type via "
                .get_class($this).'->setContentType($contentType).'
            );
        }

        $request->makePost();
        if (!empty($this->_body)) {
            $request->addHeader('Content-Type: '.$this->_contentType);
            $request->addHeader('Content-Length: '.strlen($this->_body));
            $request->setPostBody($this->_body);
        }
    }
protected function populateRequest ( CAS_Request_RequestInterface $ request ) { if ( empty ( $ this -> _contentType ) && ! empty ( $ this -> _body ) ) { throw new CAS_ProxiedService_Exception ( "If you pass a POST body, you must specify a content type via " . get_class ( $ this ) . '->setContentType($contentType).' ) ; } $ request -> makePost ( ) ; if ( ! empty ( $ this -> _body ) ) { $ request -> addHeader ( 'Content-Type: ' . $ this -> _contentType ) ; $ request -> addHeader ( 'Content-Length: ' . strlen ( $ this -> _body ) ) ; $ request -> setPostBody ( $ this -> _body ) ; } }
Add any other parts of the request needed by concrete classes

@param CAS_Request_RequestInterface $request request interface class

@return void
Add any other parts of the request needed by concrete classes