Class slamcore::TaskStatusInterface

class slamcore::TaskStatusInterface : public ObjectInterface

Task status object.

Public Types

enum TaskState

Values:

enumerator Idle
enumerator Progress
enumerator Success
enumerator Cancelled
enumerator Error
enumerator Count
using Ptr = std::shared_ptr<TaskStatusInterface>
using CPtr = std::shared_ptr<const TaskStatusInterface>

Public Functions

inline virtual ObjectType type() const

Type of the object.

virtual ~TaskStatusInterface() = default
virtual TaskType getType() const = 0

Return the type associated with this task.

virtual IDT getID() const = 0

Return the unique identifier among tasks of the same type.

virtual TaskState getState() const = 0

Return the current state of this task.

virtual std::error_code getError() const = 0

Return task error, if any.

Note

If the task has been cancelled, std::errc::operation_canceled is returned.