Graph
extends WriterAbstract
in package
implements
WithCustomSettings
Writer responsible for generating various graphs.
The Graph writer is capable of generating a Graph (as provided using the 'source' parameter) at the location provided using the artifact parameter.
Currently supported:
- 'class' (default), a Class Diagram generated using GraphViz
Interfaces, Classes and Traits
- WithCustomSettings
- Declares that the service implementing this interface yields its own settings.
Table of Contents
- $classDiagramGenerator : GraphVizClassDiagram
- $plantumlClassDiagram : PlantumlClassDiagram
- __construct() : mixed
- __toString() : string
- checkRequirements() : void
- This method verifies whether PHP has all requirements needed to run this writer.
- getDefaultSettings() : array<string, bool>
- transform() : void
- Generates a UML class diagram using PlantUML or our native GraphViz integration.
- getDestinationPath() : string
Properties
$classDiagramGenerator
private
GraphVizClassDiagram
$classDiagramGenerator
$plantumlClassDiagram
private
PlantumlClassDiagram
$plantumlClassDiagram
Methods
__construct()
public
__construct(GraphVizClassDiagram $classDiagramGenerator, PlantumlClassDiagram $plantumlClassDiagram) : mixed
Parameters
- $classDiagramGenerator : GraphVizClassDiagram
- $plantumlClassDiagram : PlantumlClassDiagram
Return values
mixed —__toString()
public
__toString() : string
Return values
string —checkRequirements()
This method verifies whether PHP has all requirements needed to run this writer.
public
checkRequirements() : void
If one of the requirements is missing for this Writer then an exception of type RequirementMissing should be thrown; this indicates to the calling process that this writer will not function.
Tags
Return values
void —getDefaultSettings()
public
getDefaultSettings() : array<string, bool>
Return values
array<string, bool> —transform()
Generates a UML class diagram using PlantUML or our native GraphViz integration.
public
transform(ProjectDescriptor $project, Transformation $transformation) : void
Parameters
- $project : ProjectDescriptor
-
Document containing the structure.
- $transformation : Transformation
-
Transformation to execute.
Return values
void —getDestinationPath()
private
getDestinationPath(Transformation $transformation) : string
Parameters
- $transformation : Transformation