|
AIM
|
#include <TaskDescription.h>
Public Types | |
| enum | Status { UNKNOWN, SUCCEEDED, FAILED } |
| enum | Type { NONE = 0, BE_ACTIVE, SLEEP, BE_RESILIENT, CALIBRATING, SLEEP_PERIOD_STAY_AWAKE, SLEEP_PERIOD_GO_TO_SLEEP, TAKE_MELATONIN, SLEEPY, UNWINDING, WAKING_UP, ACTIVE, BRIGHT_LIGHT, DIMMED_LIGHT, EXERCISE, TAKE_CAFFEINE, HAVE_BREAKFAST, HAVE_LUNCH, HAVE_DINNER, HAVE_SNACK, EAT_EXTRA_TODAY, FIRST_NIGHT_MELATONIN, FULLY_ADJUSTED, TASK_MR_WORRIES, TASK_MR_CONTROL, TASK_MR_SUPPORT, TASK_MR_FLEXIBILITY, TASK_MR_CONFIDENCE, TASK_MR_MOTIVATION, TASK_MR_RELAXATION } |
Public Member Functions | |
| TaskDescription (Type taskTypeId, double startDate, double endDate, std::string description, AIMValue target) | |
| TaskDescription (const TaskDescription &other) | |
| TaskDescription () | |
| virtual double | getStartDate () const |
| virtual double | getEndDate () const |
| virtual std::string | getDescription () const |
| virtual AIMValue | getTarget () const |
| virtual AIMValue | getCurrentValue () const |
| virtual Status | getStatus () const |
| virtual Type | getTaskType () const |
| virtual bool | isCompleted () |
| virtual AIMValue | aimValueRepresentation () |
Static Public Member Functions | |
| static std::string | taskTypeToString (Type taskType) |
| static Type | stringToTaskType (std::string taskType) |
Protected Attributes | |
| Type | taskType |
| double | startDate |
| double | endDate |
| std::string | description |
| AIMValue | target |
| AIMValue | currentValue |
| Status | status |
| bool | completed |
Description of a task that can be set by the coach. Represents the task as communicated to the 'outside' world.
Status representing whether a task has been achieved.
Task type. Note: This should be in sync with the database backend in the cloud and the mobile platforms in Cortex!
| CoachingEngine::TaskDescription::TaskDescription | ( | Type | taskTypeId, |
| double | startDate, | ||
| double | endDate, | ||
| std::string | description, | ||
| AIMValue | target | ||
| ) |
Construct a TaskDescription with all immutable fields.
| taskTypeId | Identifier for the task type. |
| startDate | Unix timestamp when the task starts. |
| endDate | Unix timestamp when the task ends. |
| description | Human readable description of the task. |
| target | Target of the task. |
| CoachingEngine::TaskDescription::TaskDescription | ( | const TaskDescription & | other | ) |
Copy constructor.
| CoachingEngine::TaskDescription::TaskDescription | ( | ) |
Default constructor Needed for the TaskVector template in swig
|
virtual |
Return an aimvalue representation of the task.
|
inlinevirtual |
Get current value of the task. The current value is related to the target value.
|
inlinevirtual |
Get human readable description of the task.
|
inlinevirtual |
Get end date of the task as Unix timestamp.
|
inlinevirtual |
Get start date of the task as Unix timestamp.
|
inlinevirtual |
Get status of the task. The status represents wehther the target is achieved (SUCCEEDED), not achieved (FAILED), or this information is unknown (UNKNOWN)
|
inlinevirtual |
Get target of the task.
|
inlinevirtual |
Get task type identifier.
|
inlinevirtual |
Return whether the task is completed.