on 5/21/01 3:44 PM, "Sky Torch" <[EMAIL PROTECTED]> wrote:

> Hello,
> 
> can someone clear some cloud for me here:
> 
> it seems to me that turbine and some template engine
> , like velocity, is a natural fit since it provides a
> navigation and impl framework that use a template env for
> presentation layer.

Right. JSP is integrated into Turbine in the same way that Velocity is.

> meanwhile, JSP is more than a template env, it's a
> flexible (someone may argue) framework where users
> can do many different things.

JSP is not really a framework. JSP alone is just a template tool. You can
add stuff around it which makes it a framework.

> therefore instead of this in velocity:
> layout -> screen classs -> context -> velocity.vm

No. Read this again...

<http://jakarta.apache.org/turbine/pullmodel.html>

> in jsp:
> JSP servcie -> jsp-temp.jsp -> its logic class
> 
> so,
> 
> 1. how does screen and layout fit into this picture ?

The layout is just a JSP template itself. The output of the execution of a
Screen is included into the layout.

> 2. let's assume you impl a screen class that populate
> a object in context so jsp can pick it up and display,
> does it make sense since the jsp can pick up from logic
> class directly ?

Yes. That is the Pull Model.

> 3. what does integratation of Turbine and JSP buy you ?

You get to use the Turbine concept of Modules.

Here is a real world example that should clarify things for you further:

If you are using JSP alone, the only way to include a common header/footer
in each and every page would be to either copy/paste the actual
header/footer across all pages or somehow "include" the header/footer which
would also require copy/pasting of code into each and every page. Stupid,
right? So, why not abstract that out into something that allows you to not
only easily modify where the header/footer shows up, but also allows you to
not have to do any copy/paste. This is the whole point of the Layout Module.

-jon


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to