<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for InterfaceViaRouteResult_V3 StructType
 * @subpackage Structs
 */
class InterfaceViaRouteResult_V3 extends InterfaceViaRouteResult_V2
{
    /**
     * The ViaRouteBehavior
     * Meta information extracted from the WSDL
     * - maxOccurs: 1
     * - minOccurs: 1
     * - nillable: true
     * @var string
     */
    public $ViaRouteBehavior;
    /**
     * Constructor method for InterfaceViaRouteResult_V3
     * @uses InterfaceViaRouteResult_V3::setViaRouteBehavior()
     * @param string $viaRouteBehavior
     */
    public function __construct($viaRouteBehavior = null)
    {
        $this
            ->setViaRouteBehavior($viaRouteBehavior);
    }
    /**
     * Get ViaRouteBehavior value
     * @return string
     */
    public function getViaRouteBehavior()
    {
        return $this->ViaRouteBehavior;
    }
    /**
     * Set ViaRouteBehavior value
     * @uses \EnumType\EnumViaRouteBehavior::valueIsValid()
     * @uses \EnumType\EnumViaRouteBehavior::getValidValues()
     * @throws \InvalidArgumentException
     * @param string $viaRouteBehavior
     * @return \StructType\InterfaceViaRouteResult_V3
     */
    public function setViaRouteBehavior($viaRouteBehavior = null)
    {
        // validation for constraint: enumeration
        if (!\EnumType\EnumViaRouteBehavior::valueIsValid($viaRouteBehavior)) {
            throw new \InvalidArgumentException(sprintf('Invalid value(s) %s, please use one of: %s from enumeration class \EnumType\EnumViaRouteBehavior', is_array($viaRouteBehavior) ? implode(', ', $viaRouteBehavior) : var_export($viaRouteBehavior, true), implode(', ', \EnumType\EnumViaRouteBehavior::getValidValues())), __LINE__);
        }
        $this->ViaRouteBehavior = $viaRouteBehavior;
        return $this;
    }
}
