<?php

namespace StructType;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for JP_PriceRange StructType
 * @subpackage Structs
 */
class JP_PriceRange extends AbstractStructBase
{
    /**
     * The Minimum
     * Meta informations extracted from the WSDL
     * - use: required
     * @var float
     */
    public $Minimum;
    /**
     * The Maximum
     * Meta informations extracted from the WSDL
     * - use: required
     * @var float
     */
    public $Maximum;
    /**
     * The Currency
     * @var string
     */
    public $Currency;
    /**
     * Constructor method for JP_PriceRange
     * @uses JP_PriceRange::setMinimum()
     * @uses JP_PriceRange::setMaximum()
     * @uses JP_PriceRange::setCurrency()
     * @param float $minimum
     * @param float $maximum
     * @param string $currency
     */
    public function __construct($minimum = null, $maximum = null, $currency = null)
    {
        $this
            ->setMinimum($minimum)
            ->setMaximum($maximum)
            ->setCurrency($currency);
    }
    /**
     * Get Minimum value
     * @return float
     */
    public function getMinimum()
    {
        return $this->Minimum;
    }
    /**
     * Set Minimum value
     * @param float $minimum
     * @return \StructType\JP_PriceRange
     */
    public function setMinimum($minimum = null)
    {
        $this->Minimum = $minimum;
        return $this;
    }
    /**
     * Get Maximum value
     * @return float
     */
    public function getMaximum()
    {
        return $this->Maximum;
    }
    /**
     * Set Maximum value
     * @param float $maximum
     * @return \StructType\JP_PriceRange
     */
    public function setMaximum($maximum = null)
    {
        $this->Maximum = $maximum;
        return $this;
    }
    /**
     * Get Currency value
     * @return string|null
     */
    public function getCurrency()
    {
        return $this->Currency;
    }
    /**
     * Set Currency value
     * @param string $currency
     * @return \StructType\JP_PriceRange
     */
    public function setCurrency($currency = null)
    {
        // validation for constraint: string
        if (!is_null($currency) && !is_string($currency)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($currency)), __LINE__);
        }
        $this->Currency = $currency;
        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 \StructType\JP_PriceRange
     */
    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__;
    }
}
