E-Book, Englisch, 648 Seiten
Rocher / Brown The Definitive Guide to Grails
2. ed
ISBN: 978-1-4302-0871-6
Verlag: Apress
Format: PDF
Kopierschutz: 1 - PDF Watermark
E-Book, Englisch, 648 Seiten
ISBN: 978-1-4302-0871-6
Verlag: Apress
Format: PDF
Kopierschutz: 1 - PDF Watermark
The rise of Ruby on Rails has signified a huge shift in how we build web applications today; it is a fantastic framework with a growing community. There is, however, space for another such framework that integrates seamlessly with Java. Thousands of companies have invested in Java, and these same companies are losing out on the benefits of a Rails-like framework. Enter Grails. Grails is not just a Rails clone. It aims to provide a Rails-like environment that is more familiar to Java developers and employs idioms that Java developers are comfortable using, making the adjustment in mentality to a dynamic framework less of a jump. The concepts within Grails, like interceptors, tag libs, and Groovy Server Pages (GSP), make those in the Java community feel right at home. Grails' foundation is on solid open source technologies such as Spring, Hibernate, and SiteMesh, which gives it even more potential in the Java space: Spring provides powerful inversion of control and MVC, Hibernate brings a stable, mature object relational mapping technology with the ability to integrate with legacy systems, and SiteMesh handles flexible layout control and page decoration. Grails complements these with additional features that take advantage of the coding-by-convention paradigm such as dynamic tag libraries, Grails object relational mapping, Groovy Server Pages, and scaffolding. Graeme Rocher, Grails lead and founder, and Jeff Brown bring you completely up-to-date with their authoritative and fully comprehensive guide to the Grails framework. You'll get to know all the core features, services, and Grails extensions via plug-ins, and understand the roles that Groovy and Grails are playing in the changing Web.
Graeme Rocher is an experienced software engineer, consultant and dynamic language expert. Graeme is project lead of the open source Grails web application framework (Grails.org) and author of The Definitive Guide to Grails. In Graeme's role as head of Grails development at SpringSource, the professional open source services company behind the Spring framework, Graeme leads the development of the Grails web framework and provides consulting, training and support to SpringSource's clients. Graeme is a frequent speaker at industry conferences on subjects related to Groovy, Grails and dynamic languages in Java. Prior to joining SpringSource Graeme co-founded G2One the Groovy/Grails Company which was later acquired by SpringSource.
Autoren/Hrsg.
Weitere Infos & Material
1;Second Edition;2
2;Contents at a Glance;5
3;Contents;6
4;About the Authors;17
5;About the Technical Reviewer;19
6;Acknowledgments;20
7;Introduction;22
7.1;Who This Book Is For;23
7.2;How This Book Is Structured;24
7.3;Conventions;24
7.4;Prerequisites;24
7.5;Downloading the Code;25
7.6;Contacting the Authors;25
8;The Essence of Grails;26
8.1;Simplicity and Power;27
8.2;Grails, the Platform;28
8.3;Living in the Java Ecosystem;29
8.4;Getting Started;30
8.5;Creating Your First Application;32
8.6;Summary;40
9;Getting Started with Grails;41
9.1;What Is Scaffolding?;41
9.2;Creating a Domain;41
9.3;Dynamic Scaffolding;43
9.4;Static Scaffolding;51
9.5;Being Environmentally Friendly;57
9.6;Configuring Data Sources;58
9.7;Deploying the Application;65
9.8;Summary;66
10;Understanding Domain Classes;68
10.1;Persisting Fields to the Database;68
10.2;Validating Domain Classes;69
10.3;Using Custom Validators;72
10.4;Understanding Transient Properties;73
10.5;Customizing Your Database Mapping;74
10.6;Building Relationships;76
10.7;Extending Classes with Inheritance;79
10.8;Embedding Objects;82
10.9;Testing Domain Classes;83
10.10;Summary;86
11;Understanding Controllers;87
11.1;Defining Controllers;87
11.2;Creating a Model;97
11.3;Rendering a View;98
11.4;Performing Data Binding;99
11.5;Working with Command Objects;104
11.6;Imposing HTTP Method Restrictions;107
11.7;Controller IO;108
11.8;Using Simple Interceptors;112
11.9;Testing Controllers;113
11.10;Controllers in Action;115
11.11;Summary;128
12;Understanding Views;129
12.1;The Basics;129
12.2;Built- in Grails Tags;133
12.3;Grails Dynamic Tags;138
12.4;Creating Custom Tags;158
12.5;Summary;163
13;Mapping URLs;164
13.1;Understanding the Default URL Mapping;164
13.2;Including Static Text in a URL Mapping;165
13.3;Removing the Controller and Action Names from the URL;166
13.4;Embedding Parameters in a Mapping;166
13.5;Specifying Additional Parameters;168
13.6;Mapping to a View;169
13.7;Applying Constraints to URL Mappings;170
13.8;Including Wildcards in a Mapping;171
13.9;Mapping to HTTP Request Methods;172
13.10;Mapping HTTP Response Codes;174
13.11;Taking Advantage of Reverse URL Mapping;175
13.12;Defining Multiple URL Mappings Classes;176
13.13;Testing URL Mappings;176
13.14;Summary;179
14;Internationalization;180
14.1;Localizing Messages;180
14.2;Using Parameterized Messages;185
14.3;Using messageSource;189
14.4;Summary;191
15;Ajax;192
15.1;The Basics of Ajax;192
15.2;Ajax in Action;194
15.3;Changing Your Ajax Provider;195
15.4;Asynchronous Form Submission;196
15.5;Executing Code Before and After a Call;198
15.6;Handling Events;199
15.7;Fun with Ajax Remote Linking;200
15.8;Adding Effects and Animation;214
15.9;Ajax- Enabled Form Fields;214
15.10;A Note on Ajax and Performance;218
15.11;Summary;219
16;Creating Web Flows;220
16.1;Getting Started with Flows;221
16.2;Flows in Action;229
16.3;Summary;268
17;GORM;269
17.1;Persistence Basics;269
17.2;Associations;272
17.3;Querying;274
17.4;Configuring GORM;283
17.5;The Semantics of GORM;285
17.6;Transactions in GORM;292
17.7;Detached Objects;294
17.8;Performance Tuning GORM;298
17.9;Locking Strategies;305
17.10;Events Auto Time Stamping;307
17.11;Summary;308
18;Services;309
18.1;Service Basics;309
18.2;Services and Dependency Injection;311
18.3;Services in Action;311
18.4;Transactions;315
18.5;Scoping Services;317
18.6;Testing Services;318
18.7;Exposing Services;318
18.8;Summary;324
19;Integrating Grails;325
19.1;Grails and Configuration;325
19.2;Understanding Grails’ Build System;330
19.3;Integration with Apache Ant;345
19.4;Dependency Resolution with Ivy;347
19.5;Code Coverage with Cobertura;350
19.6;Continuous Integration with Hudson;351
19.7;Adding Support to Your Favorite IDE;355
19.8;Integration with E- mail Servers;365
19.9;Scheduling Jobs;369
19.10;Deployment;381
19.11;Summary;385
20;Plugins;386
20.1;Plugin Basics;386
20.2;Plugins in Action;410
20.3;Summary;425
21;Security;426
21.1;Securing Against Attacks;426
21.2;Using Dynamic Codecs;433
21.3;Authentication and Authorization;435
21.4;Grails Filters;436
21.5;The JSecurity Plugin;438
21.6;Limiting Access Through URL Mappings;465
21.7;Summary;467
22;Web Services;468
22.1;REST;469
22.2;Atom and RSS;492
22.3;SOAP;497
22.4;Summary;504
23;Leveraging Spring;505
23.1;Spring Basics;505
23.2;Spring and Grails;507
23.3;Spring in Action;516
23.4;Summary;534
24;Legacy Integration with Hibernate;536
24.1;Legacy Mapping with the ORM DSL;536
24.2;Mapping with Hibernate XML;549
24.3;Summary;560
25;The Groovy Language;561
25.1;Groovy and Java: A Comparison;561
25.2;The Basics;563
25.3;Groovy Power Features;573
25.4;Summary;585
26;Index;586




