id = $id; } public function assert(Token $token): void { if (! $token->isIdentifiedBy($this->id)) { throw ConstraintViolation::error( 'The token is not identified with the expected ID', $this ); } } }