Loading...
Searching...
No Matches
AccelByte::FAccelByteTask Class Reference

#include <AccelByteTask.h>

Inheritance diagram for AccelByte::FAccelByteTask:

Public Member Functions

virtual bool Start ()
 Start the Task.
virtual EAccelByteTaskState Pause ()
 Pause the Task in the middle of the process.
virtual bool Cancel ()
 Stop the Task in the middle of the process.
virtual void Tick (double Time)
 Task Execution ticks.
virtual bool Finish ()
 Finish the Task.
virtual EAccelByteTaskState State () const
 Current State of the Task.
virtual double Time () const
 Get current Task Time.
FAccelByteCancellationToken GetCancellationToken ()
 Create Cancellation Token handler.

Protected Member Functions

void SetTaskState (EAccelByteTaskState NewState) noexcept
EAccelByteTaskState GetTaskState () const noexcept

Protected Attributes

std::atomic< double > TaskTime {0.0}
std::atomic< bool > bIsFinished {false}
FAccelByteCancellationTokenRef Token = MakeShared<FAccelByteCancellationTokenSource, ESPMode::ThreadSafe>()

Detailed Description

Base class for AccelByte Task that can be used in one of the schedulers

Member Function Documentation

◆ Cancel()

virtual bool AccelByte::FAccelByteTask::Cancel ( )
inlinevirtual

Stop the Task in the middle of the process.

Reimplemented in AccelByte::FHttpRetryTask.

◆ Finish()

virtual bool AccelByte::FAccelByteTask::Finish ( )
inlinevirtual

Finish the Task.

Reimplemented in AccelByte::FHttpRetryTask.

◆ Pause()

virtual EAccelByteTaskState AccelByte::FAccelByteTask::Pause ( )
inlinevirtual

Pause the Task in the middle of the process.

Reimplemented in AccelByte::FHttpRetryTask.

◆ Start()

virtual bool AccelByte::FAccelByteTask::Start ( )
inlinevirtual

Start the Task.

Reimplemented in AccelByte::FHttpRetryTask.

◆ Tick()

virtual void AccelByte::FAccelByteTask::Tick ( double Time)
inlinevirtual

Task Execution ticks.

Parameters
TimeTimer for the ticks

Reimplemented in AccelByte::FHttpRetryTask.