classes/phing/tasks/ext/phpunit/PHPUnitUtil.php

\PHPUnitUtil

Various utility functions

author
Michiel Rook
package
phing.tasks.ext.phpunit
since
2.1.0
version
$Id: PHPUnitUtil.php 792 2010-06-24 12:56:45Z mrook $

Properties

Propertyprotected  $definedClasses= 'array'
static
Default valuearrayDetails
Type

Methods

methodpublic  getClassFromFileName( string $filename ) : string
staticDerives the classname from a filename.

Assumes that there is only one class defined in that particular file, and that the naming follows the dot-path (Java) notation scheme.

Parameters
Name Type Description
$filename string the filename
Returns
Type Description
string
methodpublic  getDefinedClasses( string $filename, \Path $classpath = NULL ) : array
static
Parameters
Name Type Description
$filename string the filename
$classpath \Path optional classpath
Returns
Type Description
array
methodpublic  getPackageName( string $classname ) : string
staticReturns the package of a class as defined in the docblock of the class using @package
Parameters
Name Type Description
$classname string the name of the class
Returns
Type Description
string
methodpublic  getSubpackageName( string $classname ) : string|null
staticReturns the subpackage of a class as defined in the docblock of the class using @subpackage
Parameters
Name Type Description
$classname string the name of the class
Returns
Type Description
stringnull
Details
author
Benjamin Schultz
Documentation was generated by DocBlox 0.13.1.