Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

Overview

Extend and enhance your Java applications with Domain Specific Languages in Groovy

  • Build your own Domain Specific Languages on top of Groovy

  • Integrate your existing Java applications using Groovy-based Domain Specific Languages (DSLs)

  • Develop a Groovy scripting interface to Twitter

  • A step-by-step guide to building Groovy-based Domain Specific Languages that run seamlessly in the Java environment

In Detail

You may already be aware that the Java virtual machine runs on everything from the largest mainframe to the smallest microchip and supports almost every conceivable application. What you may not realize is that to develop software in some of these scenarios requires a targeted, single purpose language, a Domain Specific Language. The popular scripting language Groovy can be used to create a Domain Specific Language that can run directly on the JVM alongside regular Java code.

This comprehensive tutorial will take you through the design and development of Groovy-based Domain Specific Languages. It is a complete guide to the development of several mini-DSLs with a lot of easy-to-understand examples. This book will help you to gain all of the skills needed to develop your own Groovy-based DSLs, as it guides you from the basics through to the more complex meta-programming features of Groovy. The focus is on how the Groovy language can be used to construct domain-specific mini-languages

Practical examples are used throughout to de-mystify the seemingly complex language features and to show how they can be used to create simple and elegant DSLs. The examples include a quick and simple Groovy DSL to interface with Twitter.

The book concludes with a chapter focusing on integrating Groovy-based DSLs in such a way that the scripts can be readily incorporated into the readers' own Java applications. The overall goal of this book is to take Java developers through the skills and knowledge they need to start building effective Groovy-based DSLs to integrate into their own applications.

This practical guide will teach you how to build Domain Specific Languages in Groovy that integrate seamlessly with your Java applications

Subscriber Reviews

Average Rating: 5 out of 5 rating Based on 1 Rating

"best book for DSL and Groovy" - by pravsingh on 07-JAN-2013
Reviewer Rating: 1 star rating2 star rating3 star rating4 star rating5 star rating
very nice in providing the examples and explaining various parts of the language and DSL.

loved it.

Report as Inappropriate

Table of Contents

 Index

Extras

The publisher has provided additional content related to this title.


Description
Content

Downloading the example code for this book

  • You can download the example code files for all Packt books you have purchased from your account at http://www.PacktPub.com.
  • If you purchased this book elsewhere, you can visit http://www.PacktPub.com/support and register to have the files e-mailed directly to you.