Dear Wiki user, You have subscribed to a wiki page or wiki category on "Tapestry Wiki" for change notification.
The "Tapestry5HowtoSelectWithObjects" page has been changed by DavorHrg. http://wiki.apache.org/tapestry/Tapestry5HowtoSelectWithObjects?action=diff&rev1=12&rev2=13 -------------------------------------------------- - '''''Thiago H. de Paula Figueiredo: this approach is plain wrong. You have to retrieve a list of objects when you need just one of them (wrong) or put a list in a session (very wrong). In addition, the same class implementing two completely different interfaces is not a good idea. Just create one instance of OptionModelImpl for each of your options (objects) and pass them to a SelectModelImpl.''''' + '''Thiago H. de Paula Figueiredo:''' this approach is plain wrong. You have to retrieve a list of objects when you need just one of them (wrong) or put a list in a session (very wrong). In addition, the same class implementing two completely different interfaces is not a good idea. Just create one instance of OptionModelImpl for each of your options (objects) and pass them to a SelectModelImpl. + + '''Davor Hrg: ''' Thiago's comment should be considered, but the fact is that you should not use a select component in any situation where the number of elements is so big the performance or memory footprint becomes a problem (in that case the list is definitely too long for users to scroll through, and use [[http://tapestry.apache.org/tapestry5.1/tapestry-core/ref/org/apache/tapestry5/corelib/mixins/Autocomplete.html|AutoComplete]] instead). Also Thiago provides no example page of his so called simpler solution. Creating a <SELECT> is a bit complicated and there is only support for strings and enums currently. (T5.0.13) --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
