Xtext

Last updated
Eclipse Xtext
Stable release
2.31.0 / March 2, 2021;2 years ago (2021-03-02) [1]
Repository github.com/eclipse/xtext-core
Type Software framework
License Eclipse Public License
Website xtext.org

Xtext is an open-source software framework for developing programming languages and domain-specific languages (DSLs). Unlike standard parser generators, Xtext generates not only a parser, but also a class model for the abstract syntax tree, as well as providing a fully featured, customizable Eclipse-based IDE. [2]

Contents

Xtext is being developed in the Eclipse Project as part of the Eclipse Modeling Framework Project and is licensed under the Eclipse Public License.[ citation needed ]

History

The first version of Xtext was published in 2006 in the openArchitectureWare project. The last version released under the oAW project was version 4.3. Since the beginning of 2008, Xtext has been developed at Eclipse under the Eclipse Modeling Project. [3]

Joining Eclipse's annual simultaneous release, Xtext released version 0.7.0 (June 2009), 1.0 (June 2010), 2.0 (June 2011), 2.3 (June 2012), 2.5 (December 2013), 2.6 (May 2014) and 2.7 (September 2014). The framework is mainly developed by the German company Itemis. [4]

Functionality

To specify a language, the developer has to write a grammar in Xtext's grammar language. This grammar describes how an Ecore model is derived from a textual notation. From that definition, a code generator derives an ANTLR parser and the classes for the object model. Both can be used independently of Eclipse.

Xtext includes features which integrate well with the Eclipse-based IDE:

Xtext languages and the IDE are highly configurable, as the language infrastructure and the IDE are wired up using dependency injection and Google Guice. The default components can be easily replaced by binding customized ones instead.

Since version 2.0, Xtext has facilitated the development of domain-specific languages for the Java virtual machine, referring to and compiling to Java artifacts with tight integration into Eclipse's Java Development Toolkit. A reusable expression languages library enables rich behavior within the DSL.

A code generator written in Xtend can be hooked in for any language. For JVM languages, it is enough to map the DSL concepts to Java artifacts to get holistic Java integration. An alternative interpreter is also available.[ clarification needed ]

Uses

At the time of writing this article[ when? ], the Xtext homepage listed around 40 commercial and non-commercial projects from several application domains using Xtext. [5]

Awards

See also

Related Research Articles

<span class="mw-page-title-main">Martin Fowler (software engineer)</span> American software developer, author and public speaker

Martin Fowler is a British software developer, author and international public speaker on software development, specialising in object-oriented analysis and design, UML, patterns, and agile software development methodologies, including extreme programming.

<span class="mw-page-title-main">KDevelop</span> Integrated development environment

KDevelop is a free and open-source integrated development environment (IDE) for Unix-like computer operating systems and Windows. It provides editing, navigation and debugging features for several programming languages, and integration with build automation and version-control systems, using a plugin-based architecture.

<span class="mw-page-title-main">Eclipse (software)</span> Software development environment

Eclipse is an integrated development environment (IDE) used in computer programming. It contains a base workspace and an extensible plug-in system for customizing the environment. It is the second-most-popular IDE for Java development, and, until 2016, was the most popular. Eclipse is written mostly in Java and its primary use is for developing Java applications, but it may also be used to develop applications in other programming languages via plug-ins, including Ada, ABAP, C, C++, C#, Clojure, COBOL, D, Erlang, Fortran, Groovy, Haskell, JavaScript, Julia, Lasso, Lua, NATURAL, Perl, PHP, Prolog, Python, R, Ruby, Rust, Scala, and Scheme. It can also be used to develop documents with LaTeX and packages for the software Mathematica. Development environments include the Eclipse Java development tools (JDT) for Java and Scala, Eclipse CDT for C/C++, and Eclipse PDT for PHP, among others.

AspectJ is an aspect-oriented programming (AOP) extension for the Java programming language, created at PARC. It is available in Eclipse Foundation open-source projects, both stand-alone and integrated into Eclipse. AspectJ has become a widely used de facto standard for AOP by emphasizing simplicity and usability for end users. It uses Java-like syntax, and included IDE integrations for displaying crosscutting structure since its initial public release in 2001.

<span class="mw-page-title-main">Apache Groovy</span> Programming language

Apache Groovy is a Java-syntax-compatible object-oriented programming language for the Java platform. It is both a static and dynamic language with features similar to those of Python, Ruby, and Smalltalk. It can be used as both a programming language and a scripting language for the Java Platform, is compiled to Java virtual machine (JVM) bytecode, and interoperates seamlessly with other Java code and libraries. Groovy uses a curly-bracket syntax similar to Java's. Groovy supports closures, multiline strings, and expressions embedded in strings. Much of Groovy's power lies in its AST transformations, triggered through annotations.

