Test class

Contains the test data that is then displayed in "view my tests". Its fields are

date Date of the test

hand Hand the test is done with

displayed Number of symbols displayed in total

mistakes Number of mistakes made

Constructors

Test.new({DateTime? date, String? hand, int? displayed, int? mistakes})
Test.fromJson(Map<String, dynamic> json)
Takes the Map json as an argument and assigns values to date, hand, displayed and mistakes Used when loading data from SharedPreferences
factory

Properties

date DateTime?
getter/setter pair
displayed int?
getter/setter pair
hand String?
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
mistakes int?
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setDate(DateTime d) → void
Assigns the argument d to date
setDisplayed(int d) → void
Assigns the argument d to displayed
setHand(String h) → void
Assigns the argument h to hand
setMistakes(int m) → void
Assigns the argument m to mistakes
toJson() Map<String, dynamic>
Creates a Map in JSon format so data can be saved in SharedPreferences
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited