Skip to main content



      Home
Home » Modeling » TMF (Xtext) » org.eclipse.xtext.validation.CheckMode definition
org.eclipse.xtext.validation.CheckMode definition [message #1733923] Thu, 02 June 2016 05:16 Go to next message
Eclipse UserFriend
This line is automatically generated by xtext:
List<Issue> list = validator.validate(resource, CheckMode.ALL, CancelIndicator.NullImpl);


I am planning to change the CheckMode value.
There are several types but the documentation does not specify what each type does.

static CheckMode	ALL 
static CheckMode	EXPENSIVE_ONLY 
static CheckMode	FAST_ONLY 
static CheckMode	NORMAL_AND_FAST 
static CheckMode	NORMAL_ONLY 


I would say that EXPENSIVE means validation will take longer, but what does it cover? What is the difference with EXPENSIVE_ONLY and ALL?
How about NORMAL_ONLY, NORMAL_AND_FAST and FAST_ONLY?

Is there a document that states what each mode checks for?


Re: org.eclipse.xtext.validation.CheckMode definition [message #1733924 is a reply to message #1733923] Thu, 02 June 2016 05:20 Go to previous messageGo to next message
Eclipse UserFriend
You can give your @Check(CheckType.FAST|NORMAL|EXPENSIVE) annotation.
The check mode says which to pick
Re: org.eclipse.xtext.validation.CheckMode definition [message #1734289 is a reply to message #1733924] Mon, 06 June 2016 15:25 Go to previous message
Eclipse UserFriend
FAST: Triggered by the reconciler, i.e. when you stop typing in the editor for 200ms. These checks should execute fast. This is the default.
NORMAL: Triggered by the builder, i.e. on save. These checks are allowed to take a little longer without damaging the user experience to much.
EXPENSIVE: Only when the user explicitly triggers a validation action in the menu. Usually that is for tests that take so long that it would disturb the user too much when triggered automatically.

Every mode includes its predecessors, except for the XXX_only modes.
Previous Topic:Unit Test for XAnnotation validation shows unresolved reference
Next Topic:Latest Xtext version: 2.9.2 or 2.10.0
Goto Forum:
  


Current Time: Tue Jul 15 16:45:36 EDT 2025

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

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

Back to the top