Login  Register

Re: XForms W3C suite and XPath Functions in Orbeon

Posted by Erik Bruchez-3 on Jan 15, 2010; 6:12pm
URL: https://discuss.orbeon.com/XForms-W3C-suite-and-XPath-Functions-in-Orbeon-tp1012497p1015129.html

Hi Nick,

Excellent! I just merged the new functions into the master branch.

Changes to seconds-to-dateTime():

The change to the parameter seems fairly safe.

On the other hand, our implementation of the function returns an
xs:dateTime, so I don't think it is reasonable that the function can
also return an empty string if the parameter is NaN. I would rather
return an empty sequence. Basically what I don't like is that the
function can return different types depending on the parameter.
Hopefully changing to an empty sequence doesn't cause a problem with
the test suite? The alternative is to always return a string as per
XForms 1.1, but this is less in line with XPath 2.0.

Changes to seconds-from-dateTime():

I guess those changes are right as per the spec. But a double return
value doesn't make much sense with XPath 2.0! So I am torn on this
one.

WDYT?

-Erik

On Tue, Jan 12, 2010 at 1:20 PM, nvdbleek <[hidden email]> wrote:

>
> Hi Erik,  Alessandro, and others,
>
> As you probably already know, I'm working on a test harness for the XForms
> 1.1 test suite. I reworked almost everything compared to what I had at the
> last XForms WG FtF meeting. The tests now run directly from within the
> browser. But the main difference is that they are now written in a simple
> XML format. Currently I've written the tests for Chapter 2 and 7. You can
> find the source at http://github.com/nvdbleek/com.orbeon.testsuite.w3c if
> you want to check it out. Please read the Readme.txt to get you up to speed
> (in fact you have to execute only one ant target). Any comments are welcome.
>
> I added some missing XPath funtions to Orbeon see
> http://github.com/nvdbleek/orbeon-forms
>
> I also made changes to seconds-from-dateTime() and seconds-to-dateTime()
> which I want your opinion about before merging them to my master branch of
> Orbeon (they are currently on
> http://github.com/nvdbleek/orbeon-forms/commits/xpath_functions_fixes).
>
> The changes I made are:
> 1) seconds-from-dateTime(): changed the return type from integer to double
> (to pass test in testsuite)
> http://github.com/nvdbleek/orbeon-forms/commit/1af695f7ee7b933611bc7ed0aff6cf20e64542a5
>
> 2) seconds-to-dateTime(): changed argument type to NUMBER_TYPE ->
> seconds-to-dateTime((number('NaN')) now returns empty string as specified in
> the XForms spec
> http://github.com/nvdbleek/orbeon-forms/commit/9e35d27bc174bfb59993902b326b10d2dfbeee80
>
> Could you please give your opinion about these two fixes? I will then
> incorporate your remarks and merge them afterwards to my master.
>
> Thanks in Advance,
>
> Nick Van den Bleeken
> R&D Manager
>
> Phone: +32 3 821 01 70
> Office Fax: +32 3 821 01 71
> [hidden email]
> http://www.inventivedesigners.com
>
> --
> View this message in context: http://n4.nabble.com/XForms-W3C-suite-and-XPath-Functions-in-Orbeon-tp1012497p1012497.html
> Sent from the ObjectWeb OPS - Users mailing list archive at Nabble.com.
>
>
> --
> You receive this message as a subscriber of the [hidden email] mailing list.
> To unsubscribe: mailto:[hidden email]
> For general help: mailto:[hidden email]?subject=help
> OW2 mailing lists service home page: http://www.ow2.org/wws
>
>


--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws