Chapter 3. Modeling the domain

This chapter covers

  • What GORM is and how it works
  • Defining domain model classes
  • How domain classes are saved and updated
  • Techniques for validating and constraining fields
  • Domain class relationships (1:1, 1:m, m:n)

In this chapter, we’ll explore Grails’ support for the data model portion of your applications, and if you’re worried we’ll be digging deep into outer joins, you’ll be pleasantly surprised. We won’t be writing a line of SQL, and you won’t find any Hibernate XML mappings here either. We’ll be taking full advantage of the Convention over Configuration paradigm, which means less time configuring and more time getting work done.

We’ll be spending most of our time exploring the basics of how Grails persists ...

Get Grails in Action now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.