Book Image

Groovy for Domain-Specific Languages

By : Fergal Dearle
Book Image

Groovy for Domain-Specific Languages

By: Fergal Dearle

Overview of this book

<p>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.</p>
Table of Contents (15 chapters)
Groovy for Domain-Specific Languages
Credits
About the Author
About the Reviewers
Preface
Free Chapter
1
Introduction to DSL and Groovy
Index

About the Reviewers

Chanwit Kaewkasi is a lecturer at the School of Computer Engineering, Suranaree University, Thailand, where he received his BEng (First-class honours) in Computer Engineering. He received MEng in computer engineering from Chulalongkorn University, Thailand. Currently, he is doing a PhD in computer science at the University of Manchester, United Kingdom. His research involves an aspect-oriented approach to performance improvement of a dynamic language.

Chanwit has been an active contributor to the Groovy and Grails community since 2006. He was the very first committer of the Grails plugin project, where he maintains two of them—XFire and ZK plugin for Grails. In 2008, he joined the Google Summer of Code program for the development of a just-in-time compiler for Groovy.

Guillaume Laforge is the project lead of Groovy, the highly popular and successful dynamic language for the JVM. He co-authored Manning's bestseller "Groovy in Action" with Dierk König, and is working for SpringSource (a division of VMWare) where he's working full time on cool and Groovy stuff. You can meet Guillaume at conferences around the world where he evangelizes the Groovy dynamic language, Domain-Specific Languages in Groovy, and the agile Grails web framework.

Rob F. Castellow is the president of PAC Enterprises LLC, a contract and development company responsible for providing quality professional services. He has provided services in the development of several J2EE-based projects for large corporations in the telecommunications and financial services sectors.

Rob graduated in 1998 with a Masters in Electrical Engineering from the Georgia Institute of Technology, and began his career developing embedded systems. Rob soon found that all the excitement was in developing enterprise systems and has been working on J2EE-based applications ever since.

Rob is an enthusiast of new technologies. When he is not proofreading books on Groovy DSLs, he can be found developing Grails applications, attending user groups, reading books, managing/developing several websites, or playing with his two sons.