Index

Symbols
 
@ 55, 84
$content$ 245
$remove$ 83, 184
/app 90
 
A
 
absolute paths 371
abstract methods 99–101
AbstractComponent 33, 59, 75
AbstractPage 147
accessor methods 81, 101, 128, 223, 225, 228, 237, 308, 529
action service 494
Actions 37
activate 62
ActivateCallback 445
ActivatePage 411, 444
active page 62, 100
AdminPage 411
advertising sites, international-ization of 309
Ant 29
Ant build scripts 385
anti-patterns 13, 15
bad coding shortcuts 15
unwanted dependencies 13, 98
weak binding 13, 95
Apache 25, 480
Apache Tomcat 7
application callback 55
application extensions 328, 520
application flow 41
application layer 19–20, 404, 411
application server cluster 409
application servers 11, 18
class loaders 273
clusters 275
hot application redeploy-ment 273
JBoss 405, 480
servlets
      See application servlets
WebLogic 276, 405
application servlets
application operations, han-dling 280
as gateways 271–272
bridging between HTTP and 299
clusters and 272
engine services and 279
HTTP protocol 271
JavaBeans 271
mapping changes 279
multithreading, impact on 271
overview 271
page use compared to use of 300
relationship between JSPs and 279
request processing 270–271
return of engine instance to HttpSession 272
Servlet API 271, 273
stale session 285
stateful 285
stateless 272
URLs 279, 284, 290
application specifications 91, 517
application tier 44
ApplicationRuntimeException 53
applications
banner source in specifica-tions 339
border components and 217
changing locales for 317
compartmentalizing 262
continuing operation with missing message strings 315
Demo 12
desktop 13, 16
engines and 277
enterprise 12
examples of
      See example applications
extremely large, Tapestry framework and 274
file extension of specifications 254
forwarding requests to 369
highly complex, Tapestry framework and 274
hybrid 369
integrating with JSP 369
JavaBean construction of 299
language proficiency for 263
libraries and 256
library for services and com-ponents 336
linking from JSPs to 371
localization of 309
look and feel of 217
multi-user, Tapestry frame-work and 274
overriding default locations of component specifica-tions 256
resource storage 261
root element for specifica-tions 256
servlets
      See application servlets
specifications 254
stateless 61
URLs 333, 371
usable 170, 192, 211
user expectations 170
user-presentable names for 256
validation of input 179
web, localization of 309
ApplicationServlet 276, 409
application-specific logic 5, 22, 57
architecture 16
array types 228
ArrayList 126
asset services 267
assets 70, 75–76, 79, 184, 437, 523
context 267
duplication removal 244
image representation with 316
localization and 316
private 267
using locales to deteremine URLs 317
attributes
acceptance of unquoted 295
allow-body 219–220
allow-informal-parameters 219, 221
class 219
copying 275
direction 224, 226, 229, 251
href 13, 250
HttpSession 272, 274
initial-value 308
key 314
of parameter element 222
quoting 296
serializing 275
session 22
src 230, 236
usemap 246
authentication 10, 96, 100, 407
automatic integration 339
AWT 18
 
B
 
bad coding shortcuts 15
banner ads
applications, building 337
BannerAd component 329
CreditCardField script
      See CreditCardField script
data access 328
data model 326
DirectLink component of 325
function names 351
library specifications 336
page scripts 339
request servicing 334
script blocks 352
service implementation 332
service naming 335
source 327
storage 338
symbols 349
system 324
BaseComponent 35
BaseEngine 407, 416
BasePage 35, 57, 61
binary output 163
BinaryDumpOutputStream 163, 165
binding objects
See bindings
binding property 223
bindings
accessing 223
digit parameter 232
invariant 226
literal values 226
localized messages 226
plugged into component parameters 223
storing for parameters 225
types of 223
updating values 226
blank fields 174
bodies, component
composition 220
discarding 220
Book 453, 457–458
Bookmarkable links 450
BookQuery bean 405–406, 419, 423, 425, 429–430
bookQuery property 419
bridging between stateless and stateful worlds 299
browser back button 129, 132, 134, 148, 151, 154
bugs 271, 276, 308
business processes 44, 104
 
C
 
caching 52, 406
calculations in pages 234
Cascading Style Sheets (CSS) 97, 176, 184, 191, 201–202, 205, 217, 221, 261, 314, 511
changes, tracking 301–302
characters
invalid 292
non-ASCII, conversion of 292
nonprinting, conversion of 292
reserved, conversion of 292
unsafe, converting to HTML entities 314
check boxes 104
choke points 14
ClassCastException 59
classes
AbstractComponent 218, 250, 304, 315
AbstractFormComponent 355, 363
AbstractService 334–335
Banner 327
BannerAd 329
BannerService 332
base 315, 335, 355, 363
BaseComponent 217–219, 302
BasePage 297
BaseValidator 198, 204
ComponentAddress 306
CreditCardField 348, 355– 356
CSS 221, 260
default 219
DirectLink 250
enhanced subclasses 308
examples.resume.Exerience 260
field-error 201
IActionListener 248
IEngineService instance 250
ILink 250
instantiation of a page?s Java 302
IValidationDelegate 208, 264
Java 179, 316, 356
java.io.PrintWriter 292
java.text.MessageFormt 316
label-error 201
Letter 237
ListEditMap 159
page 178
PatternValidator 199
PriorityModel 141
Register 194
RegisterDelegate 191
Tapestry 251
tapestry-palette 260
ToDoItem 137, 145, 155
UploadResults 163
utility 306
classpath 254, 256, 261, 267
client-side
JavaScript 174, 176, 198, 203, 339, 460
logic 6, 339
pop-up windows 203, 205
scripting 198, 203, 205, 339
validations 174, 176, 205
close tags, omitting 221
clustering 275, 308, 409
code
refactoring tools for changes in 280
URL construction 280
URL servlet 280
code duplication removal 244– 245, 262
Collection 472, 500
complex form 105, 120
component libraries 480
application specifications 254
classpath location 264
classpath location of JAR 254
component referencing 256
component storage in class-path 261
Contrib library 254, 256
declaring use of 254
distribution as JAR files 254, 266
ID prefix 260
IDs 256
Java package for 264
naming patterns 256
packaging reusable compo-nents into 261
Palette component 256
prefixing 256, 260
secondary 254
servlets of 255
specifications 218, 262
tapestry-contrib-3.0.jar 254
using components from 263
component objects
framework 50
hierarchy 50
model 17, 478
component parameters 58, 80
component specifications 28, 78, 521
attributes and elements of 219
beginning of 219
instantiation of components 219
name of file 218
new property declarations 308
processing requests and 270
purpose of 219
sources of files 218
storage of 217
component templates
request processing and 270
component-oriented services 324
components 17, 21, 27
action triggering by 284
ActionLink 494
advanced form 134
anonymous Letter 237
Any 494
application-specific 216, 254
BannerAd 329, 339
Block 463, 495
Body 55, 167, 186, 220, 243, 344, 365, 495
body allowing 242
Border 217, 243, 258, 370
bound properties, reading and updating 222
buffering the output of 345
Button 495
calculations during render 234
Checkbox 103, 110–111, 118, 121, 495
communication between 271
Conditional 98, 186, 210, 220, 496
configuration 75, 85
conflicts with informal parameters 230
consistency between pages and 299
construction details 290
contained vs enclosed 243
controller 240
controlling behavior of 222
converting application-spe-cific to library compo-nents 264
corresponding to engine ser-vices 281
CreditCardField 341, 346, 348, 352
DatePicker 134, 167, 170, 208, 210–211, 221, 496
declared 259, 321
declared vs implicit 188
Delegator 165, 186, 221, 497
Digit
      See Digit component
Direct Area
      See DirectArea component
DirectLink 55, 58–59, 62, 83, 86, 88, 98, 119, 222, 229, 237, 246, 281, 284–285, 288–289, 325, 333, 370, 497
duplications 244, 424
enclosed vs contained 243
end tags 220
ExceptionDisplay 498
exceptions and 221
ExternalLink 290, 450, 499
FieldLabel 173, 175, 181, 184, 188, 201, 208, 499
FileUpload 165
filtering benefits 295
final initializations 303
finishLoad() method, overrid-ing 304
Foreach 79, 82–83, 85, 106, 115, 120, 124, 153–154, 156, 220, 222, 237, 239– 240, 500
Form 98–100, 102, 110, 149, 178, 181, 184, 188, 284– 285, 288, 299, 350, 361, 500
form element 355
FormError 264
Frame 501
GenericLink 501
Hidden 103, 134, 149, 153, 459, 502
IDs 188, 285–286, 289
Image 68, 73–74, 77–79, 221, 230, 233, 238–239, 266, 502
ImageSubmit 103, 110, 119, 316, 503
implementing in code 234
implicit components con-tained in templates 302
informal parameters 221
inputFirstName 194
inputLanguages 260
Insert 31, 187, 222, 292, 294, 314, 504
InsertText 504
instantiation of 219
interactive 246, 253
Java class of 217
JavaScript-enabled 340
JButton 21
Letter
      See Letter components
libraries
      See component libraries
LinkSubmit 505
ListEdit 103, 134, 151, 159, 464, 506
methods of
      See methods
object graphs 253
Option 103, 110, 113, 135, 506
output-only 246
overview 134
page loader instantiation of 303
PageLink 225, 281, 333, 507
pages compared to 222
Palette 118, 256, 339, 398, 463
ParameterManager 226–227
parameters
      See parameters
problems using sophisticated 259
problems with reusable 254
properties specific to pages 308
PropertySelection 103, 113, 118, 144, 210, 258–260, 318, 416, 507
purpose of 216
Radio 103, 110–111, 508
RadioGroup 103, 110–111, 508
RenderBlock 509
RenderBody 243, 434, 509
rendering 225
reusable 216, 246, 256, 265
reusable, packaging into libraries 261
rewinding 228
Rollover 435, 457, 509
sameness of 320
Scaffold
      See Scaffold component
Script 460, 510
Select 103, 110, 113, 135, 510
select 237
selectLoop 237
ServiceLink 511
Shell 97–98, 184–185, 243, 314, 511
simple 216
sources of 254
specifications
      See component specifica-tions
Spell
      See Spell component
start tags 220
Submit 103, 110, 119, 121, 512
template
      See template components
TextArea 102, 110, 210, 513
TextField 31, 98, 102, 107, 110, 121, 139, 149, 170, 184, 210, 222, 228, 513
Upload 103, 134, 160, 514
used in two different pages 308
ValidField 102, 293, 340, 367, 447, 514
      See ValidField components
WEB-INF folder and 217
concurrent users 15
configuration files 12
connected parameter property 224
CONSISTENCY 208
consistency goal 105
constraints 20
container 17
container-managed persistence 102, 404
context root 54
Contrib (Contributions) library 254, 256
Controller 29, 31, 33, 82, 117, 146
conversions 108
string 197
validation 171
value 173, 197
copyrights 243
CreditCardField script
adding client-side JavaScript 365
blocks 352
body 352
Body component 344
component defining 341
CreditCardField component 348, 355–356
event handler functions 353
executing script specifica-
tions 365
form submissions 366
obtaining script specifica-tions 365
script execution 365
specifications 345, 355
symbols 349
CSS (Cascading Style Sheets)
See Cascading Style Sheets (CSS)
cut-and-paste 53
 
D
 
