DebugStorage class

The single in-memory source of network logs.

DebugStorage() always returns the same instance and is a ChangeNotifier, so the UI updates automatically.

Inheritance

Constructors

DebugStorage()
factory

Properties

averageElapsedMs → int
Average duration of completed requests (ms).
no setter
count → int
no setter
errorCount → int
no setter
hashCode → int
The hash code for this object.
no setterinherited
hasListeners → bool
Whether any listeners are currently registered.
no setterinherited
isRecording → bool
no setter
maxRequests → int
no setter
pendingCount → int
no setter
requests → List<DebugModel>
Read-only list used by the UI (newest first).
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
successCount → int
no setter

Methods

addError(DioException dioError) → void
addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
addRequest(RequestOptions requestOptions) → void
addResponse(Response response) → void
clear() → void
configure({int? maxRequests}) → void
deleteAt(int index) → void
Deletes by index (old API, kept for compatibility).
deleteById(int id) → void
Deletes by id — indexes shift when the list changes.
deleteByIds(Iterable<int> ids) → void
deleteMultiple(List<int> indexes) → void
Deletes by indexes (old API, kept for compatibility).
dispose() → void
Discards any resources used by the object.
inherited
exportAll({bool redact = true}) → List<Map<String, dynamic>>
Converts all logs to JSON (for export / sharing).
findById(int id) → DebugModel?
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
setRecording(bool value) → void
toString() → String
A string representation of this object.
inherited

Operators

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