Documentation

Project
in package
implements Project

Represents the entire project with its files, namespaces and indexes.

Interfaces, Classes and Traits

Project
Interface for project. Since the definition of a project can be different per factory this interface will be small.

Table of Contents

$files  : array<string|int, mixed>
$name  : string
$namespaces  : array<string|int, mixed>
$rootNamespace  : Namespace_|null
__construct()  : mixed
Initializes this descriptor.
addFile()  : void
Add a file to this project.
addNamespace()  : void
Add a namespace to the project.
getFiles()  : array<string|int, File>
Returns all files with their sub-elements.
getName()  : string
Returns the name of this project.
getNamespaces()  : array<string|int, Namespace_>
Returns all namespaces with their sub-elements.
getRootNamespace()  : Namespace_|null
Returns the root (global) namespace.

Properties

$files

private array<string|int, mixed> $files = []

$namespaces

private array<string|int, mixed> $namespaces = []

Methods

__construct()

Initializes this descriptor.

public __construct(string $name[, Namespace_|null $namespace = null ]) : mixed
Parameters
$name : string

Name of the current project.

$namespace : Namespace_|null = null

Root namespace of the project.

Return values
mixed

addFile()

Add a file to this project.

public addFile(File $file) : void
Parameters
$file : File
Return values
void

addNamespace()

Add a namespace to the project.

public addNamespace(Namespace_ $namespace) : void
Parameters
$namespace : Namespace_
Return values
void

getFiles()

Returns all files with their sub-elements.

public getFiles() : array<string|int, File>
Return values
array<string|int, File>

getName()

Returns the name of this project.

public getName() : string
Return values
string

getNamespaces()

Returns all namespaces with their sub-elements.

public getNamespaces() : array<string|int, Namespace_>
Return values
array<string|int, Namespace_>

Search results