public function __construct($type)
{
if (!isset($this->types[$type])) {
throw new InvalidArgumentException(sprintf('Type specified for PHPUnit_Framework_Constraint_IsType <%s> ' . 'is not a valid type.', $type));
}
$this->type = $type;
}