<?php public static function typeNotRegistered(Type $type): self
{
return new self(
sprintf('Type of the class %s@%s is not registered.', get_class($type), spl_object_hash($type))
);
}
<?php public static function typeAlreadyRegistered(Type $type): self
{
return new self(
sprintf('Type of the class %s@%s is already registered.', get_class($type), spl_object_hash($type))
);
}
}