data integrity 203
database connection leaks 15
database connection pools 15
database layer 19
database objects 136
database query 419
databases 5, 8, 15, 19–20, 30– 31, 44, 253
dates, formatting of 309
DateValidator 174
debugging 271, 276
declared component 55, 84
decoupling 49
Delegator 187
Demo applications 12
deployment descriptor 7, 14, 23, 28
descending property 423
design 16
desktop applications 4, 13, 16, 18, 93
developers
HTML 13–14
Java 13–14
Digit components
codeless 231, 234
digit parameter of 232
Guess and Win pages and 230
in parameter?s direction 232
input and output 230
specification 231
template 232–233
use of 233
direct services 250–251, 450
DirectLink components and 284–285, 288–289
engine services 284
Form components and 284– 285, 288
forms 288
listener methods, linking to 284
overview 284
request processing 287
stale session checking 285
URLs created by 290
DirectArea components
bodyless 248, 251
classes for 250
direct service and 250–251
DirectLink component simi-larity to 247
IDirect interface and 250
images and 252
implementation 248
Java class for 248
methods for 248, 250–251
parameters for 247–248
specifications for 248
static HTML, use of 252
support for informal parame-ters 247, 250
using 252
direction
auto 432, 434, 484
in 432, 454
direction attributes 434
directories
context root 371
specifications 264
disabled parameters 87
DOCTYPE 53, 475, 517
Document Object Model 462
document type definition 517
domain logic 20
domain object properties 104, 108, 355
domain objects 31, 44, 64, 96, 132
drop-down lists 113, 136, 144, 148, 318
DTD (Document Type Defini-tion) 53, 295
duplications
removal of 244
unnecessary object 302
dynamic name generation 344
 
E
 
EAR (Enterprise Application Archive) 384
Eclipse 35
Eclipse IDE 280
e-commerce applications 290
e-commerce sites, international-ization of 309
efficiency 52
EJBs (Enterprise JavaBeans) 384
elements
acceptance of unclosed 295
adding attributes to 240
application 256
area 246, 248, 250, 252
binding 233, 349
body 352
component 219, 259
component-specification 219–220
context-asset 219
discarding from templates 245
dynamic 252
dynamic tags, checking valid-ity of 295
img 230, 236–237, 240, 246
initialization 354
input-symbol 348
let 348–349, 351, 366
library 256
map 246, 252
matching start and end tags 295–296
parameter 219, 222, 224, 251
private-asset 267
property-specification 219, 306, 308
rendering vs previewing con-flict 245
reserved-parameter 219, 230
script 294, 353
select 257–258, 261
set 348–349, 366
span 244, 314
specification 267
static 252
table 258, 260, 265
unique 352–353
See also HTML elements
engine 406
engine locale 317
engine service 530
Engine services 246
engine services
application operations 281
application URLs 279, 284
components 323
creating new 323
delegation layer 277
direct service 284
external service 290
home service 281
implementing 332
library for 336
naming 335
page rendering 281
page service 283
services roster 281
servlets compared to 281
URL construction 372
engineered coincidence 98
Enterprise Application Archive (EAR) 384
enterprise application deploy-ment 477
enterprise applications 12, 476
Enterprise JavaBeans (EJBs) 19–20, 23, 384, 404, 407
entity beans 404, 407, 410
entity objects 44
Enum base class 144
EnumPropertySelectionModel 147
Enums 148, 208
errors
handling 187
identification of 280
messages 156, 192, 267, 315
properties 416, 418, 465
event handlers 203, 221
connecting to objects 353
onkeyup 343–344
onsubmit 344, 351, 355, 366
window.onload 344
event notification 21, 117
event registration, automatic 303
example applications
Hangman application
      See Hangman application
Java Pet Store
      See Java Pet Store applica-tion
Resume Builder
      See Resume Builder appli-cation
examples (servlet name) 255
examples.register.RegisterDele-gate 191
Exception page 109
exception report 23, 58
ExceptionAnalyzer 498
ExceptionDescription 498
exceptions 221, 299
RedirectException 370
ValidatorException 368
expired session 414
external services 290, 450–451
Externalizable 410
Extreme Programming 481
 
F
 
fabricated subclass 101
fail-over strategy 274
field decorations 175, 177, 186, 189, 199, 202, 208, 210
file accessibility for users 266
file extensions
.application 254
.jwc 217
file uploads 134, 165, 514
filtering
HTML entity, disabling use of 315
output 292
firewalls 274
form control components 95, 98, 103, 108, 110, 113
form control elements 94, 104
form controls 228
form element ids 105, 113
form submissions 12, 98, 104, 107–109, 112, 194
formal parameters 527
format 504
form-level validation errors 207
form-level validations 208, 263
form-related components, tracking 210
forms 22
complex 105, 120
components
      See components
delegate 362
direct service and 288
loops 159
rewinding 152, 288, 363
simple 105
submissions 271, 366, 371, 375
synchronization issues 153
frameworks 16
commons-lang 144
JavaBeans 17, 101
JUnit 482
Maverick 11
OGNL 31
OGNL library 144
Struts 11–12
Turbine 11
Velocity 12
WebObjects 18
WebWork 11
functions
anonymous JavaScript 354
onkeyup_cc_field() 354
 
G
 
Game 45, 47, 61–62, 64, 79
Global object 406
goals
consistency 22, 60, 89, 100, 105, 136, 292
efficiency 23, 52
feedback 23, 60
simplicity 60, 100, 105
graphs, complex object 302
Guess page 42, 65, 230, 233– 234, 237–238, 240–241
GUI 18, 21, 29
 
H
 
Hangman application
Body component 243
Border component 243
changes in original code 237, 241
components with bodies 242
Guess page 230, 233–234,
237–238, 240–241
Letter component 234
look and feel of 243
Lose page 234, 238
overview 39
RenderBody component 243
rendering vs previewing con-flicts 245
review of previous 216
revised compared to original 217
Shell component 243
source code online 217
Spell component 238
stylesheet 244
target word 238, 240
Win page 230, 234, 238
HashSet 117
helper beans 179, 187, 189, 191, 195, 212, 518
hidden fields 107, 131
hidden form fields 134, 149, 151
home interfaces 23, 406
Home page 50–51, 54, 281
home service 281
hot code replace 405
href 13
HTML
editors
      See WYSIWYG HTML edi-tors
