
At a Glance
400 Pages
23.5 x 19.05 x 3.18
Paperback
$120.99
or 4 interest-free payments of $30.25 with
 orÂShips in 5 to 10 business days
WebWork helps developers build well-designed applications quickly by creating re-usable, modular, web-based applications. WebWork in Action is the first book to focus entirely on WebWork. Like a true "Action" book, it is both a tutorial on WebWork and a sourcebook for its use in demanding, real-world applications. The book goes into considerable depth on how to get desirable web features with WebWork. It uses the same basic (continuing) example as in Manning's Hibernate in Action to show how to integrate WebWork with the popular Hibernate persistance framework.
Although Java was (correctly) touted as the next big programming language, it wasn't until the introduction of J2EE and Servlets that its use really took off. Yet, in spite of the huge popularity of JSPs and Servlets, it was never easy for developers to quickly create re-usable, modular web-based applications. Not long after the introduction of JSPs, WebWork sought to solve those very problems and has been helping thousands of developers ever since. WebWork is a web-application framework used by people who understand that somewhere been "just get it done, no matter how ugly" and "make it perfect" lies their best choice. WebWork helps developers build applications quickly, but its unique design also lets developers build beautifully-designed applications.
| Foreword | p. xv |
| Preface | p. xvii |
| Acknowledgments | p. xix |
| About this book | p. xxi |
| A look at the future | p. xxvi |
| About the title | p. xxvii |
| About the cover illustration | p. xxviii |
| Introduction to WebWork | p. 1 |
| An overview of WebWork | p. 3 |
| Why MVC is important | p. 5 |
| Classic MVC becomes outdated | p. 6 |
| Classic MVC gets an update: the Front Controller | p. 7 |
| MVC evolves: the Page Controller | p. 7 |
| Understanding frameworks and containers | p. 9 |
| What is a framework? | p. 9 |
| What a container can do | p. 11 |
| WebWork: past, present, and future | p. 13 |
| The history of WebWork | p. 13 |
| Understanding the XWork core | p. 13 |
| Future directions | p. 15 |
| The CaveatEmptor application | p. 15 |
| How CaveatEmptor is organized | p. 16 |
| Summary | p. 17 |
| HelloWorld, the WebWork way | p. 19 |
| Downloading WebWork | p. 20 |
| Preparing the skeleton | p. 20 |
| Creating the web.xml deployment file | p. 21 |
| Creating the xwork.xml configuration file | p. 23 |
| Creating the webwork.properties configuration file | p. 23 |
| Tips for developing WebWork apps | p. 24 |
| Your first action | p. 24 |
| Saying hello, the WebWork way | p. 25 |
| Displaying output to the web browser | p. 26 |
| Configuring your new action | p. 27 |
| Dealing with inputs | p. 28 |
| Advanced control flow | p. 31 |
| Letting WebWork do the work | p. 33 |
| Taking advantage of ActionSupport | p. 34 |
| Intermediate modifications to the JSP | p. 35 |
| Exploring the UI tag library | p. 36 |
| Summary | p. 37 |
| Setting up WebWork | p. 38 |
| Configuring actions, results, and interceptors | p. 39 |
| Overview of terminology | p. 39 |
| Actions | p. 40 |
| Results | p. 46 |
| Interceptors | p. 48 |
| Advanced configuration | p. 52 |
| The xwork.xml DTD | p. 52 |
| Namespaces and packages | p. 53 |
| Componentization using the include tag | p. 57 |
| Other configuration files | p. 66 |
| Web-app configuration: web.xml | p. 66 |
| Feature configuration: webwork.properties | p. 67 |
| Setting up your web app | p. 70 |
| General layout | p. 70 |
| Required libraries | p. 71 |
| Optional libraries | p. 72 |
| Summary | p. 72 |
| Core concepts | p. 75 |
| Implementing WebWork actions | p. 77 |
| The Action interface | p. 78 |
| Result codes | p. 78 |
| Handling exceptions | p. 79 |
| Using the ActionSupport base class | p. 80 |
| Understanding basic validation | p. 80 |
| Validating an action: Validateable | p. 81 |
| Displaying error messages: ValidationAware | p. 82 |
| Using localized message texts | p. 86 |
| Retrieving the user's locale: LocaleProvider | p. 86 |
| Displaying the localized text: TextProvider | p. 86 |
| Providing messages for other languages | p. 89 |
| Advanced inputs | p. 90 |
| Intermediary objects | p. 90 |
| Using domain objects directly | p. 91 |
| Working with ModelDriven actions | p. 95 |
| Implementing ModelDriven actions | p. 96 |
| Considerations when using ModelDriven | p. 100 |
| Accessing data through the ActionContext | p. 102 |
| CaveatEmptor: accessing the session | p. 102 |
| Example: accessing the request and response | p. 105 |
| Handling file uploads | p. 107 |
| Accessing uploaded files through the request wrapper | p. 107 |
| Automating file uploads | p. 109 |
| Configuration settings | p. 110 |
| Summary | p. 111 |
| Adding functionality with interceptors | p. 112 |
| How interceptors are called | p. 113 |
| Using the prepackaged interceptors | p. 114 |
| Utility interceptors | p. 117 |
| Setting parameters | p. 119 |
| Defining workflow | p. 123 |
| Using prepackaged interceptor stacks | p. 126 |
| Building your own interceptors | p. 128 |
| Using the AroundInterceptor as a base | p. 129 |
| Looking at an example custom interceptor | p. 130 |
| Getting callbacks before the result is executed with the PreResultListener | p. 133 |
| Looking out for interceptor interactions | p. 134 |
| Interceptors vs. servlet filters | p. 135 |
| Summary | p. 136 |
| Inversion of Control | p. 137 |
| Examining the pattern | p. 138 |
| Common patterns for active resource management | p. 138 |
| Inverting resource management | p. 142 |
| How IoC helps with testing | p. 145 |
| IoC essentials | p. 146 |
| WebWork's IoC history | p. 146 |
| Dependencies | p. 148 |
| Scope and lifecycle | p. 149 |
| Using WebWork's IoC framework | p. 151 |
| Configuration | p. 151 |
| Creating a new component | p. 154 |
| Using IoC on any object | p. 158 |
| Dealing with complex dependencies | p. 159 |
| An example from CaveatEmptor | p. 162 |
| The HibernateSessionFactory component | p. 163 |
| The Persistence Manager component | p. 165 |
| Configuring the components | p. 168 |
| Using the new components | p. 169 |
| Alternatives | p. 170 |
| Alternative IoC containers | p. 170 |
| Non-IoC alternatives | p. 172 |
| Summary | p. 173 |
| Displaying content | p. 175 |
| Using results | p. 177 |
| Life after the action | p. 178 |
| A simple result | p. 178 |
| Configuring a result | p. 180 |
| Common results | p. 182 |
| Dispatching to a page | p. 182 |
| Redirecting to a page | p. 188 |
| Chaining to another action | p. 192 |
| Other results | p. 197 |
| Streaming Velocity templates directly to the output | p. 197 |
| FreeMarker: an alternative to Velocity | p. 202 |
| Generating reports with JasperReports | p. 203 |
| Summary | p. 207 |
| Getting data with the expression language | p. 209 |
| What is an expression language? | p. 210 |
| Why an expression language? | p. 210 |
| Why OGNL? | p. 211 |
| Other expression languages | p. 212 |
| Key OGNL concepts | p. 213 |
| Basic expression language features | p. 213 |
| Accessing bean properties | p. 214 |
| Literals and operators | p. 215 |
| Calling methods | p. 217 |
| Setting values and expression lists | p. 218 |
| Accessing static methods and fields | p. 218 |
| Accessing the OGNL context and the ActionContext | p. 218 |
| Working with collections | p. 220 |
| Working with lists and arrays | p. 220 |
| Working with maps | p. 221 |
| Filtering and projecting collections | p. 222 |
| The multiple uses of "#" | p. 223 |
| Advanced expression language features | p. 224 |
| Linking the value stack to the expression language | p. 224 |
| Data type conversion | p. 226 |
| Handling null property access | p. 227 |
| Creating lambda expressions on the fly | p. 228 |
| Summary | p. 228 |
| Tag libraries | p. 230 |
| Getting started | p. 231 |
| An overview of WebWork tags | p. 232 |
| The WebWork tag syntax | p. 233 |
| Data tags | p. 235 |
| The property tag | p. 235 |
| The set tag | p. 236 |
| The push tag | p. 237 |
| The bean tag | p. 238 |
| The action tag | p. 240 |
| Control tags | p. 242 |
| The iterator tag | p. 242 |
| The if and else tags | p. 245 |
| Miscellaneous tags | p. 246 |
| The include tag | p. 246 |
| The URL tag | p. 247 |
| The i18n and text tags | p. 250 |
| The param tag | p. 252 |
| Summary | p. 253 |
| Velocity | p. 254 |
| Introduction to Velocity | p. 255 |
| What is Velocity? | p. 255 |
| Getting ready to use Velocity | p. 257 |
| Basic syntax and operations | p. 259 |
| Property access | p. 259 |
| Method calls | p. 261 |
| Control statements: if/else and loops | p. 261 |
| Assigning variables | p. 265 |
| Advanced techniques | p. 265 |
| The VelocityContext | p. 265 |
| WebWork-supplied objects in the context | p. 266 |
| Customizing the Velocity context | p. 267 |
| Using JSP tags in Velocity | p. 268 |
| Loading Velocity templates | p. 269 |
| Summary | p. 269 |
| UI components | p. 271 |
| Why bother with UI tags? | p. 272 |
| Eliminating the pain | p. 272 |
| More than just form elements | p. 280 |
| UI tag overview | p. 283 |
| Templates | p. 283 |
| Themes | p. 285 |
| Tag attributes | p. 291 |
| UI tag reference | p. 291 |
| Common attributes | p. 291 |
| Simple tags | p. 294 |
| Collection-based tags | p. 299 |
| Advanced tags | p. 305 |
| Summary | p. 309 |
| Advanced topics | p. 311 |
| Type conversion | p. 313 |
| Why type conversion? | p. 314 |
| The Servlet specification | p. 314 |
| An action without type conversion | p. 315 |
| A view without type conversion | p. 317 |
| What WebWork's type conversion gives you | p. 319 |
| Configuration | p. 320 |
| Role of a type converter | p. 321 |
| Global type converters | p. 322 |
| Class-level type converters | p. 322 |
| Simple type conversion | p. 323 |
| Basic type conversion | p. 323 |
| Built-in type conversion | p. 325 |
| Handling null property access | p. 326 |
| Advanced topics | p. 326 |
| Handling null Collection access | p. 326 |
| Handling conversion errors | p. 329 |
| An example that puts it all together | p. 330 |
| Summary | p. 331 |
| Validating form data | p. 333 |
| Manually validating data | p. 336 |
| Validating in the execute() method | p. 336 |
| Implementing the Validateable interface | p. 337 |
| Using the Validation Framework | p. 340 |
| Building your first *-validation.xml file | p. 340 |
| Registering validators | p. 341 |
| Applying the validation interceptor | p. 345 |
| Pulling it all together | p. 346 |
| Looking at some validation XML examples | p. 348 |
| Exploring the advanced features of the Validation Framework | p. 350 |
| Implementing a custom validator | p. 351 |
| Validating with different contexts | p. 353 |
| Short-circuiting validation | p. 354 |
| The Expression Validator | p. 355 |
| Reusing validations with the visitor field validator | p. 356 |
| Summary | p. 359 |
| Internationalization | p. 360 |
| Exploring a quick internationalization example | p. 361 |
| Sources for messages | p. 362 |
| Understanding the ResourceBundle search order | p. 364 |
| Adding default resource bundles | p. 366 |
| The | p. 366 |
| Using internationalized messages | p. 368 |
| Parameterizing localized texts | p. 368 |
| Using getText() in taglib attributes | p. 369 |
| Formatting dates and numbers | p. 370 |
| Using localized messages in validations | p. 370 |
| Using internationalized texts for type conversion messages | p. 371 |
| Tips and tricks | p. 373 |
| Programmatically setting the locale | p. 373 |
| Implementing ResourceBundles as classes | p. 375 |
| Using the | p. 378 |
| Setting the encoding: here, there, and everywhere | p. 381 |
| A note on Java PropertyResourceBundles | p. 382 |
| A final note | p. 382 |
| Summary | p. 383 |
| Best practices | p. 384 |
| Setting up your environment | p. 385 |
| Setting up your IDE | p. 386 |
| Reloading resources | p. 388 |
| Unit-testing your actions | p. 389 |
| Using mock objects | p. 389 |
| The advantage of IoC for testing | p. 391 |
| Handling statics and ThreadLocals | p. 391 |
| Putting the pieces together: integration testing | p. 393 |
| Testing your configuration | p. 393 |
| Seeing the configuration with the config browser | p. 396 |
| Testing validations | p. 398 |
| Testing programmatic validations | p. 398 |
| Testing validation.xml files | p. 398 |
| Advanced UI tag usage | p. 402 |
| Overriding existing templates | p. 403 |
| Writing custom templates | p. 406 |
| Writing custom themes | p. 407 |
| Using form tokens to prevent duplicate form submissions | p. 409 |
| Using the | p. 410 |
| Applying the TokenInterceptor | p. 412 |
| Transparently re-rendering pages with the TokenSessionStoreInterceptor | p. 413 |
| Displaying wait pages automatically | p. 413 |
| A Single action for CRUD operations | p. 417 |
| Creating new categories with newCategory | p. 418 |
| Reading and updating with viewCategory and editCategory | p. 419 |
| Saving categories with saveCategory | p. 420 |
| Setting the parentCategory | p. 422 |
| Summary | p. 423 |
| WebWork architecture | p. 424 |
| Index | p. 439 |
| Table of Contents provided by Ingram. All Rights Reserved. |
ISBN: 9781932394535
ISBN-10: 1932394532
Series: In Action
Published: 13th October 2005
Format: Paperback
Language: English
Number of Pages: 400
Audience: College, Tertiary and University
Publisher: MANNING PUBN
Country of Publication: US
Dimensions (cm): 23.5 x 19.05 x 3.18
Weight (kg): 0.8
Shipping
| Standard Shipping | Express Shipping | |
|---|---|---|
| Metro postcodes: | $9.99 | $14.95 |
| Regional postcodes: | $9.99 | $14.95 |
| Rural postcodes: | $9.99 | $14.95 |
Orders over $79.00 qualify for free shipping.
How to return your order
At Booktopia, we offer hassle-free returns in accordance with our returns policy. If you wish to return an item, please get in touch with Booktopia Customer Care.
Additional postage charges may be applicable.
Defective items
If there is a problem with any of the items received for your order then the Booktopia Customer Care team is ready to assist you.
For more info please visit our Help Centre.
























