BPEditorState class

Manages all the state fields needed for the Blood Pressure Editor.

Constructors

BPEditorState()

Properties

currentEdit BPObservation?
The observation currently being edited.
getter/setter pair
diastolicController TextEditingController?
getter/setter pair
editingIndex int?
Index of the observation currently being edited, or null if none.
getter/setter pair
error String?
Error message if data loading fails.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
heartRateController TextEditingController?
getter/setter pair
isLoading bool
Whether data is currently loading (async).
getter/setter pair
isNewObservation bool
Flag tracking whether we are creating a new observation.
getter/setter pair
notesController TextEditingController?
getter/setter pair
observations List<BPObservation>
The list of loaded observations.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
systolicController TextEditingController?
Text editing controllers used for editing existing or new observations.
getter/setter pair

Methods

addNewObservation() → void
Add new blank observation at the top of the list and go to edit mode.
cancelEdit() → void
Resets editing fields and cancels the current edit.
deleteObservation(BuildContext context, dynamic editorService, BPObservation observation) Future<void>
Delete an observation from the Pod via the editorService.
disposeControllers() → void
Dispose of text controllers to prevent memory leaks.
enterEditMode(int index) → void
Enters edit mode for the observation at index.
initialiseControllers(BPObservation observation) → void
Prepares text controllers for a given observation.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
saveObservation(BuildContext context, dynamic editorService, int index) Future<void>
Save the observation at index, using the provided service.
toString() String
A string representation of this object.
inherited

Operators

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