See: Description
| Interface | Description |
|---|---|
| Groovy.Ratpack |
The definition of a Groovy Ratpack application.
|
| Class | Description |
|---|---|
| Groovy |
Static methods for specialized Groovy integration.
|
| Groovy.Script |
Methods for working with Groovy scripts as application components.
|
| GroovyRatpackMain |
A boilerplate entry point, which combines
RatpackServer.start(ratpack.func.Action) and Groovy.Script.app(). |
The Groovy support provides the following key features:
Closure based Handler Chain building DSL - see GroovyChain.TextTemplateModule.Groovy.Ratpack.DelegatesTo
Ratpack makes heavy use of a feature of Groovy 2.1 that allows the delegate of a closure to be specified via the type system.
Namely, the DelegatesTo annotation.
On all parts of the API where a Closure is being accepted as a method parameter, the parameter will be
annotated with this annotation. This specifies the type of the closure delegate object during execution.
For more information on closure delegates, see this article.
When reading the API reference, it's important to take note of the DelegatesTo annotation on closure parameters.
This parameter indicates what type to look at for information on what the closure can do.