Code Duplication    Length = 12-12 lines in 3 locations

src/DataGrid.php 3 locations

@@ 1001-1012 (lines=12) @@
998
	 * @return Filter\FilterSelect
999
	 * @throws DataGridException
1000
	 */
1001
	public function addFilterSelect($key, $name, array $options, $column = NULL)
1002
	{
1003
		$column = $column ?: $key;
1004
1005
		if (!is_string($column)) {
1006
			throw new DataGridException("Filter Select can only filter in one column.");
1007
		}
1008
1009
		$this->addFilterCheck($key);
1010
1011
		return $this->filters[$key] = new Filter\FilterSelect($key, $name, $options, $column);
1012
	}
1013
1014
1015
	/**
@@ 1068-1079 (lines=12) @@
1065
	 * @return Filter\FilterRange
1066
	 * @throws DataGridException
1067
	 */
1068
	public function addFilterRange($key, $name, $column = NULL, $name_second = '-')
1069
	{
1070
		$column = $column ?: $key;
1071
1072
		if (!is_string($column)) {
1073
			throw new DataGridException("FilterRange can only filter in one column.");
1074
		}
1075
1076
		$this->addFilterCheck($key);
1077
1078
		return $this->filters[$key] = new Filter\FilterRange($key, $name, $column, $name_second);
1079
	}
1080
1081
1082
	/**
@@ 1090-1101 (lines=12) @@
1087
	 * @return Filter\FilterDateRange
1088
	 * @throws DataGridException
1089
	 */
1090
	public function addFilterDateRange($key, $name, $column = NULL, $name_second = '-')
1091
	{
1092
		$column = $column ?: $key;
1093
1094
		if (!is_string($column)) {
1095
			throw new DataGridException("FilterDateRange can only filter in one column.");
1096
		}
1097
1098
		$this->addFilterCheck($key);
1099
1100
		return $this->filters[$key] = new Filter\FilterDateRange($key, $name, $column, $name_second);
1101
	}
1102
1103
1104
	/**