W3C home > Mailing lists > Public > public-forms@w3.org > August 2008

Re: Progress on Functions Module(s)

From: John Boyer <boyerj@ca.ibm.com>
Date: Tue, 12 Aug 2008 09:08:02 -0700
To: Erik Bruchez <ebruchez@orbeon.com>
Cc: "public-forms (new)" <public-forms@w3.org>
Message-ID: <OFEDAE5477.927AEBD0-ON882574A3.0057A4BA-882574A3.0058A0B5@ca.ibm.com>
Hi Erik,

I think it cannot be bundled with context() because context() is provided 
by the binding attributes module.
It is at least conceivable that people want to use these function modules 
without using binding attributes.

Perhaps one way to have current() appear in a more "Generic, 
Miscellaneous, Really Useful Functions" bucket is to rename the 
"Conditional functions" to "Utility functions" or some such.

I put current() in conditionals because it is always getting used to help 
implement conditional behavior in an XPath, e.g. you always need it so you 
can implement a predicate of some kind, e.g. to help make a selection 
across a table based on a key value someplace else other than in the 
table.  I also put it there because I can't imagine a more important 
bundle of functions for doing XForms.  You may not use count-non-empty() 
all that much, but choose(), current(), current() and yes even if() show 
up all the time in forms.

So, if we are to avoid creating a module just for current(), the 
conditionals seemed the best place based on what the function is used to 
do.

Cheers,
John M. Boyer, Ph.D.
Senior Technical Staff Member
Lotus Forms Architect and Researcher
Chair, W3C Forms Working Group
Workplace, Portal and Collaboration Software
IBM Victoria Software Lab
E-Mail: boyerj@ca.ibm.com 

Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer
Blog RSS feed: 
http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw





From:
Erik Bruchez <ebruchez@orbeon.com>
To:
"public-forms (new)" <public-forms@w3.org>
Date:
08/11/2008 05:50 PM
Subject:
Re: Progress on Functions Module(s)




John & all,

I think that the current() function needs to find a better home. It is 
really a core function for XForms, at the same level as the context() 
function.

Note that in XSLT 2.0, current() is under "16.6 Miscellaneous 
Additional Functions" ;-)

Can we put current() and context() together, since they both have to 
do with the XPath evaluation context?

-Erik

On Aug 11, 2008, at 5:05 PM, John Boyer wrote:

>
> With some exceptions, I've reorganized the functions module based on 
> the emails from Leigh and Erik:
>
> 
http://www.w3.org/MarkUp/Forms/specs/XForms1.2/modules/instance/xpathFunctions/index-all.html

>
> Assuming the division is satisfactory, I will proceed to make 
> separate specs.
>
> Here are the points of interest:
>
> 1) The is-card-number() function was placed under "Data Integrity" 
> as that seemed to be enough of a generic name to fit the function, 
> whereas the name "E-commerce functions" was so broad that I felt 
> like putting *all* our functions into that section.
>
> Another perhaps better place to put it is in the conditional 
> functions.  Is that a better place?  Any other ideas?
>
>
> 2) The math functions seemed a better place to put random() than 
> data integrity, even though random could be used with some of the 
> data integrity functions.
>
> How might we handle the ability to show some of these use cases via 
> examples?
>
>
> 3) The "Nodeset Functions" category seemed to be a catch-all for 
> functions we didn't know what else to do with.  However, both 
> current() and count-non-empty() can be used in "conditional" 
> scenarios, so I put them there.
>
> The count-non-empty() *could* also be used in math operations, but I 
> didn't want to end up with sum-non-empty, max-non-empty, min-non- 
> empty and avg-non-empty. This function is not really needed, except 
> possibly as authoring convenience or optimization, but it already 
> exists, so I just put it in a place where we didn't get roped into 
> adding half a dozen more functions.
>
>
> 4) Neither count-non-empty() nor boolean-from-string() had examples, 
> so I added them.  I notice that avg, min, and max also don't have 
> examples.  This appears to be left-over omissions from 1.0.
>
> Do we need them?
> Can someone send the invocations and expected results from the test 
> suite?
> Should I copy the examples to the 1.1 spec?
>
>
> 5) I added several more examples to seconds-from-dateTime() to 
> address recent misunderstandings expressed on the list.
>
> Does everyone agree with them?
> Can we add these to the test suite?
>
> Thanks,
> John M. Boyer, Ph.D.
> Senior Technical Staff Member
> Lotus Forms Architect and Researcher
> Chair, W3C Forms Working Group
> Workplace, Portal and Collaboration Software
> IBM Victoria Software Lab
> E-Mail: boyerj@ca.ibm.com
>
> Blog: http://www.ibm.com/developerworks/blogs/page/JohnBoyer
> Blog RSS feed: 
http://www.ibm.com/developerworks/blogs/rss/JohnBoyer?flavor=rssdw
>

--
Orbeon Forms - Web Forms for the Enterprise Done the Right Way
http://www.orbeon.com/
Received on Tuesday, 12 August 2008 16:08:44 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 1 October 2013 22:06:48 UTC