ILIAS  eassessment Revision 61809
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilBMFTransport Class Reference
+ Collaboration diagram for ilBMFTransport:

Public Member Functions

getTransport ($url, $encoding=SOAP_DEFAULT_ENCODING)

Detailed Description

Definition at line 36 of file class.ilBMFTransport.php.

Member Function Documentation

& ilBMFTransport::getTransport (   $url,
  $encoding = SOAP_DEFAULT_ENCODING 
)

Definition at line 38 of file class.ilBMFTransport.php.

References $res, $t, and ilBMFBase_Object\_raiseSoapFault().

Referenced by ilBMFClient\call().

{
$urlparts = @parse_url($url);
if (!$urlparts['scheme']) {
$fault = ilBMFBase_Object::_raiseSoapFault("Invalid transport URI: $url");
return $fault;
}
if (strcasecmp($urlparts['scheme'], 'mailto') == 0) {
$transport_type = 'SMTP';
} elseif (strcasecmp($urlparts['scheme'], 'https') == 0) {
$transport_type = 'HTTP';
} else {
/* handle other transport types */
$transport_type = strtoupper($urlparts['scheme']);
}
$transport_include = dirname(__FILE__).'/Transport/class.ilBMFTransport_' . $transport_type . '.php';
$res = @include_once($transport_include);
if (!$res && !in_array($transport_include, get_included_files())) {
$fault = ilBMFBase_Object::_raiseSoapFault("No Transport for {$urlparts['scheme']}");
return $fault;
}
$transport_class = "ilBMFTransport_$transport_type";
if (!class_exists($transport_class)) {
$fault = ilBMFBase_Object::_raiseSoapFault("No Transport class $transport_class");
return $fault;
}
$t =& new $transport_class($url, $encoding);
return $t;
}

+ Here is the call graph for this function:

+ Here is the caller graph for this function:


The documentation for this class was generated from the following file: