Moodle  2.2.1
http://www.collinsharper.com
PGT storage
Collaboration diagram for PGT storage:

Data Structures

class  PGTStorage

Modules

 PGT storage on the filesystem

Functions

 setPGTStorageFile ($format='', $path='')
 _curl_read_headers ($ch, $header)
 serviceWeb ($url, &$err_code, &$output)
 setCookies ($headers, $url)
 getCookies ($url)
 serviceMail ($url, $service, $flags, &$err_code, &$err_msg, &$pt)
 PGTStorage ($cas_parent)
 getStorageType ()
 getStorageInfo ()
 setErrorMessage ($error_message)
 getErrorMessage ()
 isInitialized ()
 init ()
 write ($pgt, $pgt_iou)
 read ($pgt_iou)

Variables

 $_curl_headers = array()

Function Documentation

_curl_read_headers ( ch,
header 
)

Definition at line 2250 of file client.php.

getCookies ( url)

This method get the cookies from the session

Definition at line 2369 of file client.php.

Here is the caller graph for this function:

getErrorMessage ( )

This method returns an error message set by PGTStorage::setErrorMessage().

Returns:
an error message when set by PGTStorage::setErrorMessage(), FALSE otherwise.
Deprecated:
not used.

Definition at line 135 of file pgt-main.php.

getStorageInfo ( )

This virtual method returns an informational string giving informations on the parameters of the storage.(used for debugging purposes).

Reimplemented in PGTStorageFile.

Definition at line 93 of file pgt-main.php.

getStorageType ( )

This virtual method returns an informational string giving the type of storage used by the object (used for debugging purposes).

Reimplemented in PGTStorageFile.

Definition at line 82 of file pgt-main.php.

init ( ) [protected]

This virtual method initializes the object.

Reimplemented in PGTStorageFile.

Definition at line 170 of file pgt-main.php.

isInitialized ( ) [protected]

This method tells if the storage has already been intialized.

Returns:
a boolean

Definition at line 160 of file pgt-main.php.

Here is the caller graph for this function:

PGTStorage ( cas_parent) [protected]

The constructor of the class, should be called only by inherited classes.

Parameters:
$cas_parentthe CASclient instance that creates the current object.

Definition at line 63 of file pgt-main.php.

Here is the call graph for this function:

Here is the caller graph for this function:

read ( pgt_iou) [protected]

This virtual method reads a PGT corresponding to a PGT Iou and deletes the corresponding storage entry.

Note:
Should never be called.
Parameters:
$pgt_iouthe PGT iou

Reimplemented in PGTStorageFile.

Definition at line 202 of file pgt-main.php.

serviceMail ( url,
service,
flags,
&$  err_code,
&$  err_msg,
&$  pt 
)

This method is used to access an IMAP/POP3/NNTP service.

Parameters:
$urla string giving the URL of the service, including the mailing box for IMAP URLs, as accepted by imap_open().
$servicea string giving for CAS retrieve Proxy ticket
$flagsoptions given to imap_open().
$err_codean error code Possible values are PHPCAS_SERVICE_OK (on success), PHPCAS_SERVICE_PT_NO_SERVER_RESPONSE, PHPCAS_SERVICE_PT_BAD_SERVER_RESPONSE, PHPCAS_SERVICE_PT_FAILURE, PHPCAS_SERVICE_NOT AVAILABLE.
$err_msgan error message on failure
$ptthe Proxy Ticket (PT) retrieved from the CAS server to access the URL on success, FALSE on error).
Returns:
an IMAP stream on success, FALSE otherwise (in this later case, $err_code gives the reason why it failed and $err_msg contains an error message).

Definition at line 2399 of file client.php.

serviceWeb ( url,
&$  err_code,
&$  output 
)

This method is used to access an HTTP[S] service.

Parameters:
$urlthe service to access.
$err_codean error code Possible values are PHPCAS_SERVICE_OK (on success), PHPCAS_SERVICE_PT_NO_SERVER_RESPONSE, PHPCAS_SERVICE_PT_BAD_SERVER_RESPONSE, PHPCAS_SERVICE_PT_FAILURE, PHPCAS_SERVICE_NOT AVAILABLE.
$outputthe output of the service (also used to give an error message on failure).
Returns:
TRUE on success, FALSE otherwise (in this later case, $err_code gives the reason why it failed and $output contains an error message).

Definition at line 2271 of file client.php.

Here is the call graph for this function:

setCookies ( headers,
url 
)

This method stores cookies from a HTTP Header in the session

Parameters:
$headerHTTP Header
$urlthe url the Header is from

Definition at line 2345 of file client.php.

setErrorMessage ( error_message) [protected]

This method sets en error message, which can be read later by PGTStorage::getErrorMessage().

Parameters:
$error_messagean error message
Deprecated:
not used.

Definition at line 121 of file pgt-main.php.

setPGTStorageFile ( format = '',
path = '' 
)

This method is used to tell phpCAS to store the response of the CAS server to PGT requests onto the filesystem.

Parameters:
$formatthe format used to store the PGT's (`plain' and `xml' allowed)
$paththe path where the PGT's should be stored

Definition at line 1942 of file client.php.

write ( pgt,
pgt_iou 
) [protected]

This virtual method stores a PGT and its corresponding PGT Iuo.

Note:
Should never be called.
Parameters:
$pgtthe PGT
$pgt_iouthe PGT iou

Reimplemented in PGTStorageFile.

Definition at line 188 of file pgt-main.php.


Variable Documentation

$_curl_headers = array()

This method is the callback used by readURL method to request HTTP headers.

Definition at line 2249 of file client.php.

 All Data Structures Namespaces Files Functions Variables Enumerations