| Diagnostic vs. Diagnostic... [message #663423] |
Mon, 04 April 2011 21:00  |
Henrik Lindberg Messages: 2426 Registered: July 2009 |
Senior Member |
|
|
Hi,
I am moving some logic that I executed during validation to be performed
after linking. The way to report errors is quite different when getting
an IDiagnosticsConsumer instead of being able to call the error(...)
methods.
What is the correct way to report errors ("the same way as in the
validator")? I basically want to report errors against EObject features.
The "Diagnostic" accepted by the IDiagnosticConsumer is not the emf
Diagnostic that is used in the validator, and I found sublcasses for
Linking, Syntax, and Exception issues.
Should I just subclass AbstractDiagnostic ?
Regards
- henrik
|
|
|
|
|
| Re: Diagnostic vs. Diagnostic... [message #663540 is a reply to message #663538] |
Tue, 05 April 2011 10:38  |
Henrik Lindberg Messages: 2426 Registered: July 2009 |
Senior Member |
|
|
hm, actually, I can't find that it makes use of the index for the
feature in that logic.
- henrik
On 4/5/11 4:26 PM, Henrik Lindberg wrote:
> I can answer myself -
> org.eclipse.xtext.validation.DiagnosticConverterImpl
>
> *sigh*
> - henrik
>
> On 4/5/11 4:18 PM, Henrik Lindberg wrote:
>> Where is the logic that translates a FeatureBasedDiagnostic into a
>> node/location in source ?
>>
>> - henrik
>>
>> On 4/5/11 3:00 AM, Henrik Lindberg wrote:
>>> Hi,
>>> I am moving some logic that I executed during validation to be performed
>>> after linking. The way to report errors is quite different when getting
>>> an IDiagnosticsConsumer instead of being able to call the error(...)
>>> methods.
>>>
>>> What is the correct way to report errors ("the same way as in the
>>> validator")? I basically want to report errors against EObject features.
>>>
>>> The "Diagnostic" accepted by the IDiagnosticConsumer is not the emf
>>> Diagnostic that is used in the validator, and I found sublcasses for
>>> Linking, Syntax, and Exception issues.
>>>
>>> Should I just subclass AbstractDiagnostic ?
>>>
>>> Regards
>>> - henrik
>>
>
|
|
|
Powered by
FUDForum. Page generated in 0.05643 seconds