dbertoni    01/11/26 15:26:16

  Modified:    c/src/XSLT FunctionFormatNumber.cpp
  Log:
  Use QName for retrieving XalanDecimalFormat instances.
  
  Revision  Changes    Path
  1.16      +11 -4     xml-xalan/c/src/XSLT/FunctionFormatNumber.cpp
  
  Index: FunctionFormatNumber.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/XSLT/FunctionFormatNumber.cpp,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- FunctionFormatNumber.cpp  2001/09/20 18:05:14     1.15
  +++ FunctionFormatNumber.cpp  2001/11/26 23:26:16     1.16
  @@ -2,7 +2,7 @@
    * The Apache Software License, Version 1.1
    *
    *
  - * Copyright (c) 2000 The Apache Software Foundation.  All rights 
  + * Copyright (c) 2000-2001 The Apache Software Foundation.  All rights 
    * reserved.
    *
    * Redistribution and use in source and binary forms, with or without
  @@ -66,6 +66,7 @@
   
   
   #include <XPath/XObjectFactory.hpp>
  +#include <XPath/XalanQNameByValue.hpp>
   
   
   
  @@ -85,6 +86,10 @@
   
   
   
  +static const XalanQNameByValue       theEmptyQName;
  +
  +
  +
   XObjectPtr
   FunctionFormatNumber::execute(
                        XPathExecutionContext&  executionContext,
  @@ -102,7 +107,7 @@
   
        if (theDFS == 0)
        {
  -             theDFS = 
executionContext.getDecimalFormatSymbols(Constants::DEFAULT_DECIMAL_FORMAT);
  +             theDFS = 
executionContext.getDecimalFormatSymbols(theEmptyQName);
        }
   
        typedef XPathExecutionContext::GetAndReleaseCachedString        
GetAndReleaseCachedString;
  @@ -140,8 +145,10 @@
        const XalanDOMString&                           theDecimalFormatName = 
arg3->str();
        assert(length(theDecimalFormatName) != 0);
   
  +     const XalanQNameByValue                         
theQName(theDecimalFormatName, executionContext.getPrefixResolver());
  +
        const XalanDecimalFormatSymbols*        theDFS =
  -                     
executionContext.getDecimalFormatSymbols(theDecimalFormatName);
  +                     executionContext.getDecimalFormatSymbols(theQName);
   
        if (theDFS == 0)
        {
  @@ -150,7 +157,7 @@
                                context,
                                locator);
   
  -             theDFS = 
executionContext.getDecimalFormatSymbols(Constants::DEFAULT_DECIMAL_FORMAT);
  +             theDFS = 
executionContext.getDecimalFormatSymbols(theEmptyQName);
        
        }       
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to