classes/phing/tasks/ext/visualizer/VisualizerTask.php
public function setFormat(string $format): VisualizerTask
    {
        switch ($format) {
            case VisualizerTask::FORMAT_PUML:
            case VisualizerTask::FORMAT_PNG:
            case VisualizerTask::FORMAT_EPS:
            case VisualizerTask::FORMAT_SVG:
                $this->format = $format;
                break;
            default:
                $message = "'$format' is not a valid format";
                $this->log($message, Project::MSG_ERR);
                throw new BuildException($message);
                break;
        }

        return $this;
    }
public function setFormat(string $format): VisualizerTask
    {
        switch ($format) {
            case VisualizerTask::FORMAT_PUML:
            case VisualizerTask::FORMAT_PNG:
            case VisualizerTask::FORMAT_EPS:
            case VisualizerTask::FORMAT_SVG:
                $this->format = $format;
                break;
            default:
                $message = "'$format' is not a valid format";
                $this->log($message, Project::MSG_ERR);
                throw new BuildException($message);
                break;
        }

        return $this;
    }
public function setFormat ( string $ format ) : VisualizerTask { switch ( $ format ) { case VisualizerTask :: FORMAT_PUML : case VisualizerTask :: FORMAT_PNG : case VisualizerTask :: FORMAT_EPS : case VisualizerTask :: FORMAT_SVG : $ this -> format = $ format ; break ; default : $ message = "'$format' is not a valid format" ; $ this -> log ( $ message , Project :: MSG_ERR ) ; throw new BuildException ( $ message ) ; break ; } return $ this ; }
Sets and validates diagram's format

@param string $format

@return VisualizerTask
Sets and validates diagram s format