>  The peer system is great! After doing something like this:
>  
>    Criteria c = new Criteria();
>    c.add(InfoPeer.NAME, name);
>    Vector v = InfoPeer.doSelect(c);
>    context.put("infos", v);
>  
>  I get a Vector with Info objects; from Velocity, I can then do:
>  
>    #foreach ($info in $infos)
>     <tr>
>      <td>$info.getCode()</td>
>      <td>$info.getFullName()</td>
>    #end

BTW, why not:

<td>$info.Code</td>
<td>$info.FullName</td>

>  
>  Now, I was thinking whether it would be possible to access the
>  columns within an Info object by name, not by explicitly calling
>  a Java method. For example, I would like to rewrite the Velocity
>  code above as:
>  
>    #foreach ($info in $infos)
>     <tr>
>      <td>$info.getFieldByName("code")</td>
>      <td>$info.getFieldByName("fullName")</td>
>    #end
>  
>  Is this possible with the current peer model? Or maybe as a
>  Velocity "hack"? In any case, how? If not possible at present,
>  would you think it a worthwhile addition? If yes, I would be
>  more than happy to implement this, but I would need some gentle
>  guidance to get me started...

Can you tell why exactly you need this and how you want to use it in a way
you can't currently do?

fedor.





_______________________________________________________
Tired of slow Internet? Get @Home Broadband Internet
http://www.home.com/xinbox/signup.html



------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to