safe 292
static mockups 342
HTML developers 13–14
HTML elements
a 13, 55, 87, 434
bean 178
body 167, 185, 415
form 13, 94, 98, 102–105
head 97–98, 184–185, 511
img 68, 73
input 94, 103, 107, 149, 160, 173, 177, 197–198, 201
link 184
option 103, 113, 135, 140, 506
script 167
select 94, 103, 113, 135, 140, 510
span 68, 80, 124, 176, 201
table 124, 187, 413
textarea 94, 102, 110
title 97–98
tr 124, 131, 425
See also elements
HTML mockups 68, 75, 83
HTML templates 51, 54, 234
HTTP 6–7, 11, 15, 18–19, 64
as stateful protocol, maintain-ing illusion of 306
bridging between servlets and 299
protocol 271
HTTP cookies 11, 15
HttpServlet 21, 25
HttpServletContext 25
HttpServletRequest 7, 9–12, 15– 16, 21, 25, 30, 35, 94, 104
HttpServletResponse 35
HttpSession 11, 15–16, 21, 25, 35, 60–61, 64, 126, 128, 149, 406, 409, 414, 498
HttpSession attribute 60
HttpSessions, expired 251
Hypertext Transport Protocol 6
 
I
 
IActionListener 59
IActivate 443, 445
IActive 411
IAsset 75, 503, 510
ICallback 442
IComponent 33, 35, 454
IDEs (integrated development environments) 13, 280
Eclipse 405
IDs, unique 155
IEngine 35
IErrorProperty 411, 416, 418
IExternalPage 411, 451, 499
ILibrarySpecification 523
image maps 246
images
assets 237
client-side JavaScript and 256
Letter component 237
localization of 270, 311, 316
manipulation 217
problems with icon 266
referencing packaged 266
serving from the JAR file 266
using assets to represent 316
IMarkupWriter 35
IMessageProperty 411, 416, 418
implicit component 55
informal parameters 78, 221, 520, 530
initializations, performing 299
input symbols 510
input validation 104
InsertTextMode 505
instance variables 9, 101
instrumentation 43
Instrumenting 50
integers, compared to enums 144
integrated development envi-ronments (IDEs) 280, 405
interactive pages 246
interfaces 17
event 303
HTMLWriter 297
HttpServletResponse 297
IActionListener 250
IBanner 327, 336
IBannerSource 327, 331, 336, 338
IBinding 223
IComponent 288, 292, 304
IDirect 250, 287
IEngineService 278–279, 281
IExternalPage 290
IForm 361
ILink 333
IMarkupWriter 201, 237, 292, 297
IPage 290, 299
IPageLoaderpageloader 302
IPropertySelectionModel 260, 318
IRender 164–165, 187, 292
IRequestCycle 282, 300, 317
IValidationDelegate 191, 199, 202, 367
IValidator 173, 198, 204
PageDetachListener 303, 305–306
PageRedirectException 283
PageRenderListener 297, 303
PageValidateListener 283, 303
internationalized 4, 15
Internet Explorer 6
invalid input, handling 170
IPage 33, 35, 61
IPropertySelectionModel 135, 140, 142, 147, 416
IRender 33, 497–498
IRequestCycle 35, 58, 88, 410, 442
Iterator 472, 500, 506
IUploadFile 160, 163, 165, 514
IValidator 515
 
J
 
J2EE 404
Jakarta 12
Jakarta commons-fileupload library 160
Jakarta commons-lang frame-work 144
Jakarta ORO 199
Jakarta Tomcat 476
JAR (Java Archive) files 27, 254, 266
Java 2 Enterprise Edition (J2EE) 246, 274, 404
Java class default 217
Java classpath 254, 256
Java Database Connectivity 20, 405
Java developers 13–14
Java Naming and Directory Interface 23, 406
Java Pet Store application
DirectArea component 247
DirectLink component 246
image map 246
listener methods 246, 248
pet inventory 253
PetCategory page 252
Pets page 252
Java primitive types 228, 232
Java Runtime Environment (JRE), localizing applica-tions with 309
Java Servlet API 7, 16, 25, 37
Java Standard Tag Library 33
Java types
array 228
Boolean 228
char 240
double 228
int 228, 232
java.lang.Object 248
Java Virtual Machine 405, 410, 429
java.io.PrintWriter 201
JavaBeans 12, 17, 33, 188, 222– 224
application servlets and 271
framework 101
instantiation 178
properties 47, 87, 101, 459, 478
JavaScript 20, 495, 505, 532
anonymous functions 354
Body component and 344
client-side 134, 165, 167, 172, 174, 186, 198, 203, 256, 339
components enabled by 340
customized on demand 340
DOM references 350
dynamic generation 340
event handlers 221, 344, 352
filtering 294
functions 351
malicious 294
JavaScript library 534
JavaServer Pages (JSPs) 7, 279
JBoss 7, 18, 385
JDBC 419–420
Jetty 25, 482
JRE (Java Runtime Environ-ment), localizing applica-tions with 309
JSP tags 78, 88, 280
JSPForm page 377
JSPs (JavaServer Pages) 7–15, 21, 30–31, 37, 43, 52, 63– 64, 77–78, 87–88, 95, 279
custom tags 372, 374–378
ID component determina-tion 376
integrating with Tapestry applications 369
linking back to applications 371
redirecting application requests to 369
response rendering with 369
JSTL 33
JUnit framework 482
jwcid attribute 55, 68, 84, 295
$content$ 245
$remove$ 245
Jython 525
 
K
 
key parameters 315, 317
KeyAllocator bean 405
keys, primary/unique 155
 
L
 
