Implementing Domain-Specific Languages with Xtext and Xtend

Implementing Domain-Specific Languages with Xtext and Xtend
复制标题

DOI:
--
复制
发表时间:
2013-08
期刊:
--
影响因子:
--
通讯作者:
Lorenzo Bettini
Lorenzo Bettini
中科院分区:
其他
文献类型:
--
作者:
Lorenzo Bettini

文献摘要

被引文献

相似文献

了解如何使用易于理解的示例和最佳实践使用Xtext和Xtend实现DSL概述了解如何使用Xtext快速开发特定于域的语言使用Xtend实现DSL的任何方面,一种功能齐全的类Java编程语言了解如何测试DSL实现以及如何自定义DSL的运行时和IDE方面详细信息Xtext是一种用于实现域的开源Eclipse框架,特定语言及其IDE功能。它可以让你非常快速地实现语言,最重要的是,它涵盖了完整语言基础设施的所有方面,从解析器、代码生成器、解释器等等。“使用Xtext和Xtend实现特定领域语言”将教您如何使用Xtext开发DSL,Xtext是用于实现特定领域语言的Eclipse框架。这些章节就像教程一样,通过简单易懂的示例描述了Xtext的主要概念,如语法定义、验证、代码生成、自定义等等。本书首先简要介绍了DSL实现中涉及的Xtext特性,包括IDE中的集成,然后将向您介绍Xtend,因为本书中的所有示例都将使用这种语言。然后,我们继续解释Xtext的主要概念,例如验证、代码生成以及运行时和UI方面的定制。在本书的最后,你将学习如何使用Junit测试用Xtext实现的DSL,以遵循测试驱动的开发策略,帮助开发人员实现更快、更干净的维护代码。在介绍诸如类型检查和作用域之类的高级概念时,本书通篇使用了测试驱动的方法。这本书还向您展示了如何构建和发布DSL,以便它可以安装在Eclipse中,并为您提供了如何在持续集成服务器中无头构建DSL的提示。“使用Xtext和Xtend实现特定领域语言”旨在补充官方Xtext文档,通过简化的示例解释主要概念,并教授在Xtext中实现DSL的最佳实践。这是一个初学者指南,应该为您提供专业的开发DSL及其Eclipse IDE工具。你将从本书中学到什么学习为DSL编写Xtext语法使用Xtend作为Java的替代品来编写更清晰,更易于阅读,和更多主要代码使用验证器机制为DSL编写约束检查了解如何为DSL编写代码生成器和解释器了解自动符号解析在Xtext中的工作原理以及如何对其进行自定义构建和部署DSL实现,以便其他人熟悉典型的Xtext开发工作流程方法一个循序渐进的指南,使您能够在简化示例的帮助下,以测试驱动的方式使用Xtext和Xtend快速实现DSL。
Learn how to implement a DSL with Xtext and Xtend using easy-to-understand examples and best practices Overview Learn to quickly develop a domain-specific language with Xtext Implement any aspect of a DSL using Xtend, a fully featured Java-like programming language Discover how to test a DSL implementation and how to customize runtime and IDE aspects of the DSL In Detail Xtext is an open source Eclipse framework for implementing domain-specific languages together with its IDE functionalities. It lets you implement languages really quickly, and, most of all, it covers all aspects of a complete language infrastructure, starting from the parser, code generator, interpreter, and more. "Implementing Domain-Specific Languages with Xtext and Xtend" will teach you how to develop a DSL with Xtext, an Eclipse framework for implementing domain-specific languages. The chapters are like tutorials that describe the main concepts of Xtext such as grammar definition, validation, code generation, customizations, and many more, through uncomplicated and easy-to-understand examples. Starting with briefly covering the features of Xtext that are involved in a DSL implementation, including integration in an IDE, the book will then introduce you to Xtend as this language will be used in all the examples throughout the book. We then proceed by explaining the main concepts of Xtext, such as validation, code generation, and customizations of runtime and UI aspects. By the end of the book, you will have learned how to test a DSL implemented in Xtext with Junit, in order to follow a test-driven development strategy that will help the developer implement maintainable code that is much faster and cleaner. A test-driven approach is used throughout the book when presenting advanced concepts such as type checking and scoping. The book also shows you how to build and release a DSL so that it can be installed in Eclipse, and gives you hints on how to build the DSL headlessly in a continuous integration server. "Implementing Domain-Specific Languages with Xtext and Xtend" aims to complement the official Xtext documentation to explain the main concepts through simplified examples and to teach the best practices for a DSL implementation in Xtext. It is a Beginners Guide which should set you up for professional development DSL and its Eclipse IDE tooling. What you will learn from this book Learn to write an Xtext grammar for a DSL Use Xtend as an alternative to Java to write cleaner, easier-to-read, and more maintainable code Write constraint checks for a DSL using the validator mechanism Learn how to write a code generator and an interpreter for a DSL Discover how automatic symbol resolution works in Xtext and how to customize it Build and deploy a DSL implementation so that others can install it Get well versed with the typical Xtext development workflow Approach A step-by-step guide that enables you to quickly implement a DSL with Xtext and Xtend in a test-driven way with the aid of simplified examples.