file-fetcher
Public Member Functions | Protected Attributes | List of all members
phpDocumentor\Reflection\DocBlock\Serializer Class Reference

Detailed Description

Converts a DocBlock back from an object to a complete DocComment including Asterisks.

Public Member Functions

 __construct (int $indent=0, string $indentString=' ', bool $indentFirstLine=true, ?int $lineLength=null, ?Formatter $tagFormatter=null)
 
 getDocComment (DocBlock $docblock)
 

Protected Attributes

 $indentString = ' '
 
 $indent = 0
 
 $isFirstLineIndented = true
 
 $lineLength
 
 $tagFormatter
 

Constructor & Destructor Documentation

◆ __construct()

phpDocumentor\Reflection\DocBlock\Serializer::__construct ( int  $indent = 0,
string  $indentString = ' ',
bool  $indentFirstLine = true,
?int  $lineLength = null,
?Formatter  $tagFormatter = null 
)

Create a Serializer instance.

Parameters
int$indentThe number of times the indent string is repeated.
string$indentStringThe string to indent the comment with.
bool$indentFirstLineWhether to indent the first line.
int | null$lineLengthThe max length of a line or NULL to disable line wrapping.
Formatter$tagFormatterA custom tag formatter, defaults to PassthroughFormatter.

Member Function Documentation

◆ getDocComment()

phpDocumentor\Reflection\DocBlock\Serializer::getDocComment ( DocBlock  $docblock)

Generate a DocBlock comment.

Parameters
DocBlock$docblockThe DocBlock to serialize.
Returns
string The serialized doc block.

Member Data Documentation

◆ $indent

phpDocumentor\Reflection\DocBlock\Serializer::$indent = 0
protected

◆ $indentString

phpDocumentor\Reflection\DocBlock\Serializer::$indentString = ' '
protected

◆ $isFirstLineIndented

phpDocumentor\Reflection\DocBlock\Serializer::$isFirstLineIndented = true
protected

◆ $lineLength

phpDocumentor\Reflection\DocBlock\Serializer::$lineLength
protected

◆ $tagFormatter

phpDocumentor\Reflection\DocBlock\Serializer::$tagFormatter
protected

The documentation for this class was generated from the following file: