public function __construct($token, $entity, \Exception $previous) { parent::__construct(sprintf('Cannot evaluate toeken "%s" for entity with type "%s"', $token, get_class($entity)), 0, $previous); $this->token = $token; $this->entity = $entity; }