John McNally wrote:
>
> It would seem that it might have been good to have DefaultPage write to
> data.getOut() in the event that the Layout was null.
Even if layout is null, can't I still add to the RunData document and use it
as normal?
In the case where a user doesn't want to use a layout (the just want the
webmacro page)
they would write the "guts" of the page in HTML/WM script (excluding the
<html><head><body>
tags, because the ECS document does that). Then they'd use a Screen that
extends
BaseWebMacroScreen. Set the context with anything they want, call the template,
then
add it to the rundata document body. They could simply override the getLayout in
their
screen for whatever layout they want - custom OR null.
In this case I don't see a need to use getOut() this was just an initial
thought.
>
> Since this is something more related to using a template system, maybe it
> could be setup in WebMacro.properties. Or maybe this is not reachable from
> a Screen. Anyway your BaseWebMacroScreen could look at a property to decide
> whether to return some content or write the response directly.
After looking at things again, I don't really think we need to return a response
directly.
We can still use the Turbine framework like I mentioned in the previous e-mail.
My understanding is that if layout == null then the DefaultPage will just
process the
Screen...which exactly what we want anyhow. Am I right on this?
>
> >The only thing I want to change is the
> > return type on handleTemplate() and clean up the BaseWebMacroScreen.
> >
> > Please give me your thoughts on this.
> >
>
> What return type are you considering?
I haven't put much thought into this yet, maybe I don't need to
change it, but I was looking for something more
efficient than a String. I notice you use the StringElement in a
couple place with FreeMarker. Would this be better that a String?
Thanks for your reply,
--
Dave
[EMAIL PROTECTED]
your flame > /dev/null
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]