Skip to main content



      Home
Home » Modeling » TMF (Xtext) » How to disable Parser-Markers in Project Explorer
How to disable Parser-Markers in Project Explorer [message #1810343] Thu, 08 August 2019 10:17 Go to next message
Eclipse UserFriend
Hi,

for my DSL I would like to implement the option to disable the creation of any problem markers for found problems in the problems view and project explorer. For the problems view, I can just use a filter in the UI. However, no such option exists for the project explorer.

How would I disable the generation of problem markers for my language? Ideally, the errors would still exist, but not shown, so that parsing and validation is still performed.

Regards,
Konrad
Re: How to disable Parser-Markers in Project Explorer [message #1810352 is a reply to message #1810343] Thu, 08 August 2019 12:27 Go to previous messageGo to next message
Eclipse UserFriend
hi, i wonder what your actual usecase for that. maybe the solution you have in mind is the wrong one.
markers are created by org.eclipse.xtext.ui.editor.validation.MarkerCreator.createMarker(Issue, IResource, String)
Re: How to disable Parser-Markers in Project Explorer [message #1810356 is a reply to message #1810352] Thu, 08 August 2019 14:13 Go to previous messageGo to next message
Eclipse UserFriend
Hi Christian,

I guess the case is special. We use two separate DSLs in our project, a business DSL A and a technical DSL B. A files compile to B files, which are then compiled to all sorts of SQL scripts and so on. This approach is kinda similar to XTend -> Java -> Bytecode.

The actual build process is standalone, though. So during the typical business day, a user *rarely* requires the later files (of type B or SQLs), although occasions arise where you would like to look into those.

However, our infrastructure is "a little" weak in the context I am working in. In order to cope with this, I have to keep the number of generated files to an absolute minimum as a simple eclipse-refresh (unrelated to XTtext) takes multiple seconds to complete (CPU power is fine). So, I build a feature to turn off generation of B files (and SQL files), as typically you don't need those. I used the IShouldGenerate approach, as recommended by you in another thread.

However, as some (but few) B files are created manually *and* relate to generated B files, there will always be errors due to unresolved B-references. I don't want users to bother with those if they are business level users, who will at most edit A-files.

My ideal solution would be to generate *all* B files or to not allow not-generated B files to refer to generated B files, but we are not quite there.

OK, wall of text. I am eager to hear if you have any other recommendations - otherwise thank you a lot for your hint!

Regards,
Konrad
Re: How to disable Parser-Markers in Project Explorer [message #1810369 is a reply to message #1810356] Thu, 08 August 2019 15:11 Go to previous messageGo to next message
Eclipse UserFriend
Depending on what the problem with generation performance is you could consider generation stubs only as Xtend does it for methods with errors
Re: How to disable Parser-Markers in Project Explorer [message #1810406 is a reply to message #1810369] Fri, 09 August 2019 11:53 Go to previous message
Eclipse UserFriend
Great idea, thank you. I will try it out.

Your hint with the MarkerCreator works perfectly, too.

Thanks!
Previous Topic:XText Web. How finds ACE the Language Server?
Next Topic:Maven build issues
Goto Forum:
  


Current Time: Wed May 07 10:59:40 EDT 2025

Powered by FUDForum. Page generated in 0.08043 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top