<?php

namespace dgsoft\StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for MiniRulesPriceText StructType
 * @package Dg
 * @subpackage Structs
 */
class DgMiniRulesPriceText extends AbstractStructBase
{
    /**
     * The PriceMessageValue
     * @var string
     */
    public $PriceMessageValue;
    /**
     * The PriceDataList
     * @var string
     */
    public $PriceDataList;
    /**
     * Constructor method for MiniRulesPriceText
     * @uses DgMiniRulesPriceText::setPriceMessageValue()
     * @uses DgMiniRulesPriceText::setPriceDataList()
     * @param string $priceMessageValue
     * @param string $priceDataList
     */
    public function __construct($priceMessageValue = null, $priceDataList = null)
    {
        $this
            ->setPriceMessageValue($priceMessageValue)
            ->setPriceDataList($priceDataList);
    }
    /**
     * Get PriceMessageValue value
     * @return string|null
     */
    public function getPriceMessageValue()
    {
        return $this->PriceMessageValue;
    }
    /**
     * Set PriceMessageValue value
     * @param string $priceMessageValue
     * @return \dgsoft\StructType\DgMiniRulesPriceText
     */
    public function setPriceMessageValue($priceMessageValue = null)
    {
        // validation for constraint: string
        if (!is_null($priceMessageValue) && !is_string($priceMessageValue)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($priceMessageValue)), __LINE__);
        }
        $this->PriceMessageValue = $priceMessageValue;
        return $this;
    }
    /**
     * Get PriceDataList value
     * @return string|null
     */
    public function getPriceDataList()
    {
        return $this->PriceDataList;
    }
    /**
     * Set PriceDataList value
     * @param string $priceDataList
     * @return \dgsoft\StructType\DgMiniRulesPriceText
     */
    public function setPriceDataList($priceDataList = null)
    {
        // validation for constraint: string
        if (!is_null($priceDataList) && !is_string($priceDataList)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($priceDataList)), __LINE__);
        }
        $this->PriceDataList = $priceDataList;
        return $this;
    }
    /**
     * Method called when an object has been exported with var_export() functions
     * It allows to return an object instantiated with the values
     * @see AbstractStructBase::__set_state()
     * @uses AbstractStructBase::__set_state()
     * @param array $array the exported values
     * @return \dgsoft\StructType\DgMiniRulesPriceText
     */
    public static function __set_state(array $array)
    {
        return parent::__set_state($array);
    }
    /**
     * Method returning the class name
     * @return string __CLASS__
     */
    public function __toString()
    {
        return __CLASS__;
    }
}
