AnalysisError constructor
Initialize a newly created analysis error. The error is associated with
the given source and is located at the given offset with the given
length. The error will have the given errorCode and the list of
arguments will be used to complete the message and correction. If any
contextMessages are provided, they will be recorded with the error.
Implementation
@Deprecated('Use tmp constructor instead')
factory AnalysisError(
Source source,
int offset,
int length,
ErrorCode errorCode, [
List<Object?>? arguments,
List<DiagnosticMessage> contextMessages = const [],
Object? data,
]) {
return AnalysisError.tmp(
source: source,
offset: offset,
length: length,
errorCode: errorCode,
arguments: arguments ?? const [],
contextMessages: contextMessages,
data: data,
);
}