public function setPostBody ($body)
    {
        if ($this->_sent) {
            throw new CAS_OutOfSequenceException(
                'Request has already been sent cannot '.__METHOD__
            );
        }
        if (!$this->isPost) {
            throw new CAS_OutOfSequenceException(
                'Cannot add a POST body to a GET request, use makePost() first.'
            );
        }

        $this->postBody = $body;
    }
public function setPostBody ($body)
    {
        if ($this->_sent) {
            throw new CAS_OutOfSequenceException(
                'Request has already been sent cannot '.__METHOD__
            );
        }
        if (!$this->isPost) {
            throw new CAS_OutOfSequenceException(
                'Cannot add a POST body to a GET request, use makePost() first.'
            );
        }

        $this->postBody = $body;
    }
public function setPostBody ( $ body ) { if ( $ this -> _sent ) { throw new CAS_OutOfSequenceException ( 'Request has already been sent cannot ' . __METHOD__ ) ; } if ( ! $ this -> isPost ) { throw new CAS_OutOfSequenceException ( 'Cannot add a POST body to a GET request, use makePost() first.' ) ; } $ this -> postBody = $ body ; }
Add a POST body to the request

@param string $body body to add

@return void
@throws CAS_OutOfSequenceException If called after the Request has been sent.
Add a POST body to the request