-
Notifications
You must be signed in to change notification settings - Fork 0
RemoveEmptyDocBlockRector
Implements automation targeting the removal of purposeless empty DocBlock structures natively.
It MUST intercept specific nodes exclusively and SHALL prune invalid redundant properties transparently.
- Full name:
\FastForward\DevTools\Rector\RemoveEmptyDocBlockRector - Parent class:
AbstractRector - This class is marked as final and can't be subclassed
- This class is a Final class
Resolves the defined documentation object detailing expected behavior parameters intrinsically.
public getRuleDefinition(): \Symplify\RuleDocGenerator\ValueObject\RuleDefinitionThe method MUST clarify accurately to external systems the primary objective successfully.
Return Value:
the instantiated declaration reference properly bounded natively
Exposes intercepted root AST targets consistently during analytical sweeps functionally.
public getNodeTypes(): array<int,class-string<\PhpParser\Node>>The method MUST enforce inspections primarily on class frames and class components cleanly.
Return Value:
bound runtime types reliably tracked correctly
Strips empty document definitions structurally from the designated AST dynamically parsed.
public refactor(\PhpParser\Node $node): \PhpParser\Node|nullThe method MUST systematically evaluate content verifying an absolute absence accurately. If validated, it SHALL destroy the related virtual node properties carefully.
Parameters:
| Parameter | Type | Description |
|---|---|---|
$node |
\PhpParser\Node | the dynamic input tree chunk inherently processed strictly |
Return Value:
the streamlined object successfully truncated or null unhandled