Implementing Domain-Specific Languages with Xtext and Xtend
By Lorenzo Bettini
Publisher: Packt Publishing
Final Release Date: August 2013
Pages: 342

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 Beginner's Guide which should set you up for professional development DSL and its Eclipse IDE tooling.

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.

Who this book is for

This book is for programmers who want to learn about Xtext and how to use it to implement a DSL (or a programming language) together with Eclipse IDE tooling. It assumes that the user is familiar with Eclipse and its functionality. Existing basic knowledge of a compiler implementation would be useful, though not strictly required, since the book will explain all the stages of the development of a DSL.

Product Details
Recommended for You
Customer Reviews

REVIEW SNAPSHOT®

by PowerReviews
oreillyImplementing Domain-Specific Languages with Xtext and Xtend
 
5.0

(based on 2 reviews)

Ratings Distribution

  • 5 Stars

     

    (2)

  • 4 Stars

     

    (0)

  • 3 Stars

     

    (0)

  • 2 Stars

     

    (0)

  • 1 Stars

     

    (0)

Reviewed by 2 customers

Sort by

Displaying reviews 1-2

Back to top

 
5.0

A very useful book

By PavolM

from Kalna nad Hronom, Slovakia

About Me Designer, Developer

Verified Reviewer

Pros

  • Concise
  • Easy to understand
  • Helpful examples
  • Well-written

Cons

    Best Uses

    • Intermediate
    • Novice
    • Student

    Comments about oreilly Implementing Domain-Specific Languages with Xtext and Xtend:

    This book was extremely helpful to me when working on my non-trivial project based on custom DSL (Domain-Specific Language). I've bought it almost immediately after publishing (September 2013) and used for a couple of months while working on my project.

    It contains a very understandable description of Xtext features and, above all, a lot of practically usable examples. It saved me days or perhaps even weeks of work. (Before the book was published, I developed an older version of the project without having such a book, so I can compare.)

    The book is superior in explaining many advanced concepts; for me, the most important were linking/scoping, expression handling, and validation. Although the original Xtext documentation is quite usable, the book is much more understandable (at least comparing with then-current Xtext version of 2.4.2).

    Of course, as you go into deeper experience with Xtext, you'll find some limitations of the book - it is just not possible to cover everything in full depth. A few of the most advanced topics I have found in the documentation only, but most of them is not even there - and the only way is to ask on a Xtext mailing list. But nevertheless, paying a few euros for the e-book paid back enormously in the amount of time I've spared by using the book.

    [Note: Recently a publisher of this book asked me to write a unbiased, objective and honest review of this book in exchange for a small gift (an e-book). So I gladly written it.]

     
    5.0

    Very good also for complex DSL

    By aricci303

    from Cesena, Italy

    About Me Developer, Educator

    Verified Reviewer

    Pros

    • Accurate
    • Concise
    • Easy to understand
    • Helpful examples
    • Well-written

    Cons

      Best Uses

      • Expert
      • Intermediate
      • Novice
      • Student

      Comments about oreilly Implementing Domain-Specific Languages with Xtext and Xtend:

      The book provides a careful balance between the practice of implementing DSL with Xtext and Xtend, and the explanation of the concepts and methods behind the practice. So you learn how to concretely use Xtext and Xtend but also the rationale behind this. This makes the content of the book valuable in spite of the evolution of the technologies.

      I have particularly appreciated the effort of the book, which is clearly oriented towards the implementation level, but providing also light-weight but accurate methodological insights, from design to testing, making the book effective also from a software engineering perspective.

      Finally, I consider the book particularly valuable when considering the development of complex DSL, providing features that are typically found in general-purpose languages, such as type checking and articulated scoping.

      Displaying reviews 1-2

      Back to top

       
      Buy 2 Get 1 Free Free Shipping Guarantee
      Buying Options
      Immediate Access - Go Digital what's this?
      Ebook: $29.99
      Formats:  ePub, Mobi, PDF