没有合适的资源?快使用搜索试试~ 我知道了~
首页Stripes MVC框架详解:实战与进阶指南
Stripes MVC框架详解:实战与进阶指南
需积分: 4 9 下载量 140 浏览量
更新于2024-08-02
收藏 6.26MB PDF 举报
"《Stripes与Java Web开发:重拾乐趣》是一本针对Stripes Java Web MVC框架的专业指南,特别适合新手和经验丰富的开发者。作者以其清晰易懂的方式,全面介绍了Stripes的基本原理以及其独特功能,旨在帮助读者轻松上手并实践构建实际应用。书中强调了Stripes的实用开发理念,使得即使是初学者也能快速掌握,无需担心学习难度。 书中内容深入浅出,不仅覆盖了基础概念,还详细展示了各种Stripes特性的应用场景,确保读者能够理解并灵活运用。作者对所有可能的用法都提供了详尽的实例,避免了读者在遇到新特性时的困惑,如需了解如何使用某个功能,书中都有详尽的解答。对于熟悉Stripes的读者,如Jeppe Cramon,这本书提供了关于框架更深层次和鲜为人知细节的探讨,使他们在已有的基础上更进一步,增加了对Stripes智力和技巧层面的理解。 《Stripes与Java Web开发:重拾乐趣》不仅仅是一本技术手册,更像是一本工作台上的常备参考书籍,它将使开发者在使用Stripes进行web开发的过程中体验到高效和乐趣。无论是初次接触Stripes的新手,还是希望深化理解的老手,这都是一本不可或缺的资源。"
资源详情
资源推荐
![](https://csdnimg.cn/release/download_crawler_static/1781700/bg10.jpg)
GETTING THE MOST OUT OF THIS BOOK 16
convention and adding key-label pairs in a resource bundle.
• Exception handling: When an exception goes all the way up the
stack without being handled, the servlet container shows a big
ugly exception page. You don’t want your users to see that! Stripes
lets you show specific error pages for the exception types that you
care about and has a general “catchall” error page for all other
exceptions.
• Interceptors: When handling a request, Stripes goes through sev-
eral life-cycle stages before providing a response. Interceptors let
you write code that is called before or after any of these stages,
making it easy to alter the flow, change the data, and so on. Inter-
ceptors are a gr eat way of plugging in custom behavior.
• Customizable URLs: Stripes takes care of all the URL binding for
you, so you can wri te your whole application without ever bother-
ing with URLs. However, if you need specific URL patterns, Stripes
lets you do that too.
• Easy Ajax integration: With the simple and transparent request-
response nature of St ripes, you can Ajaxify your applications by
using your favorite Ajax framework as a front end and Stripes as
a back end.
• T esting: Stripes comes with a built-in set of mock objects that
help you write automated unit tests to make sure your application
works as expected.
• Easy extension and customization: Stripes is designed in a modu-
lar fashion with many areas to hook into. You can plug in different
behavior for any part of the framework. Extensibility is an area
where St ripes really shines, and if you’re not used to being able
to easily insert custom code into a framework, you’re in for a real
treat.
1.2 Getting the Most Out of This Book
Here is some information that will help you get the most out of this
book.
What You Should Already Know
I assume you know the basics of J ava web application developme
nt,
including compiling Java code, creat i ng a web application, packaging
a WAR file, and deploying to a servlet container. You should also be
familiar with JSPs and t he Expression Lang uage (EL).
Report erratum
this copy is (P1.0 printing, October 2008)
Prepared exclusively for Trieu Nguyen
Download at Boykma.Com
![](https://csdnimg.cn/release/download_crawler_static/1781700/bg11.jpg)
GETTING THE MOST OUT OF THIS BOOK 17
If you need a refresher, you’ll find a myriad of tutorials and examples
on the Net. Here are a few good places to start:
The Java Tutorial . .. ..
http://java.sun.com/javaee5/docs/tutorial/doc/bnadr.
html
The web application section of the Java Tutorial
JSP Syntax Reference. . .
. . .
http://java.sun.com/products/jsp/syntax/2.0/syntaxref20.html
Handy reference on JSP syntax, EL expressions, directives, and standard JSP
tags
Java with Passion! . . ... ... . .. . .. . ... .. . ... ..
http://www.javapassion.com/j2ee
Sang Shin’s online course for learning Java web application d
evelopment
NetBeans Tutorial . . ... ... ... ... . .. .
http://www.netbeans.org/kb/trails/web.html
A tutorial for creating web applications with the NetBeans ID
E
Eclipse Tutorial. . .
. . .
http://www.eclipse.org/webtools/community/tutorials/BuildJ2EEWebApp/BuildJ2EEWebApp.html
A tutorial for creating web applications with the Eclipse IDE
Getting the Source Code
This book comes with a lot of sour ce code so that you can learn Stripes
by example. Of course, the text contains code snippets along with expla-
nations. Although I’ve done my best to include enough context around
the code shown in the book so that it makes sense, I didn’t want to
bombard you with pages upon pages of code l i stings. When you want
to see the full source and navigate through the code at your mind’s
desire, the best thing to do is to download the source package and use
your favorite text editor or IDE. W hile you’re at it, there’s a good chance
you’ll want to try a few things of your own. Go ahead—that’s a great
way to l earn.
You can download the source code fr om this location:
http://www.pragprog.com/titles/fdstr/source_code
Conventions
I use a few simple conventions in this book, which you’ll recog
nize if
you’ve read other books by the Pragmatic Programmers.
Live Code
The majority of code sni ppets in the book are extracted from fully
functional examples. When that’s the case, a bar before the code
contains the path t o the source file.
Report erratum
this copy is (P1.0 printing, October 2008)
Prepared exclusively for Trieu Nguyen
Download at Boykma.Com
![](https://csdnimg.cn/release/download_crawler_static/1781700/bg12.jpg)
GETTING THE MOST OUT OF THIS BOOK 18
For example:
Download getting_started/web/WEB-INF/jsp/hello. j sp
<p>
Date and time: ${actionBean.date}
</p>
If you’ve downloaded the source code package, you’ll find the fi
le
using that path. If you’re reading the PDF version of this book with
a PDF viewer that supports hyperlinks, it’s even easier: just click
the bar, and the code will appear in a browser window. If your
browser mistakenly tries to inter pret the file as HTML, just view
the page source, and you’ll see the real code.
Joe Asks...
Joe, the mythical developer, sometimes pops up to ask questions
about what I’m discussing in t he text. I answer these questions as
I go along.
Tim Says...
Tim Fennell, who created Stripes, has some wisdom to share every
now and then. Look for these Tim Says... sidebars to read his
rationale, recommendations, and colour (he’s English, so he spells
it with a u) commentary.
Road Map
This book is organized in three parts. Part I is about learning
the differ-
ent parts of Stri pes and how they work. After setting up a development
environment and getting a “Hello, World!” example running to make
sure everyt hing works, you start building the sample application that
you’ll keep improving throughout th e book. In Part II, you are ready to
use Stripes to add more sophisticated functionality to the application.
By Part III, you’ll move on to some of the mor e advanced features of
Stripes and will also learn how to integrate third-party libraries such
as Hibernate, Spring, Guice, JUnit, and jQuery.
Stripes Ver sion
This book covers Stripes 1.5. If you are using a previous versi
on of
Stripes, consider upgrading to 1.5 for your next project because this
version has many interesting new features th at make developing with
Stripes even more enjoyable.
Report erratum
this copy is (P1.0 printing, October 2008)
Prepared exclusively for Trieu Nguyen
Download at Boykma.Com
![](https://csdnimg.cn/release/download_crawler_static/1781700/bg13.jpg)
ACKNOWLEDGMENTS 19
1.3 Acknowledgments
Writing this book has been a very fulfilling, challenging, enlighten-
ing, and rewarding experience. I have several people to thank. With-
out them, my lifelong dream of writing a computer book (admittedly, a
geek’s dream) would n ot have come true.
Dear Nadia, being married to you has made me happier than I could
ever imagine. You never stop believing in me, and for that I’ll always
be grateful. You are a wonderful wife, a fantastic mother, and the most
beautiful person I have ever known. I love you.
Lily Nadine, thank you for being such a bright, active, bouncing, laughing,
happy baby. Every day, you bring us a tremendous amount of joy .
Merci Papa et Maman, Wasfi et Viva, d’être des parents si merveilleux.
Vous faites toujours tout pour moi et j’en suis très reconnaissant. Merci
à vous deux d’avoir chacun eu le courage de surmonter de graves prob-
lèmes de santé. Je vous admire. Que Dieu vous bénisse.
Thank you, Tim Fennell, for creating such an excellent framework. I
was actually able to read and understand all th e source code! You truly
did a fantastic job. Thank you f or collaborating with me on thi s book,
contributing the Tim Says... boxes, reviewing my work, making sugges-
tions for improvement, and answering my questions. Thank you also
for welcoming me as a Stripes committer. Finally, thank you for being
such a great person. Being brilliant and humble at the same time is a
rare and terrific combination.
Thank you, Andy Hunt and Dave Thomas, the Pragmatic Program-
mers, for giving this book a chance in the first place. Special thanks
to Dave for being patient with all the back-and-forth for th e book cover
and to Andy for offering advice and always answering my questions so
promptly and helpfully.
Thank you, Jackie Carter, for tirelessly reviewing my work, offering
advice, alw ays being positive, and helping me make th i s book better.
Thank you, Tony George and Steve Francisco, for reviewing my early
drafts back when I had not yet found a publisher. You dedicated your
free time to help me, and I truly appreciate it.
Thank you, Ben Gunter, for answering all my questions and for con-
tributing such great features to Stripes.
Report erratum
this copy is (P1.0 printing, October 2008)
Prepared exclusively for Trieu Nguyen
Download at Boykma.Com
![](https://csdnimg.cn/release/download_crawler_static/1781700/bg14.jpg)
ACKNOWLEDGMENTS 20
Thank you, Aaron Porter, Chris Herron, Ben Gunter, Brandon Goodin,
Jasper Fontaine, Tim Fennell, and Jeppe Cramon, for participating in
the book’s technical review.
Thank you, Remi Vankeisbelck, Will Hartung, Jasper Fontaine, and
Jeppe Cramon, for reviewing my outline and offering your suggestions.
Thank you, Aaron Porter, for contributing Stripersist and the client-
side validation code and agreeing to having them featured in this book.
Special thanks for your patience in answering all my questions!
Thank you, Oscar Westra van Holthe-Kind, for contributing the Stripes
security package.
Thank you, Martijn Dashorst and Eelco Hillenius, for answering my
questions and offering advice on undertaking the tremendous challenge
of writing a computer book.
Finally, thank you, Stripers, for forming such a bright, h elpful, dyna-
mic, li vely, and f riendly community. That’s what Stripes is all about.
Report erratum
this copy is (P1.0 printing, October 2008)
Prepared exclusively for Trieu Nguyen
Download at Boykma.Com
剩余390页未读,继续阅读
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://profile-avatar.csdnimg.cn/default.jpg!1)
wangxin0072000
- 粉丝: 2
- 资源: 1
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助
![](https://csdnimg.cn/release/wenkucmsfe/public/img/voice.245cc511.png)
最新资源
- Hadoop生态系统与MapReduce详解
- MDS系列三相整流桥模块技术规格与特性
- MFC编程:指针与句柄获取全面解析
- LM06:多模4G高速数据模块,支持GSM至TD-LTE
- 使用Gradle与Nexus构建私有仓库
- JAVA编程规范指南:命名规则与文件样式
- EMC VNX5500 存储系统日常维护指南
- 大数据驱动的互联网用户体验深度管理策略
- 改进型Booth算法:32位浮点阵列乘法器的高速设计与算法比较
- H3CNE网络认证重点知识整理
- Linux环境下MongoDB的详细安装教程
- 压缩文法的等价变换与多余规则删除
- BRMS入门指南:JBOSS安装与基础操作详解
- Win7环境下Android开发环境配置全攻略
- SHT10 C语言程序与LCD1602显示实例及精度校准
- 反垃圾邮件技术:现状与前景
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
![](https://img-home.csdnimg.cn/images/20220527035711.png)
![](https://img-home.csdnimg.cn/images/20220527035711.png)
![](https://img-home.csdnimg.cn/images/20220527035111.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![](https://csdnimg.cn/release/wenkucmsfe/public/img/green-success.6a4acb44.png)