DetectionStatus class

What ObservANT's /healthz says: its name, whether and when a cat was in view, and its visits.

Constructors

DetectionStatus({required String name, required bool inView, DateTime? lastSeen, int visits = 0, List<Visit> recent = const <Visit>[], DateTime? clip, List<DateTime> clips = const <DateTime>[], String? problem, List<String> peers = const <String>[], bool pixelated = false, List<String> classes = const <String>['cat'], bool dark = false})
const

Properties

classes → List<String>
The COCO classes it watches; an older camera that names none watches cats.
final
clip → DateTime?
The arrival /arrival.mp4 shows; a clip is encoded a few seconds after its arrival.
final
clips → List<DateTime>
Every arrival whose clip /arrival.mp4?t= still serves, newest first.
final
dark → bool
The camera sees black, so nothing can be detected: no IR at night.
final
hashCode → int
The hash code for this object.
no setterinherited
hasLatestClip → bool
The clip is of the newest visit, not one before it still waiting to be replaced.
no setter
inView → bool
final
lastSeen → DateTime?
final
name → String
final
peers → List<String>
The other ObservANT cameras' origins, as observant.toml lists them, for the overview.
final
pixelated → bool
ObservANT blocks out all but the detected animals (privacy = "pixelate").
final
problem → String?
Why the camera is not ok, in ObservANT's words; null while it delivers.
final
recent → List<Visit>
The latest visits, newest first.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
visits → int
Arrivals so far; each one replaces /arrival.jpg.
final

Methods

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

fromHealthz(String body) → DetectionStatus?
null for anything but an ObservANT camera's /healthz answer, so other hosts show nothing; one that is not ok still is one, with its problem.