label decorations 175, 188, 202
language proficiency 263
languages
handling differences in 292
handling multiple, using JRE 310
locales compared to 309
translation of 309
layout controls 258
Letter components
accessing connected parame-ter properties 237
code 236
components used in 237
correct asset for 236
Guess page and 237
implementation 236
methods for 237
parameters 235–237
purpose of 234
renderComponent() method, use of 234
similarity to Digit component 235
simplicity of 238
simplification of template 238
specifications 235
template free 234
using 237
libraries
See component libraries
library specifications 525
lifecycles
page 179, 191–192
request 179, 191
light touch 91
links
bookmarkable 290
method invoking 253
List 126, 128, 472, 506
ListEditMap 464, 468, 470
listener methods 22, 33, 55, 58– 59, 62, 73, 86, 88, 96, 98– 100, 109, 119, 127, 195, 208, 210, 252, 419, 437
as class instance 248
BaseComponent and 220
calling back application-spe-cific code 253
defining for Java Pet Store 246
forms 317
IActionListener 149
invoking 151–152, 222, 250, 288
JSP and 369
linking to, with direct service 284
synchronizeItem() 156, 159
listener objects 250
listener parameters 58
listeners
adding and removing 299
non-null 251
property 59
lists 151, 153
literals
localized 321
simple 314
load balancing 274
locales
current, passing to model?s constructor 318
definition 309
engine, editing 317
languages compared to 309
matching page and engine 317
self-describing 320
used by assets 317
localization
defined 309
handling with JRE 310
independence of page 320
logic
application-specific 57
LoginException 449
look and feel of pages 42, 50, 65, 79
Lose page 62, 234, 238
 
M
 
Map 409, 458
Map components 188
markup languages, types of 291
markup writer, calls to 250
markup writers 292
MasterQueryParameters 429
Maverick 11
messages
assembling from pieces 315
localized 223, 226, 313
properties 416, 418, 465
specialized error 315
warning, localized 315
metadata 417, 529
methods
accessor 223, 225, 228, 237
actionTriggered() 250–251, 288
activate() 62, 88, 282, 288, 442, 445
activateExternalPage() 290– 291, 378, 451, 499
addEventHandler() 361, 366
addPageRenderListener() 299
attach() 301
attribute() 237
beginEmpty() 237
beginResponse() 297
checkExtension() 331
checkRequired() 198
cleanUp() 305
cleanupAfterRender() 226
commitPageChanges() 297
constructLink() 334
constructServiceParameter() 250
createNewItem() 139, 146, 159
detach() 305–306
doPost() 108
encodeURL() 334
end() 201
equals() 145
event 306, 335
extractCardNumber() 364
finishLoad() 226, 303, 308, 428, 441
fireObservedChange() 307– 308
forgetPage() 449
format() 315
GET 377
get 237
getAsset() 74, 77
getBeans() 195
getContentType() 296–297
getDisplayLanguage() 320
getExtension() 331
getForm() 361
getKeys() 159
getLabel() 142
getLink() 333
getListener() 251
getLocale() 147
getMessage() 313, 315
getName() 335
getObject() 223–224, 228
getOption() 142–143
getOptionCount() 142
getPage() 282, 300–301, 303, 317
getPriorityModel() 139
getRandomBanner() 331
getResponseWriter() 297
getServiceParameters() 88
getSession() 11
getStream() 165
getTargetPage 225
getTaskWarning() 316
getValue() 142, 158
handleStaleSessionExcep-tion() 414
initialize() 305–306, 332, 334
isInError() 201
isStateful() 248, 250–251
links that invoke 253
match() 199
pageBeginRender() 117, 126, 158, 194, 288, 297, 432, 446, 452, 456, 459, 467
pageDetached() 306
pageEndRender() 288, 297
pageValidate() 335, 444
POST 377
prepareForRender() 225
print() 292
record() 207
recordFieldInputValue() 367
removePageRenderListener() 299
render() 165, 187, 225, 292, 297–298, 497
renderBody() 56, 251
renderComponent() 34, 56, 225, 227, 230, 234, 237, 248, 250–251, 331, 335, 363, 365, 433
renderInformalParameters() 250
renderPage() 297
renderResponse() 283, 297
renderValidatorContribu-tion() 176, 204
resetParameters() 226
service 273
service() 9, 272, 277, 334
set 237
setAttribute() 276
setContentType() 297
setFormComponent() 207
setObject() 223–224, 228
setParameters() 226
setter 307–308
static 307
static utility 250
synchronizeItem() 159
toObject() 199
toString() 197
translateValue() 142
trigger() 248, 250–251, 288
updateCardNumberFromRe-quest() 366, 368
updateSet() 472
validate() 282, 284, 287–288
writeAttributes() 176, 202
writeLabelPrefix() 176, 201
writeLabelSuffix() 176, 201
writePrefix() 202
writeSuffix() 202
MIMEs (Multipurpose Internet Mail Extensions) 160, 296– 297
Model 29, 47, 49, 75, 79, 82, 117
Model-Driven Architecture 529
Model-View-Controller pattern 29, 39, 44, 47, 79, 91, 135, 146, 478
multipart/form-data 160–161
multiple selections 113, 115, 118, 135
multi-threading 9, 12, 16, 271
 
N
 
names
conflicts 344
reserved 230
namespace conflicts 279
naming conventions 17, 101
navigation menus 415
navigational controls 243
Netscape Navigator 6
news sites, internationalization of 309
NeXT 18
NoSuchPropertyException 59
null checking 194
null value translation 198
null values 208
NullPointerException 117
numbers, formatting of 309
NumberValidator 174
 
O
 
object relational database 18
objects
applications servlets 270
database 136
Date 198
engine services 270
engines 270, 272, 276–277
for request processing 270
Game 239
graph 32
HttpSession 275, 285
immutable 276
Integer 198
mutable 276–277
Order 136
Page Loader 270
Page Recorder 270
Page Source 270
page, pooling instances of 272
Pattern 199
pools 272, 300
renderable 187
request cycle 270
RequestContext 270, 273
serialization and deserializa-tion 145, 406
serializing for storage 302
setting properties for 297
unnecessary duplication of 302
Visit 239, 272, 277
OGNL expressions 31, 33, 37, 58–59, 74, 77, 84, 98, 423, 519, 529
beans.delegate 187–188, 191
beans.required 179
bindings based upon 226
complex parameter bindings 223
components.inputFirstName 188
creating symbols with 348
default values 260
digit properties and 232
evaluating 308, 349
getMessage() method as part of 313
locating in the body 193
page.visit.game.letters 239
parameters that are 313
placed in the element body 233
updating 223
values for, used to set and update properties 308
open source 12
operation signatures 14
Operations bean 405–407, 416, 449, 458, 464, 468
org.apache.tapestry.visit-class 90
output
compatability with XML style markup 296
filtered 293
streamlining markup 292
writing directly within Java code 292
 
P
 
page
class 50, 52–53, 57
instance 52
loaders 302
mockup 42, 44, 50
properties 60, 111
recorders 297, 301
rendering 56
services 283
sources 301, 317
templates 220, 270
page specifications 28, 49–51, 55, 76–77, 84, 527
caching 270, 299
new property declarations 308
non-localization of 321
parsing 270
PageCallback 442, 445, 453
page-oriented services 324
PageRedirectException 159, 445, 467
PageRenderListener 117, 126, 432, 446, 467
pages
active, inability to change locale of 317
as controllers 240
attachment to application engine 301
caching by request cycle object 300
cleaning prior to storage 305
cleanup 306
components compared to 222
consistency between compo-nents and 299
creating new instances 302
division between instances and persistent page state 302
Exception 109
final initializations 303
finishLoad() method,overrid-ing 304
Guess 42, 65, 230, 234, 237– 238, 240–241
Home 50–51, 54, 281
HTML rendered, compared to XML related 296
independence of localiza-tions 320
instances, construction of 299
instances, readying 300
issues in using stateful 300
locales
      See locales
localized strings and static portion of 311
localizing text and images 270, 292
Lose 62, 234, 238
non-validation of 295
obtaining fresh instances of 301
page loader and 303
page source 301
persistent page properties 302, 306
persistent state separate from instance of 301
pooling instances of 270
pools 299
previewing 230
properties files 313
recorders 297, 301–302, 307
recursive processing 302
references, problems with storing 306
rendering sequence 297
renderingpage 281, 291
resetting properties of, to pristine values 304
returning to pools 304
reusing 300
rewinding 299, 363
serializing and deserializing 302
servlet use, compared to use of 300
specifications
      See page specifications
specified properties, support-ing 308
StaleLink 109, 129
StaleSession 286, 414
storage of names 306
storage of persistent proper-ties 302
stylesheets 260–261
supporting objects associated with 302
using multiple templates for 320
validation with external ser-vice 291
variable target 371
Win 62, 230, 234, 238
WYSIWYGs and 230
PageValidateListener 444
Parameter 27
parameter direction 528
ParameterManager 226–227
parameters 87
AbstractComponent 225
accessing 223
accessing values bound to 225
alt 314
analyzing direction of 226
application-specific service 286
attributes, converting from informal 251
binding 58
binding objects 222
      See also bindings
binding property names and names of 223
boolean 355
cardNumber 356, 368
component 201
condition 99
connected parameter prop-erty and 225
converting to objects array 250
cycle 292
delegate 165, 178, 181, 184, 187, 266
digit 232, 235
direction of, choosing 229
direction values of 226, 483, 528
DirectLink 221
disabled 87, 235, 237, 356– 357, 436
displayName 173, 191, 193, 201, 209
element 124
field 173, 188
focus 436
forbidding informal 221
forbidding names 230
form 226
formal 191, 222–223, 230, 314
hidden 98
image 230, 436
in 226, 251
informal 191–192, 221, 230, 314
JavaBean objects compared to component 223
key 315
letter 235–237
listener 58, 98, 119, 152, 222, 229, 247–248, 251
model 135
multiple 115
naming conflicts 225
non-rendering components and 229
page 225, 290
ParameterManager 227
parameters 87, 247–248, 250, 290
prefixes used to identify 313
processing of 225
properties 228, 237
purpose of 222
query 228, 279, 282, 284, 286, 377–378
reading and converting 224
read-only 229
reserved names 230
reusable components and 216
rewinding 224
selected 110–112, 119, 127, 260
service 246, 285, 290, 377– 378
service query 284
setting properties 225
setting values 226
size 192
sort 260
source 151–153, 222
stateful 285, 414
stylesheet 184
supporting 308
tag 119, 127
title 314
unknown runtime types and 248
updating 223
userName 378
ValidationConstraint 208
validator 174, 178, 191, 193
value 110, 112, 139, 142, 149, 151–153, 191, 193, 197, 199, 222, 228
when majority are used 229
writer 292
parsing specifications 52
password field 98
patterns
Model-View-Controller 355
performance 52, 78
performance enhancement 406
performance profiling 410
Perl 6
persistent page properties 60, 101, 125, 149, 301–302, 306, 432, 484
Person 409–410
Person bean 407, 410
placeholders 315
plumbing 178
pooling instances of page objects 270, 272
pools
database connection 15, 272, 300
object 272
obtaining page instances from 317
page 299
pop-up calendars 165
pop-up windows 203, 205
prefixes
tapestry 374
prefixing 256, 279, 314
presentation layer 19–20, 275, 404, 410–411, 449
previewing pages 238, 240–241, 245, 314
primary key 407
primitive Java types 228, 232
priority levels, selecting 141
PriorityStrings.properties file 147
processing requests
See request processing
properties
abstract 356
address 195
assets 184
beans 179
cardNumber 356
clientScriptingEnabled 204
components 181
connected parameter 225, 237
contentRenderer 165
currentDate 315
danger of leaving in place 304
Date 174
date 167
declared, initial values of 308
digit 232
dueDate 315
endDate 205, 207
engine 305
errorMessage 156
expressions 31
firstError 187
firstName 194
form 356
game 239
hasErrors 186–187
inError 209–210
item 156, 159
JavaBean 12, 223
key 153, 158
languages 260
letter 240
listEditMap 156
listeners 59
locale 147, 317
name 33, 356
optimizing number of 226
page 225, 239
persistent page 270, 277, 292, 297, 301
priority 138–139
priorityModel 139, 146
reading and updating bound 222
reinitializing 305
rendering 224
requestCycle 305
required 174, 192, 198
setting for objects 297
setting to null 305
startDate 205, 207
state 192
synthetic 72
targetPage 225
toDoList 156, 158
tracking changes to persistent page 301–302
updating 224, 228
validity of 228
visit 239, 305
properties files 313
Protected 411, 445
prototyping 75
public static field 423
Publisher 464
Python 525
 
