Inside Servlets: Server-Side Programming for the Java Platform, 2/e (Paperback)
暫譯: Servlet 內部揭秘:Java 平台的伺服器端程式設計,第 2 版 (平裝本)

Dustin R. Callaway

  • 出版商: Addison Wesley
  • 出版日期: 2001-05-14
  • 定價: $1,575
  • 售價: 2.5$399
  • 語言: 英文
  • 頁數: 920
  • 裝訂: Paperback
  • ISBN: 0201709066
  • ISBN-13: 9780201709063
  • 相關分類: Java 程式語言Java 相關技術
  • 立即出貨(限量) (庫存=9)

買這商品的人也買了...

相關主題

商品描述


Description

The Servlets best-seller for serious programmers -- thoroughly updated for the new Servlets 2.2 API!

  • Extensive new coverage: Deployment, security, authentication, internationalization, JSP, database integration, and more.
  • Advanced topics: state/session management, concurrency, cross-request communications, request forwarding, and partitioning.
  • CD-ROM: Extensive, fully updated library of ready-to-use servlet code.
Java servlets are the killer app for server-side programming. They represent the first cross-platform solution for server-side development that delivers the performance developers require -- and they've been incorporated into nearly every leading Web server platform. Inside Servlets, Second Edition teaches developers all they need to build robust, powerful servlets with Sun's new Servlets 2.2 API. It combines detailed, real-world projects, a comprehensive API reference, and extensive new coverage of crucial topics ranging from security to database integration. The book starts with a brief, crystal-clear introduction to servlet technology and architecture -- and then dives into the sophisticated techniques Java developers need to make the most of their servlets. Dustin Callaway provides a complete development framework for building Internet applications, as well as three start-to-finish sample servlets. He also offers outstanding, code-rich explanations of key techniques such as state/session management, cookies, thread-safe servlets, JDBC database access, cross-request communications, request forwarding, and partitioning. This Second Edition adds extensive coverage of deployment, servlet security and authentication, internationalization, JavaServer Pages, and more.

Dustin R. Callaway is a consultant, developer, author, and instructor specializing in Java and Internet technologies. He is currently a software engineer for Home Financial Network, specializing in developing Java-based Internet banking software. As senior programmer/analyst for Nu Skin International, he converted the firm's entire Web architecture to the Java Servlet API. He has served as a technical consultant for Arthur Andersen.

Back to Top


Table Of Contents

Foreword.
Preface.
Introduction.

I. INTRODUCTION TO WEB DEVELOPMENT.

Internet Basics 3.
Networks. Protocols. TCP/IP. Brief History of the Internet. Internet Addresses. Ports. Socket. Name Resolution. Firewalls. Protocol Tunneling. Proxy Servers. Internet Standards. Summary.

2. Web Basics.
Brief History of the Web. URLs. Web Browsers. Web Servers. Common Gateway Interface. Summary.

3. Beyond Web Basics.
HTTP. MIME. HTML Forms. Summary.

II. INTRODUCTION TO SERVLETS.


4. Why Servlets?
What Is a Servlet? Where Do Servlets Fit In? What Can Servlets Do? Why Are Servlets Better Than CGI? NSAPI/ISAPI. Summary.

5. Servlet Basics.
Basic Servlet Structure. Servlet Lifecycle. Servlet Reloading. Dissecting Two Sample Servlets. Summary.

6. Servlet API Basics.
HttpServlet. Class. GenericServlet. Class. ServletRequest Interface. HttpServletRequest Interface. ServletResponse Interface. HttpServletResponse Interface. Summary.

7. Writing Your First Servlet.
Servlet Requirements. Main Page. View Bulletins. Post Bulletin Page. Save Bulletin Page. Complete Bulletin Board Servlet. Summary 193

8 Running Servlets.
Apache Tomcat. Jrun. ServletExec. Resin. Summary.

9. Debugging Servlets. AHEADS = Servlet Debugging Process. Jbuilder. Forte for Java. VisualCaf. Summary.
10. Beyond Servlet API Basics.
ServletInputStream Class.ServletOutputStream Class. ServletConfig Interface. ServletContext Interface. ServletException Class. UnavailableException Class. Summary.

III. ADVANCED SERVLET CONCEPTS.


11. Writing Thread-Safe Servlets.
What Is Thread Safety? Synchronization. Service, doGet, and doPost Local Variables. SingleThreadModel Interface. Background Threads. Summary.

12. HTTP Redirects.
What Is an HTTP Redirect? HTTP Header Syntax for a Redirect. Sending a Redirect from a Servlet. Load-Balancing Servlet Using HTTP Redirects. Summary.

13. Cookies.
What Is a Cookie? HTTP Header Syntax for a Cookie. Setting Cookies with the Servlet API. Summary. @CHAPTER 14. State and Session Management.
What Is a Stateless Protocol? What Is a Session? State and Session Management Defined. State and Session Management Methods. Session Management with the Servlet API. Session Listeners and Events. Summary.

