CodeBlockFormatter
namespace |
bhenk\doc2rst\format |
predicates |
Cloneable | Instantiable |
implements |
|
extends |
|
hierarchy |
Renders a code block
This nameless formatter is handling everything between 3 tics that start on a new line and that are not followed by a formatter name. The block is ended with 3 tics on a new line.
syntax
```
<code>
<more code>
(...)
```
This is the result:
<code>
<more code>
(...)
Methods
CodeBlockFormatter::handleLine
predicates |
public |
implements |
@inheritdoc
Handle a line of PHPDoc
As long as the formatter wants more lines it should return true. When it has enough it should return false.
@inheritdoc from method AbstractFormatter::handleLine
public function handleLine(
Parameter #0 [ <required> string $line ]
): bool
CodeBlockFormatter::addLine
predicates |
protected |
inherited from |
Add a line to the resulting block
protected function addLine(
Parameter #0 [ <required> Stringable|string $line ]
): void
CodeBlockFormatter::__toString
predicates |
public |
implements |
|
inherited from |
Returns a reStructuredText representation of the contents of the block
public function __toString(): string
CodeBlockFormatter::getLineCount
predicates |
protected |
inherited from |
protected function getLineCount(): int
CodeBlockFormatter::increaseLineCount
predicates |
protected |
inherited from |
protected function increaseLineCount(): int
Fri, 31 Mar 2023 13:22:46 +0000