public function __construct(SimpleXMLElement $xml = null)
 {
     parent::__construct($xml);
     if (is_null($xml)) {
         return;
     }
     $this->url = (string) $xml->url;
     if (count($xml->method)) {
         $this->method = (int) $xml->method;
     }
     $this->data = (string) $xml->data;
     if (count($xml->timeout)) {
         $this->timeout = (int) $xml->timeout;
     }
     if (count($xml->connectTimeout)) {
         $this->connectTimeout = (int) $xml->connectTimeout;
     }
     $this->username = (string) $xml->username;
     $this->password = (string) $xml->password;
     if (count($xml->authenticationMethod)) {
         $this->authenticationMethod = (int) $xml->authenticationMethod;
     }
     if (count($xml->sslVersion)) {
         $this->sslVersion = (int) $xml->sslVersion;
     }
     $this->sslCertificate = (string) $xml->sslCertificate;
     $this->sslCertificateType = (string) $xml->sslCertificateType;
     $this->sslCertificatePassword = (string) $xml->sslCertificatePassword;
     $this->sslEngine = (string) $xml->sslEngine;
     $this->sslEngineDefault = (string) $xml->sslEngineDefault;
     $this->sslKeyType = (string) $xml->sslKeyType;
     $this->sslKey = (string) $xml->sslKey;
     $this->sslKeyPassword = (string) $xml->sslKeyPassword;
     if (empty($xml->customHeaders)) {
         $this->customHeaders = array();
     } else {
         $this->customHeaders = Kaltura_Client_ParseUtils::unmarshalArray($xml->customHeaders, "KalturaKeyValue");
     }
     if (empty($xml->contentParameters)) {
         $this->contentParameters = array();
     } else {
         $this->contentParameters = Kaltura_Client_ParseUtils::unmarshalArray($xml->contentParameters, "KalturaKeyValue");
     }
 }
 public function __construct(SimpleXMLElement $xml = null)
 {
     parent::__construct($xml);
     if (is_null($xml)) {
         return;
     }
     $this->fromEmail = (string) $xml->fromEmail;
     $this->fromName = (string) $xml->fromName;
     if (!empty($xml->to)) {
         $this->to = Kaltura_Client_Client::unmarshalItem($xml->to);
     }
     if (!empty($xml->cc)) {
         $this->cc = Kaltura_Client_Client::unmarshalItem($xml->cc);
     }
     if (!empty($xml->bcc)) {
         $this->bcc = Kaltura_Client_Client::unmarshalItem($xml->bcc);
     }
     if (!empty($xml->replyTo)) {
         $this->replyTo = Kaltura_Client_Client::unmarshalItem($xml->replyTo);
     }
     if (count($xml->priority)) {
         $this->priority = (int) $xml->priority;
     }
     $this->confirmReadingTo = (string) $xml->confirmReadingTo;
     $this->hostname = (string) $xml->hostname;
     $this->messageID = (string) $xml->messageID;
     if (empty($xml->customHeaders)) {
         $this->customHeaders = array();
     } else {
         $this->customHeaders = Kaltura_Client_Client::unmarshalItem($xml->customHeaders);
     }
     if (empty($xml->contentParameters)) {
         $this->contentParameters = array();
     } else {
         $this->contentParameters = Kaltura_Client_Client::unmarshalItem($xml->contentParameters);
     }
 }
 public function __construct(SimpleXMLElement $xml = null)
 {
     parent::__construct($xml);
     if (is_null($xml)) {
         return;
     }
     $this->fromEmail = (string) $xml->fromEmail;
     $this->fromName = (string) $xml->fromName;
     if (!empty($xml->to)) {
         $this->to = Kaltura_Client_ParseUtils::unmarshalObject($xml->to, "KalturaEmailNotificationRecipientJobData");
     }
     if (!empty($xml->cc)) {
         $this->cc = Kaltura_Client_ParseUtils::unmarshalObject($xml->cc, "KalturaEmailNotificationRecipientJobData");
     }
     if (!empty($xml->bcc)) {
         $this->bcc = Kaltura_Client_ParseUtils::unmarshalObject($xml->bcc, "KalturaEmailNotificationRecipientJobData");
     }
     if (!empty($xml->replyTo)) {
         $this->replyTo = Kaltura_Client_ParseUtils::unmarshalObject($xml->replyTo, "KalturaEmailNotificationRecipientJobData");
     }
     if (count($xml->priority)) {
         $this->priority = (int) $xml->priority;
     }
     $this->confirmReadingTo = (string) $xml->confirmReadingTo;
     $this->hostname = (string) $xml->hostname;
     $this->messageID = (string) $xml->messageID;
     if (empty($xml->customHeaders)) {
         $this->customHeaders = array();
     } else {
         $this->customHeaders = Kaltura_Client_ParseUtils::unmarshalArray($xml->customHeaders, "KalturaKeyValue");
     }
     if (empty($xml->contentParameters)) {
         $this->contentParameters = array();
     } else {
         $this->contentParameters = Kaltura_Client_ParseUtils::unmarshalArray($xml->contentParameters, "KalturaKeyValue");
     }
 }
 function dispatch($id, Kaltura_Client_EventNotification_Type_EventNotificationDispatchJobData $data)
 {
     $kparams = array();
     $this->client->addParam($kparams, "id", $id);
     $this->client->addParam($kparams, "data", $data->toParams());
     $this->client->queueServiceActionCall("eventnotification_eventnotificationtemplate", "dispatch", null, $kparams);
     if ($this->client->isMultiRequest()) {
         return $this->client->getMultiRequestResult();
     }
     $resultXml = $this->client->doQueue();
     $resultXmlObject = new \SimpleXMLElement($resultXml);
     Kaltura_Client_ParseUtils::checkIfError($resultXmlObject->result);
     $resultObject = (int) Kaltura_Client_ParseUtils::unmarshalSimpleType($resultXmlObject->result);
     return $resultObject;
 }
 function dispatch($id, Kaltura_Client_EventNotification_Type_EventNotificationDispatchJobData $data)
 {
     $kparams = array();
     $this->client->addParam($kparams, "id", $id);
     $this->client->addParam($kparams, "data", $data->toParams());
     $this->client->queueServiceActionCall("eventnotification_eventnotificationtemplate", "dispatch", $kparams);
     if ($this->client->isMultiRequest()) {
         return $this->client->getMultiRequestResult();
     }
     $resultObject = $this->client->doQueue();
     $this->client->throwExceptionIfError($resultObject);
     $this->client->validateObjectType($resultObject, "integer");
     return $resultObject;
 }