public static function PHP_Token_Stream_CachingFactory::get in Zircon Profile 8.0
Same name and namespace in other branches
- 8 vendor/phpunit/php-token-stream/src/Token/Stream/CachingFactory.php \PHP_Token_Stream_CachingFactory::get()
Parameters
string $filename:
Return value
2 calls to PHP_Token_Stream_CachingFactory::get()
- PHP_CodeCoverage::getLinesToBeIgnored in vendor/
phpunit/ php-code-coverage/ src/ CodeCoverage.php - Returns the lines of a source file that should be ignored.
- PHP_CodeCoverage_Report_Node_File::calculateStatistics in vendor/
phpunit/ php-code-coverage/ src/ CodeCoverage/ Report/ Node/ File.php - Calculates coverage statistics for the file.
File
- vendor/
phpunit/ php-token-stream/ src/ Token/ Stream/ CachingFactory.php, line 31
Class
- PHP_Token_Stream_CachingFactory
- A caching factory for token stream objects.
Code
public static function get($filename) {
if (!isset(self::$cache[$filename])) {
self::$cache[$filename] = new PHP_Token_Stream($filename);
}
return self::$cache[$filename];
}