MethodDoc
One method, as documented on the page of the class that declares it.
Synopsis
Section titled “Synopsis”final class MethodDoc
| Source | Ir/MethodDoc.php |
Properties
Section titled “Properties”| Property | Type | Description |
|---|---|---|
$abstract | bool | readonly. |
$doc | DocBlock | readonly. |
$final | bool | readonly. |
$fromTrait | ?``string | readonly. |
$name | string | readonly. |
$parameters | array | readonly. |
$returnType | TypeRef | readonly. |
$static | bool | readonly. |
$visibility | string | readonly. |
Constructor
Section titled “Constructor”__construct()
Section titled “__construct()”public function __construct(string $name, list<ParamDoc> $parameters, TypeRef $returnType, DocBlock $doc, 'public'|'protected' $visibility = 'public', bool $static = false, bool $abstract = false, bool $final = false, string|null $fromTrait = null): mixed
Fully-qualified trait this method was composed in from, if any.
| Parameter | Type | Description |
|---|---|---|
$name | string | |
$parameters | list``<ParamDoc> | |
$returnType | TypeRef | |
$doc | DocBlock | |
$visibility | `‘public’“ | “‘protected’` |
$static | bool | |
$abstract | bool | |
$final | bool | |
$fromTrait | `string“ | “null` |
Returns mixed
Methods
Section titled “Methods”| Method | Description |
|---|---|
shortSignature(): string | The compact form used in an at-a-glance table, without modifiers. |
signature(): string | The full signature line. |
shortSignature()
Section titled “shortSignature()”public function shortSignature(): string
The compact form used in an at-a-glance table, without modifiers.
Returns string
signature()
Section titled “signature()”public function signature(): string
The full signature line.
Modifiers are included because they are part of what a caller needs to know: a static method is called differently, and an abstract one has to be implemented.
Returns string