ProjectCapabilities
Captures which documentation, testing, and wiki surfaces are available for the current repository.
Properties
Methods
Creates a repository capability snapshot for reporting and documentation commands.
Detects whether the repository exposes autoloaded PHP API source.
Detects whether the repository can generate guides, API documentation, or both.
Detects whether metrics generation can analyse repository history and package metadata.
Detects whether wiki generation can render API documentation into the configured wiki target.
Detects whether the repository has enough PHP surface to justify running tests.
Returns the project-relative directories that expose autoloaded PHP API source.
Returns the default API package name when one can be derived from Composer namespaces.
Detects whether the configured guide directory exists.
Detects whether the repository exposes autoloaded PHP source that can be tested.
Detects whether the configured tests directory exists.
Detects whether the configured wiki target exists.
private
array<string|int, mixed>
$apiDirectories
private
string|null
$defaultPackageName
private
bool
$hasGuideDirectory
private
bool
$hasPhpSourceFiles
private
bool
$hasTestsPath
private
bool
$hasWikiTarget
Creates a repository capability snapshot for reporting and documentation commands.
public
__construct(
array<int, string>
$apiDirectories,
string|null
$defaultPackageName,
bool
$hasGuideDirectory,
bool
$hasTestsPath,
bool
$hasWikiTarget,
bool
$hasPhpSourceFiles) : mixed
Parameters
$apiDirectories
:
array<int, string>
Description
project-relative directories that contain autoloaded PHP API source
$defaultPackageName
:
string|null
Description
the default package name derived from Composer namespaces when available
$hasGuideDirectory
:
bool
Description
whether the configured guide directory exists
$hasTestsPath
:
bool
Description
whether the configured tests path exists
$hasWikiTarget
:
bool
Description
whether the configured wiki target exists
$hasPhpSourceFiles
:
bool
Description
whether the repository exposes autoloaded PHP source that can be tested
Detects whether the repository exposes autoloaded PHP API source.
public
canGenerateApiDocumentation() : bool
Return values
Detects whether the repository can generate guides, API documentation, or both.
public
canGenerateDocs() : bool
Return values
Detects whether metrics generation can analyse repository history and package metadata.
public
canGenerateMetrics() : bool
Return values
Detects whether wiki generation can render API documentation into the configured wiki target.
public
canGenerateWiki() : bool
Return values
Detects whether the repository has enough PHP surface to justify running tests.
public
canRunTests() : bool
Return values
Returns the project-relative directories that expose autoloaded PHP API source.
public
getApiDirectories() : array<string|int, mixed>
Return values
Returns the default API package name when one can be derived from Composer namespaces.
public
getDefaultPackageName() : string|null
Return values
Detects whether the configured guide directory exists.
public
hasGuideDirectory() : bool
Return values
Detects whether the repository exposes autoloaded PHP source that can be tested.
public
hasPhpSourceFiles() : bool
Return values
Detects whether the configured tests directory exists.
public
hasTestsPath() : bool
Return values
Detects whether the configured wiki target exists.
public
hasWikiTarget() : bool