15. Request Forwarding, Server-Side Includes, Servlet Chaining.
Using the RequestDispatcher Object. Server-Side Includes. Servlet Chaining. Summary.

16. Database Access with JDBC.
JDBC Architecture. Accessing a Database. Basics. Advanced Database Concepts. Database Connection Pooling. Introduction to the MySQL Database. Summary.

17. Security.
Basic Authentication. Form-Based Authentication. Digest Authentication. Secure Sockets Layer. Summary.

18. JavaServer.
Introduction to JSP. Scope Rules. Implicit Objects. Directives. Scripting Elements. Comments. Actions. CCustom Tag Libraries. Using JSP and Servlets Together. Summary.

19. Packaging and Deployment. @AHEADS Building a Web Application Archive. Deploying on Apache Tomcat. Deploying on Jrun. Deploying on ServletExec. Summary.
20. Servlet Troubleshooting.
Protocol Explorer Utility. Diagnostics Servlet. Summary.

IV. SAMPLE SERVLETS.


21. Form Mailer Servlet.
22. File Upload Servlet.
23. Servlet Template Framework.
Building a Web Application. Inside the Template Server. Guest Book Sample Application.

V. SERVLET API QUICK REFERENCE.


24. Javax.Servlet Package.
Interface RequestDispatcher. Interface Servlet. Interface ServletConfig. Interface ServletContext. Interface ServletRequest. Interface ServletResponse. Interface SingleThreadModel. Class Generic Servlet. Class ServletInputStream. Class ServletOutputStream. Class ServletException. Class UnavailableException

25. Javax.Servlet.http Package. Interface HttpServletRequest. Interface HttpServletResponse. Interface HttpSession. Interface HttpSessionBindingListener. Class Cookie. Class HttpServlet. Class HttpSessionBindingEvent. Class HttpUtils.
26. Servlet API 2.3 Update.
Filtering. Application Lifecycle Events. Shared Library Dependencies. New Error and Security Attributes. Welcome Files. New Classes, Interfaces, and Methods.

VI. APPENDICES.


A: Common Well-Known Port Assignments.
B: Java Port Scanner.
C: The Internet Standardization Process.
D: URL Syntax for Common Protocols.
E: Meaning of URL Special Characters.
F: US-ASCII Encoding for Unsafe URL Characters.
G: Java HTTP Server.
H: HTTP Response Status Codes.
I: Common HTTP Request Header Fields.
J: Deployment Descriptor DTD.
K: Common MIME Types.
L: printStackTrace to String.
M: Servlet API Class Hierarchy Diagram.
Index. 0201709066T04272001


Back to Top

商品描述(中文翻譯)

描述
《Servlets》是專為認真程式設計師所編寫的暢銷書——全面更新至新的 Servlets 2.2 API!
- 廣泛的新內容:部署、安全性、身份驗證、國際化、JSP、資料庫整合等。
- 進階主題:狀態/會話管理、併發、跨請求通訊、請求轉發和分區。
- CD-ROM:廣泛且完全更新的可即用 servlet 代碼庫。

Java servlets 是伺服器端程式設計的< I>殺手級應用。它們代表了伺服器端開發的第一個跨平台解決方案,提供開發人員所需的性能——並且已被整合到幾乎所有主要的 Web 伺服器平台中。《Inside Servlets, Second Edition》教導開發人員如何使用 Sun 的新 Servlets 2.2 API 建立穩健且強大的 servlets。它結合了詳細的實際專案、全面的 API 參考,以及對從安全性到資料庫整合等關鍵主題的廣泛新內容。本書以簡短且清晰的 servlet 技術和架構介紹開始,然後深入探討 Java 開發人員需要掌握的複雜技術,以充分利用他們的 servlets。Dustin Callaway 提供了一個完整的開發框架,用於構建網際網路應用程式,以及三個從頭到尾的範例 servlets。他還提供了關鍵技術的出色、代碼豐富的解釋,例如狀態/會話管理、cookies、線程安全的 servlets、JDBC 資料庫訪問、跨請求通訊、請求轉發和分區。本第二版增加了對部署、servlet 安全性和身份驗證、國際化、JavaServer Pages 等的廣泛覆蓋。

Dustin R. Callaway 是一位顧問、開發人員、作者和講師,專注於 Java 和網際網路技術。他目前是 Home Financial Network 的軟體工程師,專注於開發基於 Java 的網路銀行軟體。作為 Nu Skin International 的高級程式設計師/分析師,他將公司的整個 Web 架構轉換為 Java Servlet API。他曾擔任 Arthur Andersen 的技術顧問。

目錄
- 前言
- 序言
- 介紹

