Tuesday, August 17, 2010

Java server Pages




Preface 1
What's in This Book
Audience
Organization
About the Examples
Conventions Used in This Book
How to Contact Us
Acknowledgments
i JSP Application Basics
This part of the book describes the fundamentals of HTTP (the protocol used by all web applications),
how servlets and JSP are related, and how to set up a JSP development environment and install the
book examples.
1 Introducing JavaServer Pages 8
1.1 What Is JavaServer Pages?
1.2 Why Use JSP?
1.3 What You Need to Get Started
2 HTTP and Servlet Basics 13
2.1 The HTTP Request/Response Model
2.2 Servlets
2.3 Packaging Java Web Applications
3 JSP Overview 25
3.1 The Problem with Servlets
3.2 The Anatomy of a JSP Page
3.3 JSP Processing
3.4 JSP Application Design with MVC
4 Setting Up the JSP Environment 34
4.1 Installing the Java Software Development Kit
4.2 Installing the Tomcat Server
4.3 Testing Tomcat
4.4 Installing the Book Examples
4.5 Example Web Application Overview
ii JSP Application Development
The focus of this part of the book is on developing JSP-based web applications using both standard JSP
elements and custom components. Through the use of practical examples, you will learn how to handle common
tasks such as validating user input, accessing databases, authenticating users and protecting web pages,
localizing your web site, and more.
5 Generating Dynamic Content 42
5.1 What Time Is It?
5.2 Input and Output
6 Using Scripting Elements 55
6.1 Java Primer
6.2 Implicit JSP Objects
6.3 Conditional Processing
6.4 Displaying Values
6.5 Using an Expression to Set an Attribute
6.6 Declaring Variables and Methods
7 Error Handling and Debugging 74
7.1 Dealing with Syntax Errors
7.2 Debugging a JSP-Based Application
7.3 Dealing with Runtime Errors
8 Sharing Data Between JSP Pages, Requests, and Users 87
8.1 Passing Control and Data Between Pages
8.2 Sharing Session and Application Data
8.3 Using Custom Actions
8.4 Online Shopping
8.5 Memory Usage Considerations
9 Database Access 109
9.1 Accessing a Database from a JSP Page
9.2 Input Validation Without a Bean
9.3 Using Transactions
9.4 Application-Specific Database Actions
10 Authentication and Personalization 130
10.1 Container-Provided Authentication
10.2 Application-Controlled Authentication
10.3 Other Security Concerns
11 Internationalization 148
11.1 How Java Supports Internationalization and Localization
11.2 Generating Localized Output
11.3 A Brief History of Bits
11.4 Handling Localized Input
12 Bits and Pieces 165
12.1 Buffering
12.2 Including Page Fragments
12.3 XML and JSP
12.4 Mixing Client-Side and Server-Side Code
12.5 Precompiling JSP Pages
12.6 Preventing Caching of JSP Pages
12.7 How URLs Are Interpreted
III: JSP in J2EE and JSP Component Development
If you're a programmer, this is the part of the book where the real action is . Here you will learn how to develop
your own custom actions and JavaBeans, and how to combine JSP with other Java server-side technologies,
such as servlets and Enterprise JavaBeans (EJB).
13 Web Application Models 182
13.1 The Java 2 Enterprise Edition Model
13.2 The MVC Model
13.3 Scalability
14 Combining Servlets and JSP 190
14.1 Using a Servlet as the Controller
14.2 A More Modular Design Using Action Objects
14.3 Sharing Data Between Servlets and JSP Pages
14.4 Using a JSP Error Page for All Runtime Errors
15 Developing JavaBeans for JSP 200
15.1 JavaBeans as JSP Components
15.2 JSP Bean Examples
15.3 Unexpected Behavior
16 Developing JSP Custom Actions 213
16.1 Tag Extension Basics
16.2 Developing a Simple Action
16.3 Processing the Action Body
16.4 Letting Actions Cooperate
16.5 Creating New Variables Through Actions
16.6 Developing an Iterating Action
16.7 Creating the Tag Library Descriptor
16.8 Validating Syntax
16.9 How Tag Handlers May Be Reused
16.10 Packaging and Installing a Tag Library
17 Developing Database Access Components 235
17.1 Using Connections and Connection Pools
17.2 Using a Generic Database Bean
17.3 Developing Generic Database Custom Actions
17.4 Developing Application-Specific Database Components
iv Appendixes
In this part of the book, you find reference material, such as descriptions of JSP elements and classes, all book
example components, the web application deployment descriptor, and more.
A JSP Elements Syntax Reference 260
A.1 Directive Elements
A.2 Scripting Elements
A.3 Action Elements
A.4 Comments
A.5 Escape Characters
B JSP API Reference 270
B.1 Implicit Variables
B.2 Servlet Classes Accessible Through Implicit Variables
B.3 Tag Extension Classes
B.4 Other JSP Classes
C Book Example Custom Actions and Classes Reference 312
C.1 Generic Custom Actions
C.2 Internationalization Custom Actions
C.3 Database Custom Actions
C.4 Utility Classes
C.5 Database Access Classes
D Web-Application Structure and Deployment Descriptor Reference 337
D.1 Web Application File Structure
D.2 Web Application Deployment Descriptor
D.3 Creating a WAR File
E JSP Resource Reference 346
E.1 JSP-Related Products
E.2 Web Hosting
E.3 Information and Specifications
Colophon 350

Download
Another Web Programming books
Another Java books

No comments:

Post a Comment

Related Posts with Thumbnails

Put Your Ads Here!