Programming Books C Java PHP Python Learn more Browse Programming Books
Groovy for Domain-Specific Languages and over one million other books are available for Amazon Kindle. Learn more
Buy New
  • List Price: $44.99
  • Save: $2.25 (5%)
In stock but may require an extra 1-2 days to process.
Ships from and sold by
Gift-wrap available.
Have one to sell? Sell on Amazon
Flip to back Flip to front
Listen Playing... Paused   You're listening to a sample of the Audible audio edition.
Learn more
See all 2 images

Groovy for Domain-Specific Languages Paperback – June 1, 2010

ISBN-13: 978-1847196903 ISBN-10: 184719690X

Buy New
Price: $42.74
19 New from $37.31 12 Used from $20.69
Amazon Price New from Used from
"Please retry"
"Please retry"
$37.31 $20.69
Free Two-Day Shipping for College Students with Amazon Student Free%20Two-Day%20Shipping%20for%20College%20Students%20with%20Amazon%20Student

Frequently Bought Together

Groovy for Domain-Specific Languages + Groovy in Action
Price for both: $78.57

One of these items ships sooner than the other.

Buy the selected items together
If you buy a new print edition of this book (or purchased one in the past), you can buy the Kindle edition for only $2.99 (Save 82%). Print edition purchase must be sold by Amazon. Learn more.

Shop the new
New! Introducing the, a hub for Software Developers and Architects, Networking Administrators, TPMs, and other technology professionals to find highly-rated and highly-relevant career resources. Shop books on programming and big data, or read this week's blog posts by authors and thought-leaders in the tech industry. > Shop now

Product Details

  • Paperback: 312 pages
  • Publisher: Packt Publishing (June 1, 2010)
  • Language: English
  • ISBN-10: 184719690X
  • ISBN-13: 978-1847196903
  • Product Dimensions: 7.5 x 0.7 x 9.2 inches
  • Shipping Weight: 1.2 pounds (View shipping rates and policies)
  • Average Customer Review: 3.8 out of 5 stars  See all reviews (9 customer reviews)
  • Amazon Best Sellers Rank: #1,385,596 in Books (See Top 100 in Books)

Editorial Reviews

About the Author

Fergal Dearle

Fergal is a seasoned software development professional with 23 years of experience in software product development across a wide variety of technologies. He is currently principal consultant with his own software development consulting company, Dearle Technologies Ltd., engaged in design, development, and architecture for new software products for client companies. In the past Fergal has worked in lead architect and developer roles for Candle Corporation on the OMEGAMON product which is now part of IBMs Tivoli product suite as development manager for the Unix implementations of Lotus 1-2-3. In the early 1990s Fergal lead the team at Glockenspiel that developed CommonView, the first object-oriented UI framework for Microsoft Windows. The team was awarded one of the first ever Jolt Productivity Awards by Dr Dobbs Journal.

Customer Reviews

3.8 out of 5 stars
Share your thoughts with other customers

Most Helpful Customer Reviews

10 of 11 people found the following review helpful By Andre Steingress on August 1, 2010
Format: Paperback

The book Groovy for Domain-Specific Languages [Packt Publishing: 3, 5] written by Fergal Dearle [4] has been published by Packt Publishing in May 2010. As the title mentions it is all about how to implement domain-specific languages aka DSLs based on the Groovy programming language.

With this book the author explicitly targets Java programmers. As can be seen in the separate chapter descriptions below, the book covers Groovy basics, advanced DSL-related language features and script integration issues.

Although not explicitly mentioned, this book covers Groovy up to version 1.6, as this can be deducted from some code samples and screenshots.

Chapter Summary

Chapter 1 - Introduction to DSL and Groovy

The first chapter starts with a general introduction to general purpose programming languages which leads to a brief introduction to specific languages also known as domain-specific languages (DSLs). In addition, the author gives a brief introduction into Groovy and how it relates to the Java platform. A first example of Groovy's XML markup builder gives a practical example on how certain dynamic programming features support building custom DSLs.

Chapter 2 - Groovy Quick Start

The second chapter covers Groovy from ground up split into two main parts: the first part is the administrative one - it explains where to get Groovy and how to install it on various operating systems and gives an overview about basic commands found in Groovy's binary directory: groovy, groovysh, groovyConsole and groovyc.
Read more ›
Comment Was this review helpful to you? Yes No Sending feedback...
Thank you for your feedback. If this review is inappropriate, please let us know.
Sorry, we failed to record your vote. Please try again
5 of 5 people found the following review helpful By Richard J. Wagner on July 5, 2010
Format: Paperback
The book really covers two topics: The Groovy language and writing Domain-Specific Languages.

The Groovy portion is thorough and offers a broad survey of the language. Given nearly 300 pages, a lot of ground is covered, but there's usually only one example per topic shown in code. That's ok, though-- at times I needed more than one example, but never failed in my quest to find additional material via the internet. Once given an idea about the a Groovy feature (with surrounding contextual text and the usual single example) I knew what that feature was for. After that, it was up to me to gain mastery through external sources in some cases. No problem here.

The DSL part was interesting, from the point of view of a Java coder. Dynamic language features like Meta-programming and the definition of new methods on the fly are new to me, so I had a lot of questions answered as I looked over the way the author used these features to build a DSL. Interesting!

All things considered, I found the book to be a good read and I expect it'll find future use as a reference in my developer's bookshelf. Java coders can pick this one up and feel right at home.
Comment Was this review helpful to you? Yes No Sending feedback...
Thank you for your feedback. If this review is inappropriate, please let us know.
Sorry, we failed to record your vote. Please try again
4 of 4 people found the following review helpful By mrhaki on July 11, 2010
Format: Paperback
Groovy for Domain-Specific Languages has the subtitle 'Extend and enhance your Java applications with Domain-Specific Language in Groovy'. The book is aimed at Java developers who want to write a Domain-Specific Language (DSL) and integrate it with their applications.

Because the book targets a Java audience the first chapters are mostly an introduction to Groovy. The first chapter is an introduction to Groovy and Domain-Specific Languages (DSLs). The author explains some common concepts for DSLs and common examples of DSLs. In the second chapter we learn how to install Groovy and how to write and run scripts. Next we get a brief introduction into the Groovy language features, so as a Java developer we get enough knowledge to get started with Groovy. Features like metaprogramming are covered in a later chapter.

In chapter three the author covers closures. Because Groovy supports closures and they are important for writing DSLs a complete chapter is devoted to closures. This is a good thing, because as Java developers we get a good understanding of the power of closures, we don't have in Java. We learn how to write closures, pass parameters, curry parameters and invoke them. The book doesn't cover the latests Groovy 1.7.2 curry methods, but it is enough to get started.

After the first three chapters we learned enough to write our first DSL. The author explains how we can write our own DSL for a Twitter client. First we learn about the Twitter API and how to use it with the Twitter4J library. Next we are going to make the API calls more Groovy by using closures and Groovy's collection support. This results already in more readable code that doesn't read like normal Java code. We even learn how we can write a command-line script to use the Twitter DSL.
Read more ›
Comment Was this review helpful to you? Yes No Sending feedback...
Thank you for your feedback. If this review is inappropriate, please let us know.
Sorry, we failed to record your vote. Please try again
4 of 4 people found the following review helpful By carlos on January 12, 2013
Format: Kindle Edition Verified Purchase
This book is meant for people who have little or no experience developing their own internal domain specific languages (DSLs). It starts by giving a short introduction to Groovy and all of its features that make creating DSLs possible. This means that the reader of this book doesn't need to know anything about Groovy before reading it. Development experience is absolutely necessary though. The text is clear from cover to cover. Even the most complex topics can be easily understood by novices on the area. This can be a problem for more experienced people. I found myself skipping many pages as they were covering very basic topics.

Unfortunately the book doesn't go too far. I was expecting to finish it as a super DSL ninja, but I feel more like a karate kid instead. This is the downside of having unexperienced people as the target audience. Some of the most powerful Groovy features, such as AST manipulation were left ouf of the scope of the book.

The biggest problem of this book is the formatting (I am reading the kindle version). There is no indentation for code blocks. This means that any code with more than a few lines is extremely difficult to understand. I am working around that reading the book on my mac with the source files open next to it. Finding the appropriate source files for each code block is not a pleasant task though. There are still many minor typos and formatting problems.
Comment Was this review helpful to you? Yes No Sending feedback...
Thank you for your feedback. If this review is inappropriate, please let us know.
Sorry, we failed to record your vote. Please try again

What Other Items Do Customers Buy After Viewing This Item?