Methods summary
public
|
+/-
__construct( string $url, boolean $sslVerify, string $caCertificateFile, IU\PHPCap\ErrorHandlerInterface $errorHandler )
Constructor that creates a REDCap API connection for the specified URL, with the
specified settings.
Constructor that creates a REDCap API connection for the specified URL, with the
specified settings.
Parameters
- $url
- the URL for the API of the REDCap site that you want to connect to.
- $sslVerify
indicates if verification should be done for the SSL
connection to REDCap. Setting this to false is not secure.
- $caCertificateFile
the CA (Certificate Authority) certificate file used for veriying the REDCap site's
SSL certificate (i.e., for verifying that the REDCap site that is
connected to is the one specified).
- $errorHandler
- the error handler for the connection.
|
public
|
+/-
__destruct( )
Destructor for this class.
Destructor for this class.
|
public
string
|
+/-
call( mixed $data )
Makes a call to REDCap's API and returns the results.
Makes a call to REDCap's API and returns the results.
Parameters
Returns
string the response returned by the REDCap API for the specified call data.
See the REDCap API documentation for more information.
Throws
|
public
string
|
+/-
callWithArray( $dataArray )
Calls REDCap's API using a with a correctly formatted string version
of the specified array and returns the results.
Calls REDCap's API using a with a correctly formatted string version
of the specified array and returns the results.
Parameters
- $dataArray
the array of data that is converted to a
string and then passed to the REDCap API.
Returns
string the response returned by the REDCap API for the specified call data.
See the REDCap API documentation for more information.
Throws
|
public
|
+/-
getCallInfo( )
Returns call information for the most recent call.
The format of the call information will be connection dependent.
Returns call information for the most recent call. The format of the call information will be connection dependent.
|
public
|
+/-
getErrorHandler( )
Gets the error handler for the connection.
Gets the error handler for the connection.
return ErrorHandlerInterface the error handler for the connection.
|
public
|
|
public
|
+/-
getUrl( )
Gets the URL of the connection.
Gets the URL of the connection.
return string the URL of the connection.
|
public
|
+/-
setUrl( string $url )
Sets the URL of the connection.
Sets the URL of the connection.
Parameters
- $url
- the URL of the connection.
|
public
boolean
|
+/-
getSslVerify( )
Gets the status of SSL verification for the connection.
Gets the status of SSL verification for the connection.
Returns
boolean true if SSL verification is enabled, and false otherwise.
|
public
|
+/-
setSslVerify( boolean $sslVerify )
Sets SSL verification for the connection.
Sets SSL verification for the connection.
Parameters
- $sslVerify
if this is true, then the site being connected to will
have its SSL certificate verified.
|
public
integer
|
+/-
getTimeoutInSeconds( )
Gets the timeout in seconds for calls to the connection.
Gets the timeout in seconds for calls to the connection.
Returns
integer timeout in seconds for calls to connection.
|
public
|
+/-
setTimeoutInSeconds( $timeoutInSeconds )
Sets the timeout in seconds for calls to the connection.
Sets the timeout in seconds for calls to the connection.
Parameters
- $timeoutInSeconds
- in seconds for call to connection.
|
public
integer
|
+/-
getConnectionTimeoutInSeconds( )
Gets the timeout for time to make a connection in seconds.
Gets the timeout for time to make a connection in seconds.
Returns
integer connection timeout in seconds.
|
public
|
+/-
setConnectionTimeoutInSeconds( integer $connectionTimeoutInSeconds )
Sets the timeout for time to make a connection in seconds.
Sets the timeout for time to make a connection in seconds.
Parameters
- $connectionTimeoutInSeconds
- timeout in seconds.
|