class Once (View source)
| static protected Once|null | $instance | The current globally used instance. | |
| static protected bool | $enabled | Indicates if the once instance is enabled. |
| void | __construct(WeakMap $values)
Create a new once instance. | |
| static Once | instance()
Create a new once instance. | |
| mixed | value(Onceable $onceable)
Get the value of the given onceable. | |
| static void | enable()
Re-enable the once instance if it was disabled. | |
| static void | disable()
Disable the once instance. | |
| static void | flush()
Flush the once instance. |
Create a new once instance.
Create a new once instance.
Get the value of the given onceable.
Re-enable the once instance if it was disabled.
Disable the once instance.
Flush the once instance.
© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/11.x/Illuminate/Support/Once.html