$translate
$translate : \phpDocumentor\Translator\Translator
Base class for DocBlock Validations.
$translate : \phpDocumentor\Translator\Translator
__construct(string $name, \phpDocumentor\Reflection\DocBlock|null $docblock = null, \phpDocumentor\Reflection\BaseReflector|null $source = null)
Constructor
string | $name | Name of the "entity" |
\phpDocumentor\Reflection\DocBlock|null | $docblock | Docblock |
\phpDocumentor\Reflection\BaseReflector|null | $source | Source Element. |
dispatch(string $name, \phpDocumentor\Event\EventAbstract $event) : void
Dispatches an event to the Event Dispatcher.
This method tries to dispatch an event; if no Event Dispatcher has been set than this method will explicitly not fail and return null.
By not failing we make the Event Dispatcher optional and is it easier for people to re-use this component in their own application.
string | $name | Name of the event to dispatch. |
\phpDocumentor\Event\EventAbstract | $event | Arguments for this event. |
if there is a dispatcher but it is not of type EventDispatcher
logParserError(string $type, string $code, string $line, array<mixed,string> $variables = array()) : void
Dispatches a parser error to be logged.
string | $type | The logging priority as string |
string | $code | The message to log. |
string | $line | The line number where the error occurred.. |
array<mixed,string> | $variables | an array with message substitution variables. |
__(string $message, array $variables = array()) : string
Translates the ID or message in the given language.
Translation messages may contain any formatting as used by the php vsprintf function.
string | $message | ID or message to translate. |
array | $variables | Variables to use for substitution. |
getEventDispatcher() : \phpDocumentor\Event\Dispatcher
Returns the event dispatcher.
getTranslator() : \phpDocumentor\Translator\Translator|null
Returns the translation component.