Eloquent\Phony\Pho\PhoFacadeDriver::instance PHP Method

instance() public static method

Get the static instance of this driver.
public static instance ( ) : FacadeDriver
return Eloquent\Phony\Facade\FacadeDriver The static driver.
    public static function instance()
    {
        if (!self::$instance) {
            self::$instance = new self();
        }
        return self::$instance;
    }

Usage Example

Beispiel #1
0
/**
 * Turn on or off the use of ANSI colored output.
 *
 * Pass `null` to detect automatically.
 *
 * @param bool|null $useColor True to use color.
 */
function setUseColor($useColor)
{
    $facade = PhoFacadeDriver::instance();
    $facade->assertionRenderer->setUseColor($useColor);
    $facade->differenceEngine->setUseColor($useColor);
}
All Usage Examples Of Eloquent\Phony\Pho\PhoFacadeDriver::instance