eZ\Publish\Core\REST\Server\Output\ValueObjectVisitor\VersionInfo::getStatusString PHP Method

getStatusString() protected method

Maps the given version $status to a representative string.
protected getStatusString ( integer $status ) : string
$status integer
return string
    protected function getStatusString($status)
    {
        switch ($status) {
            case Values\Content\VersionInfo::STATUS_DRAFT:
                return 'DRAFT';
            case Values\Content\VersionInfo::STATUS_PUBLISHED:
                return 'PUBLISHED';
            case Values\Content\VersionInfo::STATUS_ARCHIVED:
                return 'ARCHIVED';
        }
        // @todo FIXME: What exception to use?
        throw new \Exception('Undefined version status: ' . $status);
    }