Copied!

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

Cloneable Instantiable
Methods
public __construct ( int $indent = 0 , string $indentString = ' ' , bool $indentFirstLine = true , ? int $lineLength = NULL , ? phpDocumentor\Reflection\DocBlock\Tags\Formatter $tagFormatter = NULL )
 

Create a Serializer instance.

public getDocComment ( phpDocumentor\Reflection\DocBlock $docblock ) : string
 

Generate a DocBlock comment.

  • return string The serialized doc block.
Properties
protected $indent
 
  • var int The number of times the indent string is repeated.
protected $indentString
 
  • var string The string to indent the comment with.
protected $isFirstLineIndented
 
  • var bool Whether to indent the first line with the given indent amount and string.
protected $lineLength
 
  • var int | null The max length of a line.
protected $tagFormatter
 
  • var Formatter A custom tag formatter.
Methods
private addAsterisksForEachLine ( string $indent , string $text ) : string
private addTagBlock ( phpDocumentor\Reflection\DocBlock $docblock , ? int $wrapLength , string $indent , string $comment ) : string
private getSummaryAndDescriptionTextBlock ( phpDocumentor\Reflection\DocBlock $docblock , ? int $wrapLength ) : string
private removeTrailingSpaces ( string $indent , string $text ) : string
© 2020 Bruce Wells
Search Namespaces \ Classes
Configuration Numbers (0-9.) only