Xtend 的缺点是什么?

发布于 2024-12-14 13:20:13 字数 102 浏览 1 评论 0原文

使用 Xtend 有哪些缺点/缺点?

What are the disadvantages/drawbacks of using Xtend?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

∞梦里开花 2024-12-21 13:20:13

通过询问Xtend的开发团队,我得到了以下答案:

亲爱的X先生,

与 Java 开发相比,主要缺点可能是,尽管
Xtend 的工具比其他提供的工具要好得多
语言,它仍然不如 Eclipse 对 Java 的功能
发展。

另请注意,Xtend 缺少一些您可能需要的功能
与现有 Java 项目集成:
- 构造函数的定义
- 字段初始化
- 静态方法和字段的声明

下一个版本将具有这些功能,并且还将附带
易于使用集成在 Maven 或 Ant 中运行编译器。它是
计划于今年晚些时候进行。

谨致问候,斯文·埃夫廷格

所以,总结一下:(

  • 正如 bjz 提到的)它与 Eclipse 环境紧密结合,
  • 缺少关键功能

尽管如此,他们似乎正在努力解决这些问题。还有一个 下一步 部分

By asking the development team of Xtend, I got the following answer:

Dear Mr. X,

The major drawback compared to Java development might be that although
Xtend's tooling is much better than the tooling provided by other
languages, it's still not as good as what Eclipse can do for Java
development.

Also note, that Xtend misses some features you might need when
integrating with existing Java projects :
- definition of constructors
- field initialization
- declaration of static methods and fields

The next release will have these features and will also come with an
easy to use integration to run the compiler in Maven or Ant. It's
planned for later this year.

Best Regards, Sven Efftinge

So, to conclude:

  • (as bjz mentioned) it's quite coupled with an Eclipse environment
  • critical features are missing

Nevertheless, they seem to be working on them. There is also, a What's next Section

初见你 2024-12-21 13:20:13

从版本 2.2 开始,Eclipse Xtend 语言(2011 年 12 月发布)现在支持 Apache Ant 和 Apache Maven 构建工具。

通过额外的这种支持,在持续集成/构建过程中不使用 Xtend 的一个主要缺点已经得到解决。

虽然官方/本机 IDE 支持仍然仅限于 Eclipse IDE,但 Jetbrains 的 IntelliJ IDEA 和 Oracle 的 Netbeans 都提供出色的 Maven 支持,这将有助于开发,直到开发出 IDE 特定支持为止。

Since version 2.2 - The Eclipse Xtend Language ( released December 2011 ) now ships with support for both the Apache Ant and Apache Maven build tools.

With the additional of this support, a major drawback of not being about to use Xtend in your continuous integration/build process has been resolved.

Whislt official/native IDE support is still limited to the Eclipse IDE, both IntelliJ IDEA from Jetbrains and Netbeans from Oracle offer excellent Maven support which will assist development until IDE specific support is developed.

纸伞微斜 2024-12-21 13:20:13

我还没有广泛尝试过 Xtend,但我确实遇到了 这篇文章< /a> 上周,我发现非常有启发:

与 eclipse 工具紧密耦合

Xtend 和 Xtext 无疑是超越技术
通过。对于开始使用这些产品来说,这是一个明显的优势
技术,因为它们提供了与 eclipse IDE 的良好集成。
然而,一个缺点是,用 Xtend 语言编写的代码可能会
除了 eclipse 之外,很难与其他工具一起使用。另一方面
另一方面,Xtend 生成的 Java 代码是普通 Java 代码(除了
来自生成代码中使用的轻量级 Xtend 库)。这
当然,大多数其他工具都可以使用代码。因此,我有
上面选择将 xtend 源文件放置在主 Java 中
项目的源代码文件夹(src/main/java)但放入单独的
文件夹(src/main/xtext)。这使得可以生成 Java 代码
进入 src/main/java 文件夹。从那里,可以拾取它并
由 Maven 等其他工具使用。

在某些地方,文档不足

可用于 Xtend 的文档还远远不够广泛。在
相比之下,Groovy 的可用文档非常广泛
包括书籍和各种网站。

编辑:Xtend 现在有一个独立的编译器,但他们似乎仍在推动 Eclipse 集成。从本质上来说,这完全没问题,但这确实意味着您不会在其他 IDE 中获得同样出色的体验。请访问他们的网站,了解他们的未来计划

I haven't tried out Xtend extensively, but I did come across this article last week, and I found very enlightening:

Tight coupling with eclipse tooling

Xtend and Xtext are doubtlessly eclipse technologies through and
through. This is a definite advantage for starting to use these
technologies since they offer nice integration with the eclipse IDE.
As a downside, however, code written in the Xtend language might be
difficult to use with other tools apart from eclipse. On the other
hand, the Java code generated by Xtend is vanilla Java code (apart
from the lightweight Xtend library used in the generated code). This
code, of course, can be used by most other tools. Therefore, I have
chosen above to place the xtend source files not in the main Java
source code folder of the project (src/main/java) but into a separate
folder (src/main/xtext). This enabled to let Java code be generated
into the src/main/java folder. From there, it can be picked up and
used by other tools such as Maven.

In places, insufficient documentation

The documentation available for Xtend is far from extensive. In
comparison, the documentation available for Groovy is extensive
including books and various web sites.

EDIT: Xtend now has a standalone compiler, but they still seem to be pushing the Eclipse integration. Which is completely fine by mean, but it does mean that you won't have as great of an experience in other IDEs. Check out their site to see their future plans.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文