Skip to main content



      Home
Home » Modeling » TMF (Xtext) » UI model validation
UI model validation [message #1052937] Wed, 01 May 2013 09:32 Go to next message
Eclipse UserFriend
Currently I have some validation in the main project which the UI project interprets as markers. I would like move that validation from the main project to the UI project, so that the parser is not concerned about it. Also I would like to add validations which need some data from preferences, so these have to be in the UI project as well, aimed to enrich the UI experience. What is the best way to plug in several model validations (preferably separate) which would get the marker-displaying support of Xtext?

David
Re: UI model validation [message #1052939 is a reply to message #1052937] Wed, 01 May 2013 09:40 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

simply adding a binding similar to the one in the runtimemodule to the ui module doesnt work?
Re: UI model validation [message #1052957 is a reply to message #1052939] Wed, 01 May 2013 10:49 Go to previous messageGo to next message
Eclipse UserFriend
Thank you, it does! I didn't hope for it to ba that easy. It is not possible to bind multiple validators though. Also is there way to set when or how often the validation should be performed?
Re: UI model validation [message #1052971 is a reply to message #1052957] Wed, 01 May 2013 12:11 Go to previous messageGo to next message
Eclipse UserFriend
@Check(CheckType)
Re: UI model validation [message #1053027 is a reply to message #1052957] Thu, 02 May 2013 02:15 Go to previous message
Eclipse UserFriend
Hi,

as to multiple validators. You can let your UI-Validator extend the regular one and you can use the ComposedCheck annotation for "registering" further validator classes.

Alex
Previous Topic:data binding beteen xtext and swt
Next Topic:How to limit content assist according to scoping
Goto Forum:
  


Current Time: Wed Jul 23 06:06:53 EDT 2025

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

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

Back to the top