diff --git a/lib/Doctrine/ORM/Query/Filter/SQLFilter.php b/lib/Doctrine/ORM/Query/Filter/SQLFilter.php index fc749f151..2fe921b75 100644 --- a/lib/Doctrine/ORM/Query/Filter/SQLFilter.php +++ b/lib/Doctrine/ORM/Query/Filter/SQLFilter.php @@ -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). *