Re: [xslt] Identical separators in format-number() and decimal-format



Tony Marston wrote:

Which interpretation is correct? Which interpretation is the most logical? Which interpretation is easiest to implement?

There are a number of ways in which we can try to address this matter:

 1. We can seek clarification in the JDK.

    The JDK 1.1 specification of DecimalFormat is rather vague, so we
    have to resort to a later version of JDK. However, the XSLT spec
    deliberately seems to discourage this (section 12.3)

      "The format pattern must not contain the currency sign (#x00A4);
       support for this feature was added after the initial release of
       JDK 1.1"

 2. We can seek clarification from an authorative source (the editors of
    the XSLT standard).

    I have previously attempted to seek clarify from the XSLT editors
    on other borderline cases, but without success, so I am not too
    optimistic about this option. See:

    http://lists.w3.org/Archives/Public/xsl-editors/2001JanMar/0075.html

 3. We can adopt the behavior of (the majority of) other XSLT processors
    out there.

    This is how we have resolved borderline cases concerning infinity
    and not-a-number. This, however, requires that somebody with access
    to other XSLT processors examine and report their behavior.

 4. We can reason about what kind of behavior we prefer.

    Although it is always good to apply a dose of reasoning to our
    decisions, we should be careful not to invent our own behavior
    when it comes to standards. For example, hardcoding the values of
    decimal-point and thousand-separator can be confusing for users
    who are not familiar with the values that we select.

I am unsure how we best approach this (although our approach ought to
include the spanking of the XSLT editors :)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]