SurveyHandler class
Constructors
- SurveyHandler({required File dismissedSurveyFile})
Properties
- dismissedSurveyFile → File
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
dismiss(
Survey survey, bool permanently) → void - Invoking this method will persist the survey's id in the local file with either a snooze or permanently dismissed indicator.
-
fetchPersistedSurveys(
) → Map< String, PersistedSurvey> - Retrieve a list of strings for each Survey persisted on disk.
-
fetchSurveyList(
) → Future< List< Survey> > -
Retrieves the survey metadata file from
kContextualSurveyUrl
. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
checkSurveyDate(
Survey survey) → bool -
Function to ensure that each survey is still valid by
checking the Survey.startDate and Survey.endDate
against the current
clock
now date. -
parseSurveysFromJson(
List body) → List< Survey> - Function that takes in a json data structure that is in the form of a list and returns a list of Survey items.