W3C home > Mailing lists > Public > www-forms-editor@w3.org > October 2007

Re: 7.9.3 (PR#146)

From: John Boyer <xforms-issues@mn.aptest.com>
Date: Wed, 31 Oct 2007 15:31:19 -0500
Message-Id: <200710312031.l9VKVJ70001953@htmlwg.mn.aptest.com>
To: mike@saxonica.com
CC: w3c-xml-query-wg@w3.org, www-forms-editor@w3.org

Hi Michael,

The working group solved this issue indirectly.  We found it necessary to remove
the functions encode() and decode().  Although they seem like they could be
useful, the decode function can produce results that do not fit the XPath data
model's restriction to XML Char, which means that encode() would need to take
illegal string data in order to be fully functional.

Best regards,
John Boyer

>     K. The decode() function needs to define an additional error, for
>     the case where the data can be decoded as a UTF-8 character string
>     but that string contains a character not allowed in XML.
>     The name of the encode() function is much too generic, and should
>     be renamed to something that indicates its purpose more clearly. In
>     the description of the encode() function, "The data string is
>     serialized as UTF-8" is ambiguous - it might mean (a) the parameter
>     must be UTF-8, or (b) the function serializes the input string as
>     UTF-8.
>     Also, UTF-8 is hard-coded. There are other possibilities.
>     The phrase "string of data" is redundant; you can simply say
>     "string".
>     In XPath 2.0, you would probably want to have two functions - one
>     would return the base64 binary representation, the other would
>     return the hex binary representation. Conversion of the binary to a
>     string would be done by the string() function.
>     These two functions are candidates for incorporating into XPath 2.N
>     core. We would be interested in working with you on the design of
>     these two functions.
Received on Wednesday, 31 October 2007 20:34:14 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:25:12 UTC