PDepend\Source\Tokenizer\Tokenizer::getSourceFile PHP Méthode

getSourceFile() public méthode

Returns the name of the source file.
public getSourceFile ( ) : string
Résultat string
    public function getSourceFile();

Usage Example

 /**
  * Constructs a new missing value exception.
  *
  * @param \PDepend\Source\Tokenizer\Tokenizer $tokenizer
  */
 public function __construct(Tokenizer $tokenizer)
 {
     // Get wrong token
     $token = $tokenizer->next();
     // The parser must take care for this
     assert($token instanceof Token);
     $message = sprintf('Missing default value on line: %d, col: %d, file: %s.', $token->startLine, $token->startColumn, $tokenizer->getSourceFile());
     parent::__construct($message);
 }
All Usage Examples Of PDepend\Source\Tokenizer\Tokenizer::getSourceFile