Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » Validation only FAST and NORMAL
Validation only FAST and NORMAL [message #1827026] Wed, 06 May 2020 09:02 Go to next message
Martin Jedlicka is currently offline Martin JedlickaFriend
Messages: 122
Registered: January 2016
Senior Member
Hi,

I have a question about validations in Sirius. I need that EXPENSIVE type validations are not validated (ie only NORMAL and FAST).

In xtext, this is done simply with CheckMode:
ValidationJob validationJob = new ValidationJob(resourceValidator, xtextDocument, issueProcessor, CheckMode.NORMAL_AND_FAST);


But I don't know how to do it in Sirius. I call validation:
ValidateAction.runValidation(((IDiagramWorkbenchPart) this).getDiagramEditPart(), this.getDiagram());


Thanks for any advice.

Martin
Re: Validation only FAST and NORMAL [message #1827107 is a reply to message #1827026] Thu, 07 May 2020 09:33 Go to previous message
Pierre-Charles David is currently offline Pierre-Charles DavidFriend
Messages: 548
Registered: July 2009
Senior Member
Hi Martin,

I believe CheckMode is an Xtext-specific concept, and we do not provide an equivalent in Sirius.

I am not familiar enough with that part of Xtext to say how this could be supported. Sirius relies on EMF Validation to invoke the validation rules, and gets an IBatchValidator by calling

ModelValidationService.getInstance().newValidator(EvaluationMode.BATCH)


This is hard-coded at the moment, but if Xtext integrates with EMF Validation, maybe we could offer a variant of ValidateAction.runValidation(View) where you could provide one from Xtext with the proper CheckMode?

Regards,
Pierre-Charles


Pierre-Charles David - Obeo

Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
Previous Topic:Problem in opening Eclipse with Sirius projects
Next Topic:Making a EAttribute of a EClass read-only in a Sirius model
Goto Forum:
  


Current Time: Thu Oct 29 02:16:51 GMT 2020

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

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

Back to the top