# phpDocumentor

## NoteDirective extends AbstractAdmonitionDirective in package Default

A directive that parses the sub block and call the processSub that can be overloaded, like :

.. sub-directive:: Some block of code

You can imagine anything here, like adding emphasis, lists or titles

\$name  : string
\$text  : string
__construct()  : mixed
finalize()  : void
Called at the end of the parsing to finalize the document (add something or tweak nodes)
getName()  : string
Get the directive name
process()  : void
This is the function called by the parser to process the directive, it can be overloaded to do anything with the document, like tweaking nodes or change the environment
processAction()  : void
This can be overloaded to write a directive that just do an action without changing the nodes of the document
processNode()  : Node|null
This can be overloaded to write a directive that just create one node for the document, which is common
processSub()  : Node|null
wantCode()  : bool
Should the following block be passed as a CodeNode?

### Methods

#### __construct()

``` public __construct() : mixed```
mixed

#### finalize()

Called at the end of the parsing to finalize the document (add something or tweak nodes)

``` public finalize(DocumentNode \$document) : void```
##### Parameters
\$document : DocumentNode
void

#### getName()

Get the directive name

``` public abstract getName() : string```
string

#### process()

This is the function called by the parser to process the directive, it can be overloaded to do anything with the document, like tweaking nodes or change the environment

``` public process(Parser \$parser, Node|null \$node, string \$variable, string \$data, array<string|int, string> \$options) : void```

The node that directly follows the directive is also passed to it

##### Parameters
\$parser : Parser

the calling parser

\$node : Node|null

the node that follows the directive

\$variable : string

the variable name of the directive

\$data : string

the data of the directive (following ::)

\$options : array<string|int, string>

the array of options for this directive

void

#### processAction()

This can be overloaded to write a directive that just do an action without changing the nodes of the document

``` public processAction(Parser \$parser, string \$variable, string \$data, array<string|int, string> \$options) : void```

The arguments are the same that process

##### Parameters
\$parser : Parser
\$variable : string
\$data : string
\$options : array<string|int, string>
void

#### processNode()

This can be overloaded to write a directive that just create one node for the document, which is common

``` public processNode(Parser \$parser, string \$variable, string \$data, array<string|int, string> \$options) : Node|null```

The arguments are the same that process

##### Parameters
\$parser : Parser
\$variable : string
\$data : string
\$options : array<string|int, string>
Node|null

#### processSub()

``` public processSub(Parser \$parser, Node|null \$document, string \$variable, string \$data, array<string|int, string> \$options) : Node|null```
##### Parameters
\$parser : Parser
\$document : Node|null
\$variable : string
\$data : string
\$options : array<string|int, string>
Node|null

#### wantCode()

Should the following block be passed as a CodeNode?

``` public wantCode() : bool```
bool