Returns the default value of a class member or method param.
Name | Type | Description |
---|---|---|
of | string | The reference to a class member or method param |
Source code:
<?php
class SomeClass
{
const SOME_CONST = 1;
private $someBool = false;
public function join($values, $separator = ', ')
{
}
}
Documentation source:
{{ defaultValue(of:'\SomeClass::SOME_CONST') }}
{{ defaultValue(of:'\SomeClass::$someBool') }}
{{ defaultValue(of:'\SomeClass::join(separator)') }}
Result:
1
false
,