Where org.eclipse.xtext.xbase.validation.XtypeJavaValidator
is supposed to be?
Xtext needs it in a generated file Abstract*DslJavaValidator
. This type replaces org.eclipse.xtext.validation.AbstractDeclarativeValidator
from Xtext 2.3.0 but I can't find this class anywhere in Xtext 2.4.1.
2.4 has XbaseJavaValidator
but I'm not sure whether I should use this (the code being generated by Xtext and the access to this class being discouraged).
Are there instructions anywhere how to upgrade from 2.3 to 2.4?
By blindly messing the URL, I was able to generate a list of bugs with the title "Whiteboard: v2.4" but I'm not sure whether a) this is the actual list of bugs and b) how to get the list for 2.4.1.
The prefix of the class is generated from the base grammar. So if your grammar starts with
grammar ...
with org.eclipse.xtext.xbase.Xtype
the code generators will try to extend XtypeJavaValidtor
. If you derive from Xbase, it will use XbaseJavaValidtor
(ie name of grammar + JavaValidtor
)
This bug report contains a workaround :
Workaround: pass
inheritImplementation=false
in the workflow like this:fragment = validation.ValidatorFragment auto-inject { inheritImplementation = false }
Same is probably true for the
ImportNamespacesScopingFragment
,ContentAssistFragment
andQuickfixProviderFragment
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.