I. 網頁開發介紹
1. 網際網路基礎
- 網路、協議、TCP/IP、網際網路簡史、網際網路地址、端口、socket、名稱解析、防火牆、協議隧道、代理伺服器、網際網路標準、總結
2. 網頁基礎
- 網頁簡史、URL、網頁瀏覽器、網頁伺服器、通用閘道介面、總結
3. 超越網頁基礎
- HTTP、MIME、HTML 表單、總結

II. Servlet 介紹
4. 為什麼選擇 Servlets?
- 什麼是 Servlet?Servlet 的位置?Servlet 可以做什麼?為什麼 Servlets 比 CGI 更好?NSAPI/ISAPI、總結
5. Servlet 基礎
- 基本 Servlet 結構、Servlet 生命週期、Servlet 重新加載、剖析兩個範例 Servlets、總結
6. Servlet API 基礎
- HttpServlet 類、GenericServlet 類、ServletRequest 介面、HttpServletRequest 介面、ServletResponse 介面、HttpServletResponse 介面、總結
7. 撰寫您的第一個 Servlet
- Servlet 要求、主頁、查看公告、發佈公告頁、保存公告頁、完整公告板 Servlet、總結
8. 執行 Servlets
- Apache Tomcat、Jrun、ServletExec、Resin、總結
9. 除錯 Servlets
- AHEADS = Servlet 除錯過程、Jbuilder、Forte for Java、VisualCaf、總結
10. 超越 Servlet API 基礎
- ServletInputStream 類、ServletOutputStream 類、ServletConfig 介面、ServletContext 介面、ServletException 類、UnavailableException 類、總結

III. 進階 Servlet 概念
11. 撰寫線程安全的 Servlets
- 什麼是線程安全?同步、服務、doGet 和 doPost 本地變數、SingleThreadModel 介面、背景線程、總結
12. HTTP 重新導向
- 什麼是 HTTP 重新導向?重新導向的 HTTP 標頭語法、從 Servlet 發送重新導向、使用 HTTP 重新導向的負載平衡 Servlet、總結
13. Cookies
- 什麼是 Cookie?Cookie 的 HTTP 標頭語法、使用 Servlet API 設置 Cookies、總結
14. 狀態和會話管理
- 什麼是無狀態協議?什麼是會話?狀態和會話管理定義、狀態和會話管理方法、使用 Servlet API 的會話管理、會話監聽器和事件、總結
15. 請求轉發、伺服器端包含、Servlet 鏈接
- 使用 RequestDispatcher 物件、伺服器端包含、Servlet 鏈接、總結
16. 使用 JDBC 訪問資料庫
- JDBC 架構、訪問資料庫、基礎、進階資料庫概念、資料庫連接池、MySQL 資料庫簡介、總結
17. 安全性
- 基本身份驗證、基於表單的身份驗證、摘要身份驗證、安全套接字層、總結
18. JavaServer
- JSP 簡介、範圍規則、隱含物件、指令、腳本元素、註解、動作、自定義標籤庫、同時使用 JSP 和 Servlets、總結
19. 打包和部署
- AHEADS 建立網頁應用程式檔案、在 Apache Tomcat 上部署、在 Jrun 上部署、在 ServletExec 上部署、總結
20. Servlet 故障排除
- 協議探索工具、診斷 Servlet、總結

IV. 範例 Servlets
21. 表單郵件 Servlet
22. 檔案上傳 Servlet
23. Servlet 模板框架
- 建立網頁應用程式、模板伺服器內部、訪客簿範例應用程式

V. Servlet API 快速參考
24. Javax.Servlet 套件
- 介面 RequestDispatcher、介面 Servlet、介面 ServletConfig、介面 ServletContext、介面 ServletRequest、介面 ServletResponse、介面 SingleThreadModel、類 Generic Servlet、類 ServletInputStream、類 ServletOutputStream、類 ServletException、類 UnavailableException
25. Javax.Servlet.http 套件
- 介面 HttpServletRequest、介面 HttpServletResponse、介面 HttpSession、介面 HttpSessionBindingListener、類 Cookie、類 HttpServlet、類 HttpSessionBindingEvent、類 HttpUtils
26. Servlet API 2.3 更新
- 過濾、應用程式生命週期事件、共享庫依賴、新的錯誤和安全屬性、歡迎檔案、新的類、介面和方法

VI. 附錄
A: 常見的知名端口分配
B: Java 端口掃描器
C: 網際網路標準化過程
D: 常見協議的 URL 語法
E: URL 特殊字符的含義
F: 不安全 URL 字符的 US-ASCII 編碼
G: Java HTTP 伺服器
H: HTTP 回應狀態碼
I: 常見 HTTP 請求標頭欄位
J: 部署描述符 DTD
K: 常見 MIME 類型
L: printStackTrace 轉為字串
M: Servlet API 類別層次結構圖
索引