<?php

namespace NineDotMedia\viapost-php\Struct;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for SendDriverMailingConfirmationResponse Struct
 * @subpackage Structs
 */
class SendDriverMailingConfirmationResponse extends AbstractStructBase
{
    /**
     * The SendDriverMailingConfirmationResult
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 1
     * @var bool
     */
    public $SendDriverMailingConfirmationResult;
    /**
     * The returnMessage
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 0
     * @var string
     */
    public $returnMessage;
    /**
     * Constructor method for SendDriverMailingConfirmationResponse
     * @uses SendDriverMailingConfirmationResponse::setSendDriverMailingConfirmationResult()
     * @uses SendDriverMailingConfirmationResponse::setReturnMessage()
     * @param bool $sendDriverMailingConfirmationResult
     * @param string $returnMessage
     */
    public function __construct($sendDriverMailingConfirmationResult = null, $returnMessage = null)
    {
        $this
            ->setSendDriverMailingConfirmationResult($sendDriverMailingConfirmationResult)
            ->setReturnMessage($returnMessage);
    }
    /**
     * Get SendDriverMailingConfirmationResult value
     * @return bool
     */
    public function getSendDriverMailingConfirmationResult()
    {
        return $this->SendDriverMailingConfirmationResult;
    }
    /**
     * Set SendDriverMailingConfirmationResult value
     * @param bool $sendDriverMailingConfirmationResult
     * @return \NineDotMedia\viapost-php\Struct\SendDriverMailingConfirmationResponse
     */
    public function setSendDriverMailingConfirmationResult($sendDriverMailingConfirmationResult = null)
    {
        // validation for constraint: boolean
        if (!is_null($sendDriverMailingConfirmationResult) && !is_bool($sendDriverMailingConfirmationResult)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a bool, %s given', var_export($sendDriverMailingConfirmationResult, true), gettype($sendDriverMailingConfirmationResult)), __LINE__);
        }
        $this->SendDriverMailingConfirmationResult = $sendDriverMailingConfirmationResult;
        return $this;
    }
    /**
     * Get returnMessage value
     * @return string|null
     */
    public function getReturnMessage()
    {
        return $this->returnMessage;
    }
    /**
     * Set returnMessage value
     * @param string $returnMessage
     * @return \NineDotMedia\viapost-php\Struct\SendDriverMailingConfirmationResponse
     */
    public function setReturnMessage($returnMessage = null)
    {
        // validation for constraint: string
        if (!is_null($returnMessage) && !is_string($returnMessage)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($returnMessage, true), gettype($returnMessage)), __LINE__);
        }
        $this->returnMessage = $returnMessage;
        return $this;
    }
}
