Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Spring MVC Beginner's Guide

You're reading from   Spring MVC Beginner's Guide Your ultimate guide to building a complete web application using all the capabilities of Spring MVC

Arrow left icon
Product type Paperback
Published in Jun 2014
Publisher
ISBN-13 9781783284870
Length 304 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Amuthan Ganeshan Amuthan Ganeshan
Author Profile Icon Amuthan Ganeshan
Amuthan Ganeshan
Arrow right icon
View More author details
Toc

Table of Contents (14) Chapters Close

Preface 1. Configuring a Spring Development Environment FREE CHAPTER 2. Spring MVC Architecture – Architecting Your Web Store 3. Control Your Store with Controllers 4. Working with Spring Tag Libraries 5. Working with View Resolver 6. Intercept Your Store with Interceptor 7. Validate Your Products with a Validator 8. Give REST to Your Application with Ajax 9. Apache Tiles and Spring Web Flow in Action 10. Testing Your Application A. Using the Gradle Build Tool B. Pop Quiz Answers Index

What this book covers

Chapter 1, Configuring a Spring Development Environment, will give you a quick overview of Spring MVC and its architecture and guide you through detailed notes and step-by-step instructions to set up your development environment. After installing the required prerequisites, you will try out a quick example of how to develop an application with Spring MVC. Although the chapter doesn't explain all the code in detail, you'll pick up a few things intuitively.

Chapter 2, Spring MVC Architecture – Architecting Your Web Store, will lay down the ground work for the sample application that we are going to build along the way, chapter by chapter. This chapter will introduce you to concepts such as request mapping, web application context, Spring MVC request flow, and the layered architecture of a typical web application.

Chapter 3, Control Your Store with Controllers, will take you through the concept of a controller; you will learn more about how to define a controller, and use URI template patterns, matrix variables, and request parameters.

Chapter 4, Working with Spring Tag Libraries, will teach you how to use Spring and Spring form tag libraries in web form handling. You will learn how to bind domain objects with views and how to use message bundles to externalize label caption texts. At the end of this chapter, you will see how to add a login form.

Chapter 5, Working with View Resolver, will present the inner mechanics of how InternalResourceViewResolver resolves a view and takes you through how to use various view types, such as redirect view and static view. You will also learn about the multipart resolver and content negotiation view resolver. Finally, you will learn how to use exception handler resolvers.

Chapter 6, Intercept Your Store with Interceptor, will present the concept of an interceptor to you. You will learn how to leverage the interceptor to handle or transform requests and responses flexibly. This chapter will teach you how to make your web page support internalization with the help of LocaleChangeInterceptor. This chapter also introduces how to perform audit logging in a log file using the interceptor concept.

Chapter 7, Validate Your Products with a Validator, will give you an overview of the validation concept. You will learn about bean validation, and you will learn how to perform custom validation along with the standard bean validation. You will also learn about the classic Spring validation and how to combine it with bean validation.

Chapter 8, Give REST to Your Application with Ajax, will teach you the basic principles of REST and Ajax. You will learn how to develop an application in RESTful services. The basic concept of HTTP verbs and how they are related to standard CRUD operations will be explained, and you will learn how to fire an Ajax request and handle it from a web page.

Chapter 9, Apache Tiles and Spring Web Flow in Action, will teach you how to use the Spring web flow to develop workflow-based web pages. You will learn more about states and transitions in web flow and how to define a flow definition. This chapter also teaches you how to decompose a page using Apache tiles. You will also learn more about TileViewResolver and how to define reusable Apache tiles templates.

Chapter 10, Testing your Application, will teach you how to leverage the Spring testing capability to test your controllers. You will learn how to load the test context and how to mock the service and repository layers. This chapter also introduces you to the Spring MVC test module and teaches you how to use that.

Appendix A, Using the Gradle Build Tool, introduces you to using the Gradle build tool for our sample application. You will learn about the Gradle script that is required to build our project using Gradle build tool.

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image