File tree Expand file tree Collapse file tree 1 file changed +7
-16
lines changed Expand file tree Collapse file tree 1 file changed +7
-16
lines changed Original file line number Diff line number Diff line change @@ -72,22 +72,13 @@ private function renderEntries(array $entries): void
72
72
{
73
73
$ relation = new Relation ($ entries , $ this ->options );
74
74
75
- switch ($ this ->options ->diagram ()) {
76
- case Options::DIAGRAM_CLASS :
77
- $ this ->renderDiagramClass ($ relation );
78
- break ;
79
- case OPTIONS ::DIAGRAM_PACKAGE :
80
- $ this ->renderDiagramPackage ($ relation );
81
- break ;
82
- case OPTIONS ::DIAGRAM_JIG :
83
- $ this ->renderDiagramJig ($ relation );
84
- break ;
85
- case OPTIONS ::DIAGRAM_DIVSION :
86
- $ this ->renderDiagramVivsion ($ relation );
87
- break ;
88
- default :
89
- throw new RuntimeException ('invalid diagram. ' );
90
- }
75
+ match ($ this ->options ->diagram ()) {
76
+ Options::DIAGRAM_CLASS => $ this ->renderDiagramClass ($ relation ),
77
+ OPTIONS ::DIAGRAM_PACKAGE => $ this ->renderDiagramPackage ($ relation ),
78
+ OPTIONS ::DIAGRAM_JIG => $ this ->renderDiagramJig ($ relation ),
79
+ OPTIONS ::DIAGRAM_DIVSION => $ this ->renderDiagramVivsion ($ relation ),
80
+ default => throw new RuntimeException ('invalid diagram. ' )
81
+ };
91
82
}
92
83
93
84
private function renderDiagramClass (Relation $ relation ): void
You can’t perform that action at this time.
0 commit comments