(file) Return to XmlWriter.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/XmlWriter.cpp between version 1.147 and 1.149

version 1.147, 2007/01/11 16:21:54 version 1.149, 2007/03/05 20:02:06
Line 92 
Line 92 
 struct SpecialChar struct SpecialChar
 { {
     const char* str;     const char* str;
     size_t size;      Uint32 size;
 }; };
  
 // Defines encodings of special characters. Just use a 7-bit ASCII character // Defines encodings of special characters. Just use a 7-bit ASCII character
Line 420 
Line 420 
         _xmlWritter_appendSpecialChar(os, *str++);         _xmlWritter_appendSpecialChar(os, *str++);
 } }
  
   // On windows sprintf outputs 3 digit precision exponent prepending
   // zeros. Make it 2 digit precision if first digit is zero in the exponent.
   #ifdef PEGASUS_OS_TYPE_WINDOWS
   inline void _xmlWriter_normalizeRealValueString(char *str)
   {
       // skip initial sign value...
       if (*str == '-' || *str == '+')
       {
           ++str;
       }
       while (*str && *str != '+' && *str != '-')
       {
           ++str;
       }
       if (*str && * ++str == '0')
       {
           *str = *(str+1);
           *(str+1) = *(str+2);
           *(str+2) = 0;
       }
   }
   #endif
   
 void XmlWriter::append(Buffer& out, const Char16& x) void XmlWriter::append(Buffer& out, const Char16& x)
 { {
     _xmlWritter_appendChar(out, x);     _xmlWritter_appendChar(out, x);
Line 465 
Line 488 
     // given in the CIM/XML spec, and the precision required by the CIM 2.2 spec     // given in the CIM/XML spec, and the precision required by the CIM 2.2 spec
     // (4 byte IEEE floating point)     // (4 byte IEEE floating point)
     sprintf(buffer, "%.7e", x);     sprintf(buffer, "%.7e", x);
   #ifdef PEGASUS_OS_TYPE_WINDOWS
       _xmlWriter_normalizeRealValueString(buffer);
   #endif
     append(out, buffer);     append(out, buffer);
 } }
  
Line 475 
Line 501 
     // with the format given in the CIM/XML spec, and the precision required     // with the format given in the CIM/XML spec, and the precision required
     // by the CIM 2.2 spec (8 byte IEEE floating point)     // by the CIM 2.2 spec (8 byte IEEE floating point)
     sprintf(buffer, "%.16e", x);     sprintf(buffer, "%.16e", x);
   #ifdef PEGASUS_OS_TYPE_WINDOWS
       _xmlWriter_normalizeRealValueString(buffer);
   #endif
     append(out, buffer);     append(out, buffer);
 } }
  
Line 2714 
Line 2743 
         httpMethod,         httpMethod,
         httpAcceptLanguages,         httpAcceptLanguages,
         httpContentLanguages,         httpContentLanguages,
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;
Line 2787 
Line 2816 
         tmp,         tmp,
         httpMethod,         httpMethod,
         cimException.getContentLanguages(),         cimException.getContentLanguages(),
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;
Line 2831 
Line 2860 
         httpMethod,         httpMethod,
         httpAcceptLanguages,         httpAcceptLanguages,
         httpContentLanguages,         httpContentLanguages,
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;
Line 2919 
Line 2948 
     appendMethodResponseHeader(tmp,     appendMethodResponseHeader(tmp,
         httpMethod,         httpMethod,
         cimException.getContentLanguages(),         cimException.getContentLanguages(),
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;
Line 3212 
Line 3241 
         authenticationHeader,         authenticationHeader,
         httpAcceptLanguages,         httpAcceptLanguages,
         httpContentLanguages,         httpContentLanguages,
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;
Line 3245 
Line 3274 
     appendEMethodResponseHeader(tmp,     appendEMethodResponseHeader(tmp,
         httpMethod,         httpMethod,
         httpContentLanguages,         httpContentLanguages,
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;
Line 3278 
Line 3307 
         tmp,         tmp,
         httpMethod,         httpMethod,
         cimException.getContentLanguages(),         cimException.getContentLanguages(),
         (Uint32)out.size());          out.size());
     tmp << out;     tmp << out;
  
     return tmp;     return tmp;


Legend:
Removed from v.1.147  
changed lines
  Added in v.1.149

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2