48        $this->use_wsdl = 
true;
 
   49        $timeout = 
$ilSetting->get(
'soap_connect_timeout', self::DEFAULT_CONNECT_TIMEOUT);
 
   53        $this->connect_timeout = $timeout;
 
   73        $this->connect_timeout = $a_timeout;
 
   90        $this->response_timeout = (int) $a_timeout;
 
  107        $this->use_wsdl = $a_stat;
 
  116        return $this->use_wsdl;
 
  128            if (strlen(trim(
$ilSetting->get(
'soap_wsdl_path', 
'')))) {
 
  129                $this->uri = 
$ilSetting->get(
'soap_wsdl_path', 
'');
 
  135            $this->log->debug(
'Using wsdl: ' . $this->
getServer());
 
  136            $this->log->debug(
'Using connection timeout: ' . $this->
getTimeout());
 
  140            $this->client = 
new SoapClient(
 
  143                    'exceptions' => 
true,
 
  145                    'connection_timeout' => (
int) $this->
getTimeout()
 
  149        } 
catch (SoapFault $ex) {
 
  150            $this->log->warning(
'Soap init failed with message: ' . $ex->getMessage());
 
  164        $this->stored_socket_timeout = ini_get(
'default_socket_timeout');
 
  165        $this->log->debug(
'Default socket timeout is: ' . $this->stored_socket_timeout);
 
  168            $this->log->debug(
'WSDL mode, using socket timeout: ' . $this->
getTimeout());
 
  169            ini_set(
'default_socket_timeout', $this->
getTimeout());
 
  171            $this->log->debug(
'Non WSDL mode, using socket timeout: ' . $this->
getResponseTimeout());
 
  183        ini_set(
'default_socket_timeout', $this->stored_socket_timeout);
 
  184        $this->log->debug(
'Restoring default socket timeout to: ' . $this->stored_socket_timeout);
 
  193    public function call($a_operation, $a_params)
 
  195        $this->log->debug(
'Calling webservice: ' . $a_operation);
 
  199            return $this->client->__call($a_operation, $a_params);
 
  200        } 
catch (SoapFault $exception) {
 
  201            $this->log->error(
'Calling webservice failed with message: ' . $exception->getMessage());
 
  202            $this->log->debug($this->client->__getLastResponseHeaders());
 
  203            $this->log->debug($this->client->__getLastResponse());
 
  205        } 
catch (Exception $exception) {
 
  206            $this->log->error(
'Caught unknown exception with message: ' . $exception->getMessage());
 
  207            $this->log->debug($this->client->__getLastResponseHeaders());
 
  208            $this->log->debug($this->client->__getLastResponse());
 
An exception for terminatinating execution or to throw for unit testing.
static getLogger($a_component_id)
Get component logger.
getTimeout()
Get connect timeout.
enableWSDL($a_stat)
enable wsdl mode
call($a_operation, $a_params)
Call webservice method.
const DEFAULT_CONNECT_TIMEOUT
setResponseTimeout($a_timeout)
getServer()
Get server uri.
enabledWSDL()
Check if wsdl is enabled.
resetSocketTimeout()
Reset socket default timeout to defaults.
setTimeout($a_timeout)
Set connect timeout.
setSocketTimeout($a_wsdl_mode)
Set socket timeout.
const DEFAULT_RESPONSE_TIMEOUT