for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the Sylius package.
*
* (c) Paweł Jędrzejewski
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Sylius\Component\Grid\Definition;
/**
* @author Paweł Jędrzejewski <[email protected]>
class Filter
{
* @var string
private $name;
private $type;
private $label;
private $template;
* @var array
private $options = [];
* @param string $name
* @param string $type
private function __construct($name, $type)
$this->name = $name;
$this->type = $type;
$this->label = $name;
}
* @return self
public static function fromNameAndType($name, $type)
return new self($name, $type);
* @return string
public function getName()
return $this->name;
public function getType()
return $this->type;
public function getLabel()
return $this->label;
* @param string $label
public function setLabel($label)
$this->label = $label;
public function getTemplate()
return $this->template;
* @param string $template
public function setTemplate($template)
$this->template = $template;
* @return array
public function getOptions()
return $this->options;
* @param array $options
public function setOptions($options)
$this->options = $options;