|
@@ -30,6 +30,14 @@ class GraphvizDumper extends Dumper
|
|
|
{
|
|
|
private $nodes;
|
|
|
private $edges;
|
|
|
+ private $options = array(
|
|
|
+ 'graph' => array('ratio' => 'compress'),
|
|
|
+ 'node' => array('fontsize' => 11, 'fontname' => 'Arial', 'shape' => 'record'),
|
|
|
+ 'edge' => array('fontsize' => 9, 'fontname' => 'Arial', 'color' => 'grey', 'arrowhead' => 'open', 'arrowsize' => 0.5),
|
|
|
+ 'node.instance' => array('fillcolor' => '#9999ff', 'style' => 'filled'),
|
|
|
+ 'node.definition' => array('fillcolor' => '#eeeeee'),
|
|
|
+ 'node.missing' => array('fillcolor' => '#ff9999', 'style' => 'filled'),
|
|
|
+ );
|
|
|
|
|
|
/**
|
|
|
* Dumps the service container as a graphviz graph.
|
|
@@ -49,15 +57,6 @@ class GraphvizDumper extends Dumper
|
|
|
*/
|
|
|
public function dump(array $options = array())
|
|
|
{
|
|
|
- $this->options = array(
|
|
|
- 'graph' => array('ratio' => 'compress'),
|
|
|
- 'node' => array('fontsize' => 11, 'fontname' => 'Arial', 'shape' => 'record'),
|
|
|
- 'edge' => array('fontsize' => 9, 'fontname' => 'Arial', 'color' => 'grey', 'arrowhead' => 'open', 'arrowsize' => 0.5),
|
|
|
- 'node.instance' => array('fillcolor' => '#9999ff', 'style' => 'filled'),
|
|
|
- 'node.definition' => array('fillcolor' => '#eeeeee'),
|
|
|
- 'node.missing' => array('fillcolor' => '#ff9999', 'style' => 'filled'),
|
|
|
- );
|
|
|
-
|
|
|
foreach (array('graph', 'node', 'edge', 'node.instance', 'node.definition', 'node.missing') as $key) {
|
|
|
if (isset($options[$key])) {
|
|
|
$this->options[$key] = array_merge($this->options[$key], $options[$key]);
|