Q
 
query parameters 5, 7–9, 12, 14, 16, 22, 37, 63, 86, 94, 98, 100, 104–105, 110, 118, 160, 279, 282, 284, 286
 
R
 
race conditions 159
radio buttons 104
radio elements 111
recompile 280
recursive processing 302
redeploy 406
redeployment 407
RedirectFilter 475
refactoring tools 280
Register page
building 189
HTML markup and 293
implementation 195
specifications 195
RegisterDelegate 202
registration, automatic 299
remote interface 407, 425, 429
Remote Method Invocation 405
remote object access 407
RemoteException 406, 426, 429–430, 432
render events 288
request cycle rewinding 250
request cycles 6, 8, 16, 35, 270, 292, 297, 300, 304
request processing
attribute serializing and copy-ing 275
direct service 287
end of 304
external service 290
initial access of a page 317
order operations 287
persistent page properties and 306
request cycles 292, 297, 300, 304
server-side 339
Servlet API and 276
stateful 286
synchronization of server-side-state 276
RequestContext 498
reserved entities, escaping 296
Resin 25
resource bundles 310
ResourceBundle 148
resources, managing scarce 272
Resume Builder
form-level validation 263
look and feel of 261
Palette component 257
stylesheet 260–261
retry loops 407, 429, 432, 470
reuse 23
rewind phase 109, 126–127, 129
routers 274
 
S
 
Scaffold component
choice of images 231
codeless 231, 234
digit parameter of 232
in parameter?s direction 232
specification 231
template 233
use of 234
script specification elements 460
body 462, 533
foreach 533
if 534
if-not 534
include-script 534
initialization 462, 534
input-symbol 535
let 535
set 535
unique 536
script specifications 532
scripting languages 6
scripting, client-side 198, 203, 205, 339
scriptlets 77, 87–88
scripts
blocks 352
specifications 345, 365
security 203
checks 282, 284
filtering and 293–294
separation of concerns 29, 76
separation of layers 405
Serializable 410
serialVersionUID 410
server clusters
request processing with 274, 306
servers
JBoss application 385
open-source 385
server-side
redirects to the JSP 376
values, converting 364
server-side state 10–12, 18, 35, 60–61, 101, 109, 131, 270, 272, 302
server-side state management 18
service parameters 88
Servlet API 271–273, 275, 292
Servlet API and multipart/form-data 160
ServletContext 406
servlets 5, 7, 11–13, 15, 22, 27, 30, 37, 63, 86, 88–89
applications 340
classes 64
containers 7, 9, 11, 18–19, 25, 28, 474–475, 482
context 90
filter 26, 475
names 255
See also application servlets
session attributes 22, 409
session beans 404
BookQuery 405–406, 419, 423, 425, 429–430
KeyAllocator 405
Operations 405–407, 416, 449, 458, 464, 468
sessions 11
Set 117, 472
shopping carts 151
simple forms 105
simplicity goal 22, 105
single selections 115
singletons
data 328
SortColumn 423
sortColumn property 423
special component ids
$content$ 245
$remove$ 83
specification elements
application 517
bean 518
binding 84, 191, 519
component 70, 84, 520
component-specification 521
component-type 521
configure 520
context-asset 70, 75, 523
description 523
duplication removal 244, 262
extension 523
external-asset 524
inherited-binding 524
library 525
library-specification 525
listener-binding 525
page 526
page-specification 527
parameter 483, 527
parsing 52
private-asset 528
property 417, 529
property-specification 102, 417–418, 529
reserved-parameter 530
service 530
set-property 179, 193, 531
set-string-property 193
static-binding 191, 531
specified properties 100, 156
Spell component
basis for 239
binding letter property to let-ter parameter 240
bodyless 241
components for 239–240
Guess page and 240–241
implementation 239
properties of 239
purpose of 239
replacing with spaceholder 241
simplifying page template with a 239
target word and 240
updating the letter property 240
using 240
Spindle 35–36
stack trace 23
stale links 129
stale sessions 285, 414
StaleLink page 109
StaleLinkException 120, 129, 131, 151, 154
StaleSession pages 414
StaleSessionException 414
stateful flags 285
stateful session beans 419, 430
stateless applications 61
stateless coding 272
stateless mode 61
stateless protocol 6
stateless session beans 407
states
application-wide 277
internal 277
server-side 270, 274
stateValidator 192
static HTML 220, 252
static text 220, 296
storage
application-wide states 277
assets 267
cleaning pages prior to 305
component specifications 254
engine instances in HttpSes-sion 272
global application data 272
in package directorie 264
object states 302
page instances 317
page names 306
page specifications 254
persistent page properties 302
properties files 313
script specifications 365
serializing objects for 302
specifications 261
WEB-INF folders 254
strings
compiling 199
conversion of 174
editing properties of 171
empty 198
key parameters 315
literal 193
localization of, using JRE 311
localization of, using Tapes-try 311, 314
message, operating with miss-ing 315
static (literal) 191
StringValidator 174, 191–192
Struts 12, 37, 98
Action 12
stylesheets 184, 258
submit controls 118
subsystems 35
suffixing 279
super class implementation, invoking 304
Swing 18, 21, 29
symbols
baseName 350
creating 349
creditCardField 349
formatMessage 349
formValidateFunction 351, 361, 366
input 349, 365
Map 366
uniqueness, importance of 351
synchronization faults 151
synthetic properties 72, 82, 115, 135
system properties 25
 
T
 
Tacos
See Tapestry Component Archive
tag libraries 12
tag library descriptors 374
taglib declarations 377
tags
See HTML elements
Tapestry Component Archive
480
team development 4, 64
template components
body discard 220
instantiation of class instance 217
page template composition 220
specifications 217
      See also component specifi-cations
