DevMessageV2 class

Enhanced dev message with granular update information.

Used for communication between dev server and browser client.

Constructors

DevMessageV2({required DevMessageType type, String? file, String? module, List<String>? components, Map<String, dynamic>? patch, String? error, String? stackTrace, DevMessageSeverity severity = DevMessageSeverity.info, SourceLocation? location, Map<String, dynamic>? data, int? timestamp})
const
DevMessageV2.buildError(String error, {String? stackTrace, SourceLocation? location})
Creates a build error message.
factory
DevMessageV2.clearErrors()
Creates a clear errors message.
factory
DevMessageV2.componentTreeResponse(Map<String, dynamic> tree)
Creates a component tree response.
factory
DevMessageV2.fromJson(Map<String, dynamic> json)
Creates from JSON map.
factory
DevMessageV2.fromJsonString(String jsonString)
Creates from JSON string.
factory
DevMessageV2.hotReload({String? file, List<String>? components})
Helper constructors for common message types. Creates a hot reload message.
factory
DevMessageV2.runtimeError(String error, {String? stackTrace, SourceLocation? location})
Creates a runtime error message.
factory
DevMessageV2.styleUpdate(String file, {Map<String, dynamic>? patch})
Creates a style update message for CSS hot injection.
factory

Properties

components List<String>?
List of components that need re-render.
final
data Map<String, dynamic>?
Arbitrary data payload.
final
error String?
Error message if applicable.
final
file String?
Affected file path.
final
hashCode int
The hash code for this object.
no setterinherited
location SourceLocation?
Source location for errors.
final
module String?
Specific module affected.
final
patch Map<String, dynamic>?
CSS/style patches for hot injection.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
severity DevMessageSeverity
Message severity.
final
stackTrace String?
Stack trace for errors.
final
timestamp int
Unix timestamp in milliseconds.
final
type DevMessageType
Message type.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts to JSON for WebSocket transmission.
toJsonString() String
Converts to JSON string.
toString() String
A string representation of this object.
inherited

Operators

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