ScanEntry class final

The count of one key in a ScanSession.

Constructors

ScanEntry({required String key, required int quantity, required DateTime firstAt, required DateTime updatedAt, String? label, ScanCode? lastCode})
Creates an entry.
const
ScanEntry.fromJson(Map<String, Object?> json)
Reads a map written by toJson. Throws a FormatException for malformed input.
factory

Properties

firstAt → DateTime
When the entry was created.
final
hashCode → int
The hash code for this object.
no setteroverride
key → String
The count key: the code value, or the key chosen by the validator.
final
label → String?
Display label from the validator, if any.
final
lastCode → ScanCode?
The most recent code counted under this key; null for entries created by hand.
final
quantity → int
The counted quantity (never negative).
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
updatedAt → DateTime
When the entry last changed.
final

Methods

copyWith({int? quantity, String? label, ScanCode? lastCode, DateTime? updatedAt}) → ScanEntry
A copy with the given fields replaced.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, Object?>
A JSON-compatible map.
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override