SEARCH
0-9 A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Prev | Current Page 115 | Next

Alexander Kolesnikov

"Tapestry 5: Building Web Applications"


On the other hand, many Tapestry 5 developers prefer to define their components
completely in the Java code of the page class (as was demonstrated in the previous
chapter), and then only use t:id attributes to insert components into the template.
Choose which ever approach you prefer.
Let's have a look at this pair of components:


Label for the first text box
:


t:value="userName"/>

The second one, TextField, is already familiar to us only this time it has a
t:id="userName" attribute. The first component is new however. We can see
that it is of type Label and in its t:for attribute it references the t:id attribute of
TextField, so this is a label for precisely this text box.
Chapter 4
[ 91 ]
Notice that the Label component surrounds some not very meaningful, and
probably too lengthy text. I have intentionally used such a weird text for the label
so that you could appreciate the miracles that Tapestry does for us. The trick is that
when the application runs and the page is rendered, the text surrounded by Label
component is discarded (it might have been a part of the original mock up, and used
for preview purposes only).


Pages:
103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
hotel jelenia góra Russian bride Free English grammar and study guid powiekszenia wielkoformatowe counter strike 1.6