<?php

namespace patest\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for SinglePropertyCriteriaOfClientTicketType8Q8HnG_P7
 * StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:SinglePropertyCriteriaOfClientTicketType8Q8HnG_P7
 * @subpackage Structs
 */
class SinglePropertyCriteriaOfClientTicketType8Q8HnG_P7 extends SinglePropertyCriteriaBase
{
    /**
     * The Value
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * @var string
     */
    public $Value;
    /**
     * Constructor method for SinglePropertyCriteriaOfClientTicketType8Q8HnG_P7
     * @uses SinglePropertyCriteriaOfClientTicketType8Q8HnG_P7::setValue()
     * @param string $value
     */
    public function __construct($value = null)
    {
        $this
            ->setValue($value);
    }
    /**
     * Get Value value
     * @return string|null
     */
    public function getValue()
    {
        return $this->Value;
    }
    /**
     * Set Value value
     * @uses \patest\EnumType\ClientTicketType::valueIsValid()
     * @uses \patest\EnumType\ClientTicketType::getValidValues()
     * @throws \InvalidArgumentException
     * @param string $value
     * @return \patest\StructType\SinglePropertyCriteriaOfClientTicketType8Q8HnG_P7
     */
    public function setValue($value = null)
    {
        // validation for constraint: enumeration
        if (!\patest\EnumType\ClientTicketType::valueIsValid($value)) {
            throw new \InvalidArgumentException(sprintf('Invalid value(s) %s, please use one of: %s from enumeration class \patest\EnumType\ClientTicketType', is_array($value) ? implode(', ', $value) : var_export($value, true), implode(', ', \patest\EnumType\ClientTicketType::getValidValues())), __LINE__);
        }
        $this->Value = $value;
        return $this;
    }
}
