예제 #1
0
 /**
  * The constructor
  * 
  * @param string  $rooturl     The URL of the wsdl file
  * @param string  $type        The type of exchange
  * @param array   $options     An array of options
  * @param boolean $loggable    True if you want to log all the exchanges with the web service
  * @param string  $local_cert  Path of the certifacte
  * @param string  $passphrase  Pass phrase for the certificate
  * @param boolean $safe_mode   Safe mode
  * @param boolean $verify_peer Require verification of SSL certificate used
  * @param string  $cafile      Location of Certificate Authority file on local filesystem
  *
  * @throws CMbException
  *
  * @return CNuSOAPClient
  */
 function __construct($rooturl, $type = null, $options = array(), $loggable = null, $local_cert = null, $passphrase = null, $safe_mode = false, $verify_peer = false, $cafile = null)
 {
     $this->wsdl_url = $rooturl;
     if ($loggable) {
         $this->loggable = $loggable;
     }
     if ($type) {
         $this->type_echange_soap = $type;
     }
     if (!$safe_mode) {
         if (!($html = file_get_contents($this->wsdl_url))) {
             $this->soap_client_error = true;
             throw new CMbException("CSourceSOAP-unable-to-parse-url", $this->wsdl_url);
         }
         if (strpos($html, "<?xml") === false) {
             $this->soap_client_error = true;
             throw new CMbException("CSourceSOAP-wsdl-invalid");
         }
     }
     if (array_key_exists("encoding", $options)) {
         $encoding = $options["encoding"];
         $this->soap_defencoding = $encoding;
         if ($encoding == "UTF-8") {
             $this->decode_utf8 = false;
         }
     }
     if ($local_cert) {
         $this->certRequest = array("sslcertfile" => $local_cert);
     }
     if ($passphrase) {
         $this->certRequest = array("passphrase" => $passphrase);
     }
     parent::__construct($rooturl, true, false, false, false, false, CAppUI::conf("webservices connection_timeout"));
     $this->wsdl_url = $rooturl;
 }
예제 #2
0
 function __construct($wsdlUrl, $username, $password)
 {
     $this->authtype = 'basic';
     $this->username = $username;
     $this->password = $password;
     parent::__construct($wsdlUrl, 'wsdl');
 }
예제 #3
0
 /**
  * Constructor
  */
 public function __construct()
 {
     $endpoint = $this->getEndpoint();
     $this->setupNuSoap($endpoint);
     $options = $this->getOptions();
     parent::__construct($endpoint, false, false, false, false, false, $options['connection_timeout']);
 }
 function __construct($wsdlUrl, $username = null, $password = null)
 {
     $this->authtype = 'basic';
     $this->username = $username;
     $this->password = $password;
     parent::__construct($wsdlUrl, 'wsdl');
     $this->setVerbose(false);
 }
예제 #5
0
 function __construct()
 {
     $wsdlUrl = kConf::get('live_analytics_web_service_url');
     parent::__construct($wsdlUrl, 'wsdl');
     $this->keepType(true);
 }
 public function IShopServerWSService($wsdl = "IShopServerWS.wsdl", $options = array())
 {
     foreach (self::$classmap as $key => $value) {
         if (!isset($options['classmap'][$key])) {
             $options['classmap'][$key] = $value;
         }
     }
     parent::__construct($wsdl, $options);
 }