public function setMatcher($matcher)
{
if (!$matcher instanceof Matcher\MatcherInterface && !is_callable($matcher)) {
throw new InvalidArgumentException(sprintf('The matcher must be callable, or implement \\Crummy\\Phlack\\Common\\Matcher\\MatcherInterface. "%" given.', is_object($matcher) ? get_class($matcher) : gettype($matcher)));
}
$this->matcher = $matcher;
return $this;
}