On Sun, May 17, 2009 at 8:56 PM, Narayanaswamy, Mohan < [email protected]> wrote:
> I am learning lift(and so scala) for the past 7 days. > > Myself and one of my friend were discussing about lift for our new project. > When I was introducing the TODO project code and how to setup using mvn. > > He was able to understand quite easily and I really amazed about it as he > is newer to lift than me. > > He mentioned that lift may actually constructing the object and invoking > the method as similar to JSF. He went on saying that, convention makes > simpler in Lift, whereas JSF configuration made jsf complex. He even > compared how "Facelet and Lift template & snippet" were quite similar. > > How fare it is true that lift is constructing the object similar to JSF? Is > there any relation to JSF and LIFT? > Thanks for the question. Lift processes the XML of the template for each request. It does not do any pre-compilation or such. The work is done in LiftSession.processSurroundAndInclude. The nodes of the template are pattern matched against stuff that could be snippets and dispatches the snippets. This can be performant because (1) the JVM garbage collector is quite good and generating a lot of temporary objects is okay and (2) HotSpot does a great job of tuning the code. Back in the Java 1.1 days, these things were not true and it was important to pre-compile as much as possible. > Mohan > > *Code we used for our discussion* > > <lift:TD.add form="post"> > <table> > <tr> > <td>Description:</td> > <td><todo:desc>To Do</todo:desc></td> > 19 > </tr> > <tr> > <td> > Priority > </td> > <td> > <todo:priority> > <select><option>1</option></select> > </todo:priority> > </td> > </tr> > <tr> > <td> </td> > <td> > <todo:submit> > <button>New</button> > </todo:submit> > </td> > </tr> > </table> > </lift:TD.add> > > ============================================================================== > Please access the attached hyperlink for an important electronic > communications disclaimer: > http://www.credit-suisse.com/legal/en/disclaimer_email_ib.html > ============================================================================== > > > > > -- Lift, the simply functional web framework http://liftweb.net Beginning Scala http://www.apress.com/book/view/1430219890 Follow me: http://twitter.com/dpp Git some: http://github.com/dpp --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~----------~----~----~----~------~----~------~--~---
