<?php

namespace CustomerManagement\ServiceType;

use \WsdlToPhp\PackageBase\AbstractSoapClientBase;

/**
 * This class stands for Edit ServiceType
 * @subpackage Services
 */
class Edit extends AbstractSoapClientBase
{
    /**
     * Sets the Authentication SoapHeader param
     * @uses AbstractSoapClientBase::setSoapHeader()
     * @param \CustomerManagement\StructType\Authentication $authentication
     * @param string $nameSpace
     * @param bool $mustUnderstand
     * @param string $actor
     * @return bool
     */
    public function setSoapHeaderAuthentication(\CustomerManagement\StructType\Authentication $authentication, $nameSpace = 'http://www.alarm.com/WebServices', $mustUnderstand = false, $actor = null)
    {
        return $this->setSoapHeader($nameSpace, 'Authentication', $authentication, $mustUnderstand, $actor);
    }
    /**
     * Method to call the operation originally named EditMasterCode
     * Meta information extracted from the WSDL
     * - SOAPHeaderNames: Authentication
     * - SOAPHeaderNamespaces: http://www.alarm.com/WebServices
     * - SOAPHeaderTypes: \CustomerManagement\StructType\Authentication
     * - SOAPHeaders: required
     * @uses AbstractSoapClientBase::getSoapClient()
     * @uses AbstractSoapClientBase::setResult()
     * @uses AbstractSoapClientBase::getResult()
     * @uses AbstractSoapClientBase::saveLastError()
     * @param \CustomerManagement\StructType\EditMasterCode $parameters
     * @return \CustomerManagement\StructType\EditMasterCodeResponse|bool
     */
    public function EditMasterCode(\CustomerManagement\StructType\EditMasterCode $parameters)
    {
        try {
            $this->setResult($this->getSoapClient()->EditMasterCode($parameters));
            return $this->getResult();
        } catch (\SoapFault $soapFault) {
            $this->saveLastError(__METHOD__, $soapFault);
            return false;
        }
    }
    /**
     * Method to call the operation originally named EditUserCode
     * Meta information extracted from the WSDL
     * - SOAPHeaderNames: Authentication
     * - SOAPHeaderNamespaces: http://www.alarm.com/WebServices
     * - SOAPHeaderTypes: \CustomerManagement\StructType\Authentication
     * - SOAPHeaders: required
     * - documentation: Calling this method will send a notification to the customer that their user codes have changed.To only update the user name, leave the NewUserCode field blank. To remove a code entirely, pass null for NewUserCode. This will remove
     * the user's code, but will not delete the user's profile information (phone, email, etc) on the account. To delete the user's profile when removing a user code, pass DeleteAdcUserProfile = true.
     * @uses AbstractSoapClientBase::getSoapClient()
     * @uses AbstractSoapClientBase::setResult()
     * @uses AbstractSoapClientBase::getResult()
     * @uses AbstractSoapClientBase::saveLastError()
     * @param \CustomerManagement\StructType\EditUserCode $parameters
     * @return \CustomerManagement\StructType\EditUserCodeResponse|bool
     */
    public function EditUserCode(\CustomerManagement\StructType\EditUserCode $parameters)
    {
        try {
            $this->setResult($this->getSoapClient()->EditUserCode($parameters));
            return $this->getResult();
        } catch (\SoapFault $soapFault) {
            $this->saveLastError(__METHOD__, $soapFault);
            return false;
        }
    }
    /**
     * Method to call the operation originally named EditScheduledAppointmentV2
     * Meta information extracted from the WSDL
     * - SOAPHeaderNames: Authentication
     * - SOAPHeaderNamespaces: http://www.alarm.com/WebServices
     * - SOAPHeaderTypes: \CustomerManagement\StructType\Authentication
     * - SOAPHeaders: required
     * - documentation: Modify a scheduled service appointment for a customer.
     * @uses AbstractSoapClientBase::getSoapClient()
     * @uses AbstractSoapClientBase::setResult()
     * @uses AbstractSoapClientBase::getResult()
     * @uses AbstractSoapClientBase::saveLastError()
     * @param \CustomerManagement\StructType\EditScheduledAppointmentV2 $parameters
     * @return \CustomerManagement\StructType\EditScheduledAppointmentV2Response|bool
     */
    public function EditScheduledAppointmentV2(\CustomerManagement\StructType\EditScheduledAppointmentV2 $parameters)
    {
        try {
            $this->setResult($this->getSoapClient()->EditScheduledAppointmentV2($parameters));
            return $this->getResult();
        } catch (\SoapFault $soapFault) {
            $this->saveLastError(__METHOD__, $soapFault);
            return false;
        }
    }
    /**
     * Returns the result
     * @see AbstractSoapClientBase::getResult()
     * @return \CustomerManagement\StructType\EditMasterCodeResponse|\CustomerManagement\StructType\EditScheduledAppointmentV2Response|\CustomerManagement\StructType\EditUserCodeResponse
     */
    public function getResult()
    {
        return parent::getResult();
    }
}
