StudySubject class
Methods
allTasksCompletedFor (DateTime dateTime )
→ bool
Check if all tasks are fully completed on a given day
returns true if all of of the tasks (interventions & observations)
have been completed on a given day
completedForPhase (int index )
→ int
completedTaskForDay (String taskId , DateTime dateTime )
→ bool
Check if a task is fully completed for all task instances
returns true if a given task has been completed for all of its
completionPeriods on a given day
completedTaskInstanceForDay (String taskId , CompletionPeriod completionPeriod , DateTime dateTime )
→ bool
Check if a task instance is completed
returns true if a given task has been completed for a specific
completionPeriod on a given day
completedTasksFor (Task task )
→ int
dayAfterEndOfPhase (int index )
→ DateTime
daysLeftForPhase (int index )
→ int
delete ()
→ Future <StudySubject >
override
deleteProgress ()
→ Future <void >
endDate (DateTime dt )
→ DateTime
getDayOfStudyFor (DateTime date )
→ int
getInterventionForDate (DateTime date )
→ Intervention ?
getInterventionIndexForDate (DateTime date )
→ int
getInterventionsInOrder ()
→ List <Intervention >
getResultsByDate ({required String interventionId })
→ Map <DateTime , List <SubjectProgress > >
getTaskProgressForDay (String taskId , DateTime dateTime )
→ List <SubjectProgress >
noSuchMethod (Invocation invocation )
→ dynamic
Invoked when a nonexistent method or property is accessed.
inherited
percentCompletedForPhase (int index )
→ double
percentMissedForPhase (int index , DateTime date )
→ double
resultsFor (String taskId )
→ List <SubjectProgress >
save ({bool onlyUpdate = false })
→ Future <StudySubject >
Save the object to the database.
By default, this will upsert the object, i.e. insert it if it does not exist, or update it if it does.
If onlyUpdate
is set to true, the object has to exist in the database, otherwise the result will be empty.
override
scheduleFor (DateTime dateTime )
→ List <TaskInstance >
setStartDateBackBy ({required int days })
→ Future <void >
softDelete ()
→ Future <StudySubject >
startOfPhase (int index )
→ DateTime
toFullJson ({Map <String , dynamic > ? partialJson })
→ Map <String , dynamic >
toJson ()
→ Map <String , dynamic >
override
toString ()
→ String
A string representation of this object.
override
totalTaskCountFor (Task task )
→ int