This class represents an exception during the tag creation

Since the internals of the library are relaying on the correct syntax of a docblock
we cannot simply throw exceptions at all time because the exceptions will break the creation of a
docklock. Just silently ignore the exceptions is not an option because the user as an issue to fix.

This tag holds that error information until a using application is able to display it. The object wil just behave
like any normal tag. So the normal application flow will not break.

Cloneable Final
Methods
public __toString () : string
public static create ( string $body , string $name = '' ) : self
public getException () : Throwable
public getName () : string
public render ( ? phpDocumentor\Reflection\DocBlock\Tags\Formatter $formatter = NULL ) : string
public withError ( Throwable $exception ) : self
Properties
private $body
 
  • var string
private $name
 
  • var string
private $throwable
 
  • var Throwable | null
Methods
private __construct ( string $name , string $body )
private flattenArguments ( $value )
 
  • return mixed
  • throws ReflectionException
private flattenExceptionBacktrace ( Throwable $exception ) : void
 

Removes all complex types from backtrace

Not all objects are serializable. So we need to remove them from the
stored exception to be sure that we do not break existing library usage.

Methods
public static create ( string $body , string $name = '' ) : self
© 2020 Bruce Wells
Search Namespaces \ Classes
Configuration Numbers (0-9.) only