AppserverIo\Appserver\Core\ApplicationServer::runlevelToString PHP Метод

runlevelToString() публичный Метод

Translates and returns a string representation of the passed runlevel.
public runlevelToString ( integer $runlevel ) : string
$runlevel integer The runlevel to return the string representation for
Результат string The string representation for the passed runlevel
    public function runlevelToString($runlevel)
    {
        // flip the array with the string => integer runlevel definitions
        $runlevels = array_flip(Runlevels::singleton()->getRunlevels());
        if (isset($runlevels[$runlevel])) {
            return $runlevels[$runlevel];
        }
        // throw an exception if the runlevel is unknown
        throw new \Exception(sprintf('Request invalid runlevel to string conversion for %s', $runlevel));
    }