1
0
mirror of synced 2025-01-31 04:21:44 +03:00

Allow if parameter exists in SQLFilter

This commit is contained in:
Miro Demovic 2014-02-26 08:55:09 +01:00
parent f5897d4b0b
commit 1921c2f74a

View File

@ -107,6 +107,22 @@ abstract class SQLFilter
return $this->em->getConnection()->quote($this->parameters[$name]['value'], $this->parameters[$name]['type']);
}
/**
* Checks if a parameter was set for the filter.
*
* @param string $name Name of the parameter.
*
* @return boolean
*/
final public function hasParameter($name)
{
if (!isset($this->parameters[$name])) {
return false;
}
return true;
}
/**
* Returns as string representation of the SQLFilter parameters (the state).
*