简体   繁体   English

Eclipse 4.3(Kepler)中的xCore文件错误

[英]Error in xCore file in Eclipse 4.3(Kepler)

I have just installed eclipse 4.3(Kepler) and when i open my xcore file it gives me some error: 我刚刚安装了eclipse 4.3(Kepler),当我打开xcore文件时,它给了我一些错误:

Couldn't resolve reference to XAnnotationDirective 'GenModel' 无法解析对XAnnotationDirective'GenModel'的引用
Couldn't resolve reference to XAnnotationDirective 'ExtendedMetaData'. 无法解析对XAnnotationDirective'ExtendedMetaData'的引用。

what could be the reason? 可能是什么原因? any help will be appreciated. 任何帮助将不胜感激。

Regards 问候
Sharif 谢里夫

The error is caused mainly due to incompatible dependencies and version mismatches. 该错误主要是由于不兼容的依赖项和版本不匹配引起的。 The following setting should fix your problem: 以下设置可以解决您的问题:

Firstly try doing a clean build. 首先,尝试进行干净的构建。 Generally that would solve your problem. 通常,这可以解决您的问题。 But if it doesn't try the following: 但是,如果不尝试以下操作:

emf-xcore-SDK-VERSION and the following dependencies: emf-xcore-SDK-VERSION和以下依赖项:

Require-Bundle: 需要束:

org.eclipse.core.runtime,
org.eclipse.emf.ecore;visibility:=reexport,
org.eclipse.xtext.xbase.lib;visibility:=reexport,
org.eclipse.emf.ecore.xcore.lib

in the JAR's manifest file and rebuild. 在JAR的清单文件中并重建。

EDIT: Turns out that the official documentation of xcore states to use either Eclipse 4.2 or 3.8. 编辑:事实证明, xcore的官方文档规定要使用Eclipse 4.2或3.8。 Also the first version of Xcore will be part of the Juno release train and is currently available in the Juno p2 repository. Xcore的第一个版本也将成为Juno发行版的一部分,并且目前在Juno p2存储库中可用。 Maybe the subsequent versions will add Kepler build as well. 也许后续版本也会添加开普勒版本。 You probably need to downgrade the Eclipse to 4.2 to make xcore work. 您可能需要将Eclipse降级到4.2才能使xcore工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM