Table of Contents

 

Copyright

Brief Table of Contents

Table of Contents

Foreword

Preface

Acknowledgments

About this Book

About the Title

About the Cover Illustration

1. Introducing Grails

Chapter 1. Grails in a hurry . . .

1.1. Introducing Grails

1.1.1. Why Grails changed the game

1.1.2. Seven big ideas

1.2. Getting set up

1.3. QOTD: your sample program

1.3.1. Writing a controller

1.3.2. Generating an HTML page: the view

1.3.3. Adding style with Grails layouts

1.4. Creating the domain model

1.4.1. Configuring the data source

1.4.2. Exploring database operations

1.5. Adding UI actions

1.5.1. Scaffolding: adding rocket fuel

1.5.2. Surviving the worst-case scenario

1.6. Improving the architecture

1.6.1. Your Grails test case

1.6.2. Going Web 2.0: Ajaxing the view

1.6.3. Bundling the final product: creating a WAR file

1.6.4. And 80 lines of code later

1.7. Summary and best practices

Chapter 2. The Groovy essentials

2.1. Writing your first script

2.1.1. Using lists, loops, and methods

2.1.2. Working with strings

2.2. Creating a quote analyzer class

2.2.1. Introducing Spock properly

2.2.2. Creating the initial class

2.2.3. Working with maps

2.2.4. Taking the analyzer for a spin

2.3. Going to the next level

2.3.1. Discovering closures

2. Core Grails