#include <Timer.h>
|
| | Timer (const Timer &)=delete |
| |
| | Timer (Timer &&)=delete |
| |
| Timer & | operator= (const Timer &)=delete |
| |
| Timer & | operator= (Timer &&)=delete |
| |
| template<typename Func , typename... Args> |
| void | DelayExecute (const Func &callback, int delay, Args &&... args) |
| | Executes function after X seconds.
|
| |
| template<typename Func , typename... Args> |
| void | DelayExecute (const FString &identifier, const Func &callback, int delay, Args &&... args) |
| | Executes function after X seconds.
|
| |
| template<typename Func , typename... Args> |
| void | RecurringExecute (const Func &callback, int execution_interval, int execution_counter, bool async, Args &&... args) |
| | Executes function every X seconds.
|
| |
| template<typename Func , typename... Args> |
| void | RecurringExecute (const FString &identifier, const Func &callback, int execution_interval, int execution_counter, bool async, Args &&... args) |
| | Executes function every X seconds.
|
| |
| void | UnloadTimer (const FString &identifier) |
| | Unloads timer by identifier.
|
| |
| void | UnloadAllTimers () |
| | Unloads all timers from the caller plugin.
|
| |
Definition at line 10 of file Timer.h.
◆ Timer() [1/3]
◆ Timer() [2/3]
| API::Timer::Timer |
( |
Timer && | | ) |
|
|
delete |
◆ Timer() [3/3]
◆ ~Timer()
◆ DelayExecute() [1/2]
template<
typename Func , typename... Args>
Executes function after X seconds.
- Parameters
-
| identifier | Unique identifier for the delay execute |
- Template Parameters
-
| Func | Callback function type |
| Args | Callback arguments types |
- Parameters
-
| callback | Callback function |
| delay | Delay in seconds |
| args | Callback arguments |
Definition at line 44 of file Timer.h.
◆ DelayExecute() [2/2]
template<
typename Func , typename... Args>
| void API::Timer::DelayExecute |
( |
const Func & | callback, |
|
|
int | delay, |
|
|
Args &&... | args ) |
|
inline |
Executes function after X seconds.
- Template Parameters
-
| Func | Callback function type |
| Args | Callback arguments types |
- Parameters
-
| callback | Callback function |
| delay | Delay in seconds |
| args | Callback arguments |
Definition at line 29 of file Timer.h.
◆ DelayExecuteInternal()
◆ Get()
| Timer & API::Timer::Get |
( |
| ) |
|
|
static |
◆ operator=() [1/2]
◆ operator=() [2/2]
◆ RecurringExecute() [1/2]
template<
typename Func , typename... Args>
| void API::Timer::RecurringExecute |
( |
const FString & | identifier, |
|
|
const Func & | callback, |
|
|
int | execution_interval, |
|
|
int | execution_counter, |
|
|
bool | async, |
|
|
Args &&... | args ) |
|
inline |
Executes function every X seconds.
- Parameters
-
| identifier | Unique identifier for the delay execute |
- Template Parameters
-
| Func | Callback function type |
| Args | Callback arguments types |
- Parameters
-
| callback | Callback function |
| execution_interval | Delay between executions in seconds |
| execution_counter | Amount of times to execute function, -1 for unlimited |
| async | If true, function will be executed in the new thread |
| args | Callback arguments |
Definition at line 80 of file Timer.h.
◆ RecurringExecute() [2/2]
template<
typename Func , typename... Args>
| void API::Timer::RecurringExecute |
( |
const Func & | callback, |
|
|
int | execution_interval, |
|
|
int | execution_counter, |
|
|
bool | async, |
|
|
Args &&... | args ) |
|
inline |
Executes function every X seconds.
- Template Parameters
-
| Func | Callback function type |
| Args | Callback arguments types |
- Parameters
-
| callback | Callback function |
| execution_interval | Delay between executions in seconds |
| execution_counter | Amount of times to execute function, -1 for unlimited |
| async | If true, function will be executed in the new thread |
| args | Callback arguments |
Definition at line 60 of file Timer.h.
◆ RecurringExecuteInternal()
◆ UnloadAllTimers()
| void API::Timer::UnloadAllTimers |
( |
| ) |
|
|
inline |
Unloads all timers from the caller plugin.
Definition at line 99 of file Timer.h.
◆ UnloadTimer()
Unloads timer by identifier.
- Parameters
-
| identifier | Unique identifier for the timer, either a delay execute or a recurring execute |
Definition at line 91 of file Timer.h.
◆ UnloadTimerInternal()
◆ UnloadTimersFromModule()
◆ Update()
| void API::Timer::Update |
( |
| ) |
|
|
private |
◆ PluginManager
◆ timer_funcs_
| std::vector<std::shared_ptr<TimerFunc> > API::Timer::timer_funcs_ |
|
private |
The documentation for this class was generated from the following files:
- C:/Users/lachl/Downloads/ArkServerAPI_NEW/ASA/AsaApi/AsaApi/Core/Public/Timer.h
- C:/Users/lachl/Downloads/ArkServerAPI_NEW/ASA/AsaApi/AsaApi/Core/Private/Tools/Timer.cpp