Message class

A structured message object. Used to return errors from requests.

Constructors

Message({required String format, required int id, bool? sendTelemetry, bool? showUser, String? url, String? urlLabel, Map<String, Object?>? variables})
Message.fromMap(Map<String, Object?> obj)

Properties

format → String
A format string for the message. Embedded variables have the form {name}. If variable name starts with an underscore character, the variable does not contain user data (PII) and can be safely used for telemetry purposes.
final
hashCode → int
The hash code for this object.
no setterinherited
id → int
Unique (within a debug adapter implementation) identifier for the message. The purpose of these error IDs is to help extension authors that have the requirement that every user visible error message needs a corresponding error number, so that users or customer support can find information about the specific error more easily.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sendTelemetry → bool?
If true send to telemetry.
final
showUser → bool?
If true show user.
final
url → String?
A url where additional information about this message can be found.
final
urlLabel → String?
A label that is presented to the user as the UI for opening the url.
final
variables → Map<String, Object?>?
An object used as a dictionary for looking up the variables in the format string.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() → Map<String, Object?>
toString() → String
A string representation of this object.
inherited

Operators

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

Static Methods

canParse(Object? obj) → bool
fromJson(Map<String, Object?> obj) → Message