<?php
/**
 * File for class DhlApiServiceBook
 * @package DhlApi
 * @subpackage Services
 * @author WsdlToPhp Team <contact@wsdltophp.com>
 * @version 20140325-01
 * @date 2015-02-05
 */
/**
 * This class stands for DhlApiServiceBook originally named Book
 * @package DhlApi
 * @subpackage Services
 * @author WsdlToPhp Team <contact@wsdltophp.com>
 * @version 20140325-01
 * @date 2015-02-05
 */
class DhlApiServiceBook extends DhlApiWsdlClass
{
    /**
     * Method to call the operation originally named bookCourier
     * Documentation : Zamawianie kuriera
     * @uses DhlApiWsdlClass::getSoapClient()
     * @uses DhlApiWsdlClass::setResult()
     * @uses DhlApiWsdlClass::saveLastError()
     * @param DhlApiStructBookCourier $_dhlApiStructBookCourier
     * @return DhlApiStructBookCourierResponse
     */
    public function bookCourier(DhlApiStructBookCourier $_dhlApiStructBookCourier)
    {
        try
        {
            return $this->setResult(self::getSoapClient()->bookCourier($_dhlApiStructBookCourier));
        }
        catch(SoapFault $soapFault)
        {
            return !$this->saveLastError(__METHOD__,$soapFault);
        }
    }
    /**
     * Returns the result
     * @see DhlApiWsdlClass::getResult()
     * @return DhlApiStructBookCourierResponse
     */
    public function getResult()
    {
        return parent::getResult();
    }
    /**
     * Method returning the class name
     * @return string __CLASS__
     */
    public function __toString()
    {
        return __CLASS__;
    }
}