A domain-specific language (DSL) is a computer language specialized to a particular application domain. This is in contrast to a general-purpose language (GPL), which is broadly applicable across domains. There are a wide variety of DSLs, ranging from widely used languages for common domains, such as HTML for web pages, down to languages used by only one or a few pieces of software, such as MUSH soft code. DSLs can be further subdivided by the kind of language, and include domain-specific markup languages, domain-specific modeling languages, and domain-specific programming languages. Special-purpose computer languages have always existed in the computer age, but the term "domain-specific language" has become more popular due to the rise of domain-specific modeling. Simpler DSLs, particularly ones used by a single application, are sometimes informally called mini-languages.

In computer-based language recognition, ANTLR, or ANother Tool for Language Recognition, is a parser generator that uses a LL(*) algorithm for parsing. ANTLR is the successor to the Purdue Compiler Construction Tool Set (PCCTS), first developed in 1989, and is under active development. Its maintainer is Professor Terence Parr of the University of San Francisco.

<span class="mw-page-title-main">PHPEdit</span>

PHPEdit was a commercial IDE developed by the French company WaterProof SARL. It ran on the Microsoft Windows operating system, and was designed mainly for the PHP language, but supported many other languages such as CSS, HTML, JavaScript, INI, PHPEditScript, PlainText, SQL, XML, and XSLT.

<span class="mw-page-title-main">QVT</span> Standard set of languages for model transformation

QVT (Query/View/Transformation) is a standard set of languages for model transformation defined by the Object Management Group.

Web2py is an open-source web application framework written in the Python programming language. Web2py allows web developers to program dynamic web content using Python. Web2py is designed to help reduce tedious web development tasks, such as developing web forms from scratch, although a web developer may build a form from scratch if required.

JetBrains MPS is a language workbench developed by JetBrains. MPS is a tool to design domain-specific languages (DSL). It uses projectional editing which allows users to overcome the limits of language parsers, and build DSL editors, such as ones with tables and diagrams.
It implements language-oriented programming. MPS is an environment for language definition, a language workbench, and integrated development environment (IDE) for such languages.

Acceleo is an open-source code generator from the Eclipse Foundation that allows people to use a model-driven approach to building applications. It is an implementation of the "MOFM2T" standard, from the Object Management Group (OMG), for performing model-to-text transformation.

Xtend is a general-purpose high-level programming language for the Java Virtual Machine. Syntactically and semantically Xtend has its roots in the Java programming language but focuses on a more concise syntax and some additional functionality such as type inference, extension methods, and operator overloading. Being primarily an object-oriented language, it also integrates features known from functional programming, e.g. lambda expressions. Xtend is statically typed and uses Java's type system without modifications. It is compiled to Java code and thereby seamlessly integrates with all existing Java libraries.

OMeta is a specialized object-oriented programming language for pattern matching, developed by Alessandro Warth and Ian Piumarta in 2007 under the Viewpoints Research Institute. The language is based on Parsing Expression Grammars (PEGs) rather than Context-Free Grammars with the intent of providing "a natural and convenient way for programmers to implement tokenizers, parsers, visitors, and tree-transformers".

A language workbench is a tool or set of tools that enables software development in the language-oriented programming software development paradigm. A language workbench will typically include tools to support the definition, reuse and composition of domain-specific languages together with their integrated development environment. Language workbenches were introduced and popularized by Martin Fowler in 2005.

References

  1. "Xtext - Release Notes". eclipse.dev. Retrieved 2023-05-29.
  2. github/xtext, Eclipse Foundation, 2021-02-04, retrieved 2021-02-08
  3. Efftinge, Sven. "Xtext - Language Engineering Made Easy!". www.eclipse.org. Retrieved 16 February 2018.
  4. itemis. Retrieved from http://www.itemis.com.
  5. Retrieved from http://www.eclipse.org/Xtext/community.html.
  6. Gayowski, Lynn. "Eclipse Community Awards Winners Announced". www.eclipse.org. Retrieved 16 February 2018.
  7. Skerrett, Ian. "Eclipse Community Awards Winners Announced". www.eclipse.org. Retrieved 16 February 2018.
  8. Guindon, Christopher. "Eclipse Community Award Winners Announced". www.eclipse.org. Retrieved 16 February 2018.

Bibliography