Laravel\Lumen\Application::runningInConsole PHP Method

runningInConsole() public method

Determine if the application is running in the console.
public runningInConsole ( ) : boolean
return boolean
    public function runningInConsole()
    {
        return php_sapi_name() == 'cli';
    }

Usage Example

コード例 #1
0
 /**
  * Determine if the application is running in the console.
  *
  * @return string 
  * @static 
  */
 public static function runningInConsole()
 {
     return \Laravel\Lumen\Application::runningInConsole();
 }