|
[XQuery Talk Mailing List Archive Home] [By Date] [By Thread] [By Subject] [By Author] [Recent Entries] [Reply To This Message] flowrrr - how to structure a function?Martin Probst martin at x-hive.comTue Oct 17 21:06:19 PDT 2006
Hi, > I wonder how other processors work. I read somewhere that you can > use Saxon as eXist's XQuery processor, which I intend to do for > validity and performance comparisons. > > Do other processors evaluate sequences in order? X-Hive will currently evaluate the function calls in order, but we actively warn our customers that this might not always be the case. There is little reason to change the order of evaluation in this example, but in other examples the implementation might decide to change that. I think having functions that have side effects is always a dangerous thing. Specifically when writing web applications this is a problem - people need all those "redirect" and "set cookie" things. My idea at solving that would be to rather return an XML document format that describes the whole HTTP response. E.g. have response:redirect($code, $uri) actually return a value, <?web-request redirect $code $uri ?>, and the wrapper around that should interpret the results. With XQJ and the servlet API, it might even be possible to write something cross-implementation. Regards, Martin -- Martin Probst X-Hive Corporation http://x-query.com/mailman/listinfo/talk
|
Purchase Stylus Studio Online Today!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|






