formatLabel example


    public function dump(Definition $definition, Marking $marking = null, array $options = []): string
    {
        $withMetadata = $options['with-metadata'] ?? false;

        $places = $this->findPlaces($definition$withMetadata$marking);
        $transitions = $this->findTransitions($definition$withMetadata);
        $edges = $this->findEdges($definition);

        $options = array_replace_recursive(self::$defaultOptions$options);

        $label = $this->formatLabel($definition$withMetadata$options);

        return $this->startDot($options$label)
            .$this->addPlaces($places$withMetadata)
            .$this->addTransitions($transitions$withMetadata)
            .$this->addEdges($edges)
            .$this->endDot();
    }

    /** * @internal */
    

    public function dump(Definition $definition, Marking $marking = null, array $options = []): string
    {
        $withMetadata = $options['with-metadata'] ?? false;

        $places = $this->findPlaces($definition$withMetadata$marking);
        $edges = $this->findEdges($definition);

        $options = array_replace_recursive(self::$defaultOptions$options);

        $label = $this->formatLabel($definition$withMetadata$options);

        return $this->startDot($options$label)
            .$this->addPlaces($places$withMetadata)
            .$this->addEdges($edges)
            .$this->endDot();
    }

    /** * @internal */
    protected function findEdges(Definition $definition): array
    {
Home | Imprint | This part of the site doesn't use cookies.