steps in creating 217
template parser 295
templates
caching 299
multiple 320
script specifications 340
templating 7, 12
test 91
test suite 49
testing 49
text
formatting 316
instructional, need for local-ization of 314
localization of 270, 311, 320
static 296
translation 309
text fields 104–105
thread of control 16
tier
application 44
title bars 243
ToDo application 159
Tomcat 18, 25, 39, 487
toolkit 16
Turbine 11
 
U
 
unit-test suite 481
unsafe characters, converting 237
unwanted dependencies 13, 98
updating applications 155
URLs (Uniform Resource Loca-tors) 5, 13–14, 16, 22, 27, 55, 63–64, 86, 88, 90, 98
application 279, 284
application servlet 290
determining with assets 317
representation, Tapestry applications 333
user identity 6, 96
UserListEditMap 471
utility functions
onkeyup_cc_field() 352
validate_cc_field() 352
 
V
 
validation 12
delegates 362, 364, 367
input subsystems 364
subsystems 367, 388
validation delegates 449
defining 193
field and error tracking with 173
helper beans and 179
label and field decoration and 202
listener methods and 207
ValidField components and 178
without ValidField 209
ValidationDelegate 177, 202
ValidationException 175
validations
client-side 170, 205
conversions 171
errorserrors 187
form-level 208
server-side 171, 202
ValidatorException 198
validators 283
creating 198
custom 199
defining 193
helper beans and 179
Register pages and 189
stateValidator 192
ValidField 203
ValidField components
client-side JavaScript pro-duced by 186
FieldLabel components mixed with 208
FieldLabel, using with 181
inputEnd 205
inputStart 205
integration of client-side vali-dation into applications 203
JavaBeans andvalidfield 178
Register page specifications and 194
TextField variation 170
validation delegates shared by 184
validation without 208
writeAttributes() and 202
writeSuffix() and 202
value conversions 173, 197
values
accessing bound 225
auto 228
bound to component parame-ters 311
custom 228
direction of movement 224
form 228
in 228
initial, when none are pro-vided 309
limitations 228
literal 226
literal static 223
OGNL expression default 260
ognl null 251
problems with mutable 307
properly quoting 237
reading and updating bound 223
reserved characters 292
service context 285
stateful flag 285
updating 226
variables
instance 271
Velocity 12
View 29–30, 75, 146
Virtual Library (VL)
BookLink component 422, 426, 450
BookMatches page 413, 418, 425, 430, 434
Border component 415, 438
Borrow component 426
BorrowedBooks page 430
Browser component 425, 430, 432
ColumnSorter component
423, 434
EditPublishers page 464
EditUsers page 470
GiveAwayBooks page 463
Home page 413
MyLibrary page 430, 444, 457
NewBook page 445
PersonLink component 422, 426, 453
ShowError component 416, 418
ShowMessage component 416, 418
ViewBook page 411, 422, 426, 449, 451, 453
ViewPerson page 422, 426, 449, 455
Virtual Library application
accessing 385
Add New Book page 396
administration
      See VL administration
Ant Build script 385
book borrowing 389
Borrowed Books page 395
configuration 385
database access 384
database sample 389
database updating 389
defined 384
detail pages 390
Edit Book page 395
Edit Profile page 396
Edit Publishers page 400
Edit Users page 399
Enterprise Application Archive EAR) 384
Enterprise JavaBeans (EJBs) 384
functionality, adminstrative 399
functionality, user 399
Give Away Books page 396
JBoss application server and 385
log in on the fly 392
logging in 388
Login page 388
      See also VL Login page
managing books 393
Matching Books page
      See VL Matching Books page
My Library page
      See VL My Library page
non-lendable books 393
Register page 389
registering 388
Search page
      See VL Search page
Transfer Books page 400
View Book page 390
View Person page 392, 411, 430
VirtualLibraryEngine 409–410, 414, 430
Visit object 58, 60, 406, 409
VL administration
administrative privileges 399
book ownership transfer 399
Edit Publishers page 400
Edit Users page 399
form wizard 400
Give Away books page 400
navigation menu 400
pages, protection of 399
passwords 399
publisher list, managing 399
system lock-out 399
testing administrative pages 399
Transfer Books page 400
users, deleting 399
VL Edit Book page
drop-down blanks 395
drop-down lists 395
Publisher field 395
VL Login page
email addresses, unknown 388
error messages 388
fields, invalid 388
login ID 388
passwords 388
Register now link 389
return users 389
validation subsystems 388
VL Matching Books page
book borrowing 386, 389
column sorting 387
disabled button 387
links 386
navigation options 386
new books icon 386
non-lendable books 386
page navigation controls 387
paging results 387
sort order controls 387
table 386
VL My Library page
Add New Book page 396
books, deleting 393
books, editing 393
Borrowed Books page 395
Delete Book icon 395
deleted books confirmation 395
Edit Book page 394
Edit Profile page 396
navigation controls 394
returning books 395
VL Search page
form 385
navigation menu 385
navigational border 385
page title 385
reminder 391
Search button 386
VL View Book page 390
VL View Person page 392
 
W
 
WAR 27, 52, 75, 90, 476
warning messages, localized 315
weak binding 13, 95
web applications 4
context 27, 523
credit card numbers 341
localization of 309
web deployment descriptor 37, 61, 63–64, 88–89, 474–475
web sites, internationalization of 309
WEB-INF 52
WEB-INF folder 217, 254, 266, 313, 365
WEB-INF/lib folder 254
WebLogic 7, 18, 25
WebLogic application servers 276
WebObjects 18
WebSphere 7, 18, 25
Win page 62, 230, 234, 238
window titles 315
WML (Wireless Markup Lan-guage) 291, 295, 494
WordSource 45, 47, 61, 64
WYSIWYG HTML editors 14, 42, 44, 68, 73, 78, 83, 314
editing, support of 221
previewing with 230, 233, 241, 259
WYSIWYG preview 68, 184, 415
 
X
 
XHTML 291, 295
XML (Extensible Markup Lan-guage) 7, 19, 23, 35, 37, 291, 295
files 374
script specifications 345
XML namespaces 256
XML-related markup lan-guages 291
 
Z
 
zip codes 193, 195, 198