package Default

 Methods

__construct()

__construct(string $filename, boolean $includeIfNotAlreadyIncluded = false

Parameters

$filename

string

$includeIfNotAlreadyIncluded

boolean

Exceptions

\Zend\Code\Reflection\Exception\InvalidArgumentException If file does not exists
\Zend\Code\Reflection\Exception\RuntimeException If file exists but is not included or required

Serialize to string

__toString() : string

Required by the Reflector interface

todo What should this serialization look like?

Returns

string

Required by the Reflector interface.

export() : null
Static
todo What should this do?

Returns

null

Retrieve the reflection class of a given class found in this file

getClass(null|string $name = null) : \Zend\Code\Reflection\ClassReflection

Parameters

$name

nullstring

Exceptions

\Zend\Code\Reflection\Exception\InvalidArgumentException for invalid class name or invalid reflection class

Returns

\Zend\Code\Reflection\ClassReflection

Return the reflection classes of the classes found inside this file

getClasses() : array<mixed,\Zend\Code\Reflection\ClassReflection>

Returns

array<mixed,\Zend\Code\Reflection\ClassReflection>

Return the full contents of file

getContents() : string

Returns

string

getDocBlock()

getDocBlock() : \Zend\Code\Reflection\DocBlockReflection

Returns

\Zend\Code\Reflection\DocBlockReflection

getDocComment()

getDocComment() : string

Returns

string

Get the end line / number of lines

getEndLine() : integer

Returns

integer

Return the file name of the reflected file

getFileName() : string

Returns

string

Return the reflection functions of the functions found inside this file

getFunctions() : array<mixed,\Zend\Code\Reflection\FunctionReflection>

Returns

array<mixed,\Zend\Code\Reflection\FunctionReflection>

getNamespace()

getNamespace() : string

Returns

string

getNamespaces()

getNamespaces() : array<mixed,string>

Returns

array<mixed,string>

Get the start line - Always 1, staying consistent with the Reflection API

getStartLine() : integer

Returns

integer

getUses()

getUses() : array

Returns

array

toString()

toString() 
inherited_from \Zend\Code\Reflection\ReflectionInterface::toString()

Validate / check a file level DocBlock

checkFileDocBlock(array $tokens) : void

Parameters

$tokens

array

Array of tokenizer tokens

This method does the work of "reflecting" the file

reflect() : void

Uses Zend\Code\Scanner\FileScanner to gather file information

 Properties

 

$classes

$classes : array<mixed,\Zend\Code\Reflection\ClassReflection>

Default

array()
 

$contents

$contents : string

Default

null
 

$docComment

$docComment : string

Default

null
 

$endLine

$endLine : integer

Default

null
 

$filePath

$filePath : string

Default

null
 

$functions

$functions : array<mixed,\Zend\Code\Reflection\FunctionReflection>

Default

array()
 

$namespaces

$namespaces : array<mixed,string>

Default

array()
 

$requiredFiles

$requiredFiles : array<mixed,string>

Default

array()
 

$startLine

$startLine : integer

Default

1
 

$uses

$uses : array<mixed,string>

Default

array()