phpCAS  version 1.4.0
Public Member Functions | List of all members
CAS_Request_MultiRequestInterface Class Reference
Inheritance diagram for CAS_Request_MultiRequestInterface:
CAS_Request_CurlMultiRequest

Public Member Functions

 addRequest (CAS_Request_RequestInterface $request)
 
 getNumRequests ()
 
 send ()
 

Detailed Description

This interface defines a class library for performing multiple web requests in batches. Implementations of this interface may perform requests serially or in parallel.

Definition at line 42 of file MultiRequestInterface.php.

Member Function Documentation

◆ addRequest()

CAS_Request_MultiRequestInterface::addRequest ( CAS_Request_RequestInterface  $request)

Add a new Request to this batch. Note, implementations will likely restrict requests to their own concrete class hierarchy.

Parameters
CAS_Request_RequestInterface$requestrequest interface
Returns
void
Exceptions
CAS_OutOfSequenceExceptionIf called after the Request has been sent.
CAS_InvalidArgumentExceptionIf passed a Request of the wrong implmentation.

◆ getNumRequests()

CAS_Request_MultiRequestInterface::getNumRequests ( )

Retrieve the number of requests added to this batch.

Returns
int number of request elements

◆ send()

CAS_Request_MultiRequestInterface::send ( )

Perform the request. After sending, all requests will have their responses poulated.

Returns
bool TRUE on success, FALSE on failure.
Exceptions
CAS_OutOfSequenceExceptionIf called multiple times.