<?php
/**
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen
 * Do not edit the class manually.
 */

namespace SquareConnect\Model;

use \ArrayAccess;
/**
 * CatalogQueryFilteredItemsCustomAttributeFilter Class Doc Comment
 *
 * @category Class
 * @package  SquareConnect
 * @author   Square Inc.
 * @license  http://www.apache.org/licenses/LICENSE-2.0 Apache License v2
 * @link     https://squareup.com/developers
 */
class CatalogQueryFilteredItemsCustomAttributeFilter implements ArrayAccess
{
    /**
      * Array of property to type mappings. Used for (de)serialization 
      * @var string[]
      */
    static $swaggerTypes = array(
        'filter_type' => 'string',
        'custom_attribute_definition_ids' => 'string[]',
        'custom_attribute_value_exact' => 'string',
        'custom_attribute_value_prefix' => 'string',
        'custom_attribute_min_value' => 'string',
        'custom_attribute_max_value' => 'string'
    );
  
    /** 
      * Array of attributes where the key is the local name, and the value is the original name
      * @var string[] 
      */
    static $attributeMap = array(
        'filter_type' => 'filter_type',
        'custom_attribute_definition_ids' => 'custom_attribute_definition_ids',
        'custom_attribute_value_exact' => 'custom_attribute_value_exact',
        'custom_attribute_value_prefix' => 'custom_attribute_value_prefix',
        'custom_attribute_min_value' => 'custom_attribute_min_value',
        'custom_attribute_max_value' => 'custom_attribute_max_value'
    );
  
    /**
      * Array of attributes to setter functions (for deserialization of responses)
      * @var string[]
      */
    static $setters = array(
        'filter_type' => 'setFilterType',
        'custom_attribute_definition_ids' => 'setCustomAttributeDefinitionIds',
        'custom_attribute_value_exact' => 'setCustomAttributeValueExact',
        'custom_attribute_value_prefix' => 'setCustomAttributeValuePrefix',
        'custom_attribute_min_value' => 'setCustomAttributeMinValue',
        'custom_attribute_max_value' => 'setCustomAttributeMaxValue'
    );
  
    /**
      * Array of attributes to getter functions (for serialization of requests)
      * @var string[]
      */
    static $getters = array(
        'filter_type' => 'getFilterType',
        'custom_attribute_definition_ids' => 'getCustomAttributeDefinitionIds',
        'custom_attribute_value_exact' => 'getCustomAttributeValueExact',
        'custom_attribute_value_prefix' => 'getCustomAttributeValuePrefix',
        'custom_attribute_min_value' => 'getCustomAttributeMinValue',
        'custom_attribute_max_value' => 'getCustomAttributeMaxValue'
    );
  
    /**
      * $filter_type See [CatalogQueryFilteredItemsCustomAttributeFilterFilterType](#type-catalogqueryfiltereditemscustomattributefilterfiltertype) for possible values
      * @var string
      */
    protected $filter_type;
    /**
      * $custom_attribute_definition_ids 
      * @var string[]
      */
    protected $custom_attribute_definition_ids;
    /**
      * $custom_attribute_value_exact 
      * @var string
      */
    protected $custom_attribute_value_exact;
    /**
      * $custom_attribute_value_prefix 
      * @var string
      */
    protected $custom_attribute_value_prefix;
    /**
      * $custom_attribute_min_value 
      * @var string
      */
    protected $custom_attribute_min_value;
    /**
      * $custom_attribute_max_value 
      * @var string
      */
    protected $custom_attribute_max_value;

    /**
     * Constructor
     * @param mixed[] $data Associated array of property value initializing the model
     */
    public function __construct(array $data = null)
    {
        if ($data != null) {
            if (isset($data["filter_type"])) {
              $this->filter_type = $data["filter_type"];
            } else {
              $this->filter_type = null;
            }
            if (isset($data["custom_attribute_definition_ids"])) {
              $this->custom_attribute_definition_ids = $data["custom_attribute_definition_ids"];
            } else {
              $this->custom_attribute_definition_ids = null;
            }
            if (isset($data["custom_attribute_value_exact"])) {
              $this->custom_attribute_value_exact = $data["custom_attribute_value_exact"];
            } else {
              $this->custom_attribute_value_exact = null;
            }
            if (isset($data["custom_attribute_value_prefix"])) {
              $this->custom_attribute_value_prefix = $data["custom_attribute_value_prefix"];
            } else {
              $this->custom_attribute_value_prefix = null;
            }
            if (isset($data["custom_attribute_min_value"])) {
              $this->custom_attribute_min_value = $data["custom_attribute_min_value"];
            } else {
              $this->custom_attribute_min_value = null;
            }
            if (isset($data["custom_attribute_max_value"])) {
              $this->custom_attribute_max_value = $data["custom_attribute_max_value"];
            } else {
              $this->custom_attribute_max_value = null;
            }
        }
    }
    /**
     * Gets filter_type
     * @return string
     */
    public function getFilterType()
    {
        return $this->filter_type;
    }
  
    /**
     * Sets filter_type
     * @param string $filter_type See [CatalogQueryFilteredItemsCustomAttributeFilterFilterType](#type-catalogqueryfiltereditemscustomattributefilterfiltertype) for possible values
     * @return $this
     */
    public function setFilterType($filter_type)
    {
        $this->filter_type = $filter_type;
        return $this;
    }
    /**
     * Gets custom_attribute_definition_ids
     * @return string[]
     */
    public function getCustomAttributeDefinitionIds()
    {
        return $this->custom_attribute_definition_ids;
    }
  
    /**
     * Sets custom_attribute_definition_ids
     * @param string[] $custom_attribute_definition_ids 
     * @return $this
     */
    public function setCustomAttributeDefinitionIds($custom_attribute_definition_ids)
    {
        $this->custom_attribute_definition_ids = $custom_attribute_definition_ids;
        return $this;
    }
    /**
     * Gets custom_attribute_value_exact
     * @return string
     */
    public function getCustomAttributeValueExact()
    {
        return $this->custom_attribute_value_exact;
    }
  
    /**
     * Sets custom_attribute_value_exact
     * @param string $custom_attribute_value_exact 
     * @return $this
     */
    public function setCustomAttributeValueExact($custom_attribute_value_exact)
    {
        $this->custom_attribute_value_exact = $custom_attribute_value_exact;
        return $this;
    }
    /**
     * Gets custom_attribute_value_prefix
     * @return string
     */
    public function getCustomAttributeValuePrefix()
    {
        return $this->custom_attribute_value_prefix;
    }
  
    /**
     * Sets custom_attribute_value_prefix
     * @param string $custom_attribute_value_prefix 
     * @return $this
     */
    public function setCustomAttributeValuePrefix($custom_attribute_value_prefix)
    {
        $this->custom_attribute_value_prefix = $custom_attribute_value_prefix;
        return $this;
    }
    /**
     * Gets custom_attribute_min_value
     * @return string
     */
    public function getCustomAttributeMinValue()
    {
        return $this->custom_attribute_min_value;
    }
  
    /**
     * Sets custom_attribute_min_value
     * @param string $custom_attribute_min_value 
     * @return $this
     */
    public function setCustomAttributeMinValue($custom_attribute_min_value)
    {
        $this->custom_attribute_min_value = $custom_attribute_min_value;
        return $this;
    }
    /**
     * Gets custom_attribute_max_value
     * @return string
     */
    public function getCustomAttributeMaxValue()
    {
        return $this->custom_attribute_max_value;
    }
  
    /**
     * Sets custom_attribute_max_value
     * @param string $custom_attribute_max_value 
     * @return $this
     */
    public function setCustomAttributeMaxValue($custom_attribute_max_value)
    {
        $this->custom_attribute_max_value = $custom_attribute_max_value;
        return $this;
    }
    /**
     * Returns true if offset exists. False otherwise.
     * @param  integer $offset Offset 
     * @return boolean
     */
    public function offsetExists($offset)
    {
        return isset($this->$offset);
    }
  
    /**
     * Gets offset.
     * @param  integer $offset Offset 
     * @return mixed 
     */
    public function offsetGet($offset)
    {
        return $this->$offset;
    }
  
    /**
     * Sets value based on offset.
     * @param  integer $offset Offset 
     * @param  mixed   $value  Value to be set
     * @return void
     */
    public function offsetSet($offset, $value)
    {
        $this->$offset = $value;
    }
  
    /**
     * Unsets offset.
     * @param  integer $offset Offset 
     * @return void
     */
    public function offsetUnset($offset)
    {
        unset($this->$offset);
    }
  
    /**
     * Gets the string presentation of the object
     * @return string
     */
    public function __toString()
    {
        if (defined('JSON_PRETTY_PRINT')) {
            return json_encode(\SquareConnect\ObjectSerializer::sanitizeForSerialization($this), JSON_PRETTY_PRINT);
        } else {
            return json_encode(\SquareConnect\ObjectSerializer::sanitizeForSerialization($this));
        }
    }
}
