This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
Re: krl servlets & concurrency
- From: Per Bothner <per at bothner dot com>
- To: 62945 <62945 at bol dot com dot br>
- Cc: kawa <kawa at sources dot redhat dot com>
- Date: Sun, 08 Aug 2004 11:25:07 -0700
- Subject: Re: krl servlets & concurrency
- References: <I253VL$8F7F656D8391F73E746F8ADB06172E8F@bol.com.br>
62945 wrote:
The technique you offer makes it quite difficult to mix
text/data and code in krl, since there can be no
top-level vars.
You can do this in BRL/KRL:
[(let ((local-x (some-expression)))]
<some-tag>[(use local-x)]</some-tag>[)]
Just remember than what's really going on in BRL/KRL is
that ]text[ is just funny syntax for "text".
Shouldn't (ou couldn't) KRL semantics follow JSP, since
it seems the most usual and practical ?
Well, you need at least two kinds of various: Variables
that are local to a request, and variables that persist between
requests. 'define' is the latter; you can use
it's not obvious whether "define" in BRL/KRL should be
also need to follow Scheme, where "define"
means global.
We could presumably extend BRL/KRL with a define-local form.
But for more complex HTML-generation tasks, expecially if you
need to read/use/generate XML/XHTML, I recommend using XQuery:
http://www.gnu.org/software/qexo/XQ-Gen-XML.html
--
--Per Bothner
per@bothner.com http://per.bothner.com/