/**
  * Allows you to add a new event notification template object
  * 
  * @action add
  * @param KalturaEventNotificationTemplate $eventNotificationTemplate
  * @return KalturaEventNotificationTemplate
  */
 public function addAction(KalturaEventNotificationTemplate $eventNotificationTemplate)
 {
     $dbEventNotificationTemplate = $eventNotificationTemplate->toInsertableObject();
     /* @var $dbEventNotificationTemplate EventNotificationTemplate */
     $dbEventNotificationTemplate->setStatus(EventNotificationTemplateStatus::ACTIVE);
     $dbEventNotificationTemplate->setPartnerId($this->impersonatedPartnerId);
     $dbEventNotificationTemplate->save();
     // return the saved object
     $eventNotificationTemplate = KalturaEventNotificationTemplate::getInstanceByType($dbEventNotificationTemplate->getType());
     $eventNotificationTemplate->fromObject($dbEventNotificationTemplate);
     return $eventNotificationTemplate;
 }
 /**
  * Allows you to add a new event notification template object
  * 
  * @action add
  * @param KalturaEventNotificationTemplate $eventNotificationTemplate
  * @return KalturaEventNotificationTemplate
  */
 public function addAction(KalturaEventNotificationTemplate $eventNotificationTemplate)
 {
     $dbEventNotificationTemplate = $eventNotificationTemplate->toInsertableObject();
     /* @var $dbEventNotificationTemplate EventNotificationTemplate */
     $dbEventNotificationTemplate->setStatus(EventNotificationTemplateStatus::ACTIVE);
     //Partner 0 cannot be impersonated, the reasong this work is because null equals to 0.
     $dbEventNotificationTemplate->setPartnerId($this->impersonatedPartnerId);
     $dbEventNotificationTemplate->save();
     // return the saved object
     $eventNotificationTemplate = KalturaEventNotificationTemplate::getInstanceByType($dbEventNotificationTemplate->getType());
     $eventNotificationTemplate->fromObject($dbEventNotificationTemplate, $this->getResponseProfile());
     return $eventNotificationTemplate;
 }