dbertoni 00/05/08 10:30:05
Modified: c/src/TestXSLT process.cpp
Log:
Changes for ICU integration.
Revision Changes Path
1.17 +22 -2 xml-xalan/c/src/TestXSLT/process.cpp
Index: process.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/TestXSLT/process.cpp,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- process.cpp 2000/05/01 15:13:39 1.16
+++ process.cpp 2000/05/08 17:30:05 1.17
@@ -126,6 +126,14 @@
+#if defined(XALAN_USE_ICU)
+#include <ICUBridge/ICUBridge.hpp>
+#include <ICUBridge/FunctionICUFormatNumber.hpp>
+#include <ICUBridge/ICUXalanNumberFormatFactory.hpp>
+#endif
+
+
+
#if !defined (XALAN_NO_NAMESPACES)
using std::auto_ptr;
using std::cerr;
@@ -444,6 +452,18 @@
// Runtime.getRuntime().traceInstructions(false);
+#if defined(XALAN_USE_ICU)
+ // Create an installer to install the substitue format-number()
function.
+ FunctionICUFormatNumber::FunctionICUFormatNumberInstaller
theInstaller;
+
+ // Create a factory for creating XalanNumberFormat instances using
+ // the ICU as implementation...
+ ICUXalanNumberFormatFactory theXalanNumberFormatFactory;
+
+ // Install the ICU-based factory...
+
StylesheetExecutionContextDefault::installXalanNumberFormatFactory(&theXalanNumberFormatFactory);
+#endif
+
/**
* The default diagnostic writer...
*/
@@ -802,11 +822,11 @@
<< "\" Node value: \""
<< theInstance->getNodeValue()
<< "\""
- #if defined(XALAN_RTTI_AVAILABLE) && !defined(XALAN_NO_TYPEINFO)
+#if defined(XALAN_RTTI_AVAILABLE) && !defined(XALAN_NO_TYPEINFO)
<< " Type: \""
<< typeid(*theInstance).name()
<< "\""
- #endif
+#endif
<< endl
<< endl;
}