(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.135 and 1.136.6.1

version 1.135, 2006/01/30 16:17:08 version 1.136.6.1, 2006/04/25 14:42:18
Line 51 
Line 51 
 #include <cstdio> #include <cstdio>
 #include "Constants.h" #include "Constants.h"
 #include "CIMClass.h" #include "CIMClass.h"
   #include "CIMError.h"
 #include "CIMClassRep.h" #include "CIMClassRep.h"
 #include "CIMInstance.h" #include "CIMInstance.h"
 #include "CIMInstanceRep.h" #include "CIMInstanceRep.h"
Line 658 
Line 659 
     0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,1,     0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,1,
 }; };
  
   // Perform the necessary URI encoding of characters in HTTP header values.
   // This is required by the HTTP/1.1 specification and the CIM/HTTP
   // Specification (section 3.3.2).
 static void _xmlWritter_encodeURIChar(String& outString, Sint8 char8) static void _xmlWritter_encodeURIChar(String& outString, Sint8 char8)
 { {
     Uint8 c = (Uint8)char8;     Uint8 c = (Uint8)char8;
Line 1023 
Line 1027 
  
 inline void _xmlWritter_appendValue(Buffer& out, const CIMDateTime& x) inline void _xmlWritter_appendValue(Buffer& out, const CIMDateTime& x)
 { {
     out << x.toString();  //ATTN: append() method?      // It is not necessary to use XmlWriter::appendSpecial(), because
       // CIMDateTime values do not contain special characters.
       out << x.toString();
 } }
  
 inline void _xmlWritter_appendValue(Buffer& out, const CIMObjectPath& x) inline void _xmlWritter_appendValue(Buffer& out, const CIMObjectPath& x)
Line 1921 
Line 1927 
  
                 static const char *clientTransferEncodingOff =                 static const char *clientTransferEncodingOff =
                         getenv("PEGASUS_HTTP_TRANSFER_ENCODING_REQUEST");                         getenv("PEGASUS_HTTP_TRANSFER_ENCODING_REQUEST");
       // MEB: CIMERROR: can only be disabled if debug is on.
   
                 if (!clientTransferEncodingOff || *clientTransferEncodingOff != '0')                 if (!clientTransferEncodingOff || *clientTransferEncodingOff != '0')
 #endif #endif
  
Line 2013 
Line 2021 
     }     }
     if (errorDetail != String::EMPTY)     if (errorDetail != String::EMPTY)
     {     {
         // ATTN-RK-P3-20020404: It is critical that this text not contain '\n'  
         // ATTN-RK-P3-20020404: Need to encode this value properly.  (See  
         // CIM/HTTP Specification section 3.3.2  
         out << STRLIT(PEGASUS_HTTPHEADERTAG_ERRORDETAIL ": ")         out << STRLIT(PEGASUS_HTTPHEADERTAG_ERRORDETAIL ": ")
             << encodeURICharacters(errorDetail) << STRLIT("\r\n");             << encodeURICharacters(errorDetail) << STRLIT("\r\n");
     }     }
Line 2307 
Line 2312 
  
     out << STRLIT("<ERROR");     out << STRLIT("<ERROR");
     out << STRLIT(" CODE=\"") << Uint32(cimException.getCode());     out << STRLIT(" CODE=\"") << Uint32(cimException.getCode());
   
     out.append('"');     out.append('"');
     String description = TraceableCIMException(cimException).getDescription();     String description = TraceableCIMException(cimException).getDescription();
     if (description != String::EMPTY)     if (description != String::EMPTY)
Line 2315 
Line 2321 
         appendSpecial(out, description);         appendSpecial(out, description);
         out.append('"');         out.append('"');
     }     }
     out << STRLIT("/>");      out << STRLIT(">");
   
       ((CIMException*)&cimException)->addError(CIMError().getInstance());
   
       for (Uint32 i = 0, n = cimException.getErrorCount(); i < n; i++)
       {
           appendInstanceElement(out, cimException.getError(i));
       }
   
       out << STRLIT("</ERROR>");
 } }
  
 //------------------------------------------------------------------------------ //------------------------------------------------------------------------------
Line 2421 
Line 2436 
  
 //------------------------------------------------------------------------------ //------------------------------------------------------------------------------
 // //
 // appendQualifierNameIParameter()  
 //  
 //------------------------------------------------------------------------------  
   
 void XmlWriter::appendQualifierNameIParameter(  
     Buffer& out,  
     const char* name,  
     const String& qualifierName)  
 {  
     // <!ELEMENT IPARAMVALUE (VALUE|VALUE.ARRAY|VALUE.REFERENCE  
     //     |INSTANCENAME|CLASSNAME|QUALIFIER.DECLARATION  
     //     |CLASS|INSTANCE|VALUE.NAMEDINSTANCE)?>  
     //  
     // ATTN: notice that there is really no way to pass a qualifier name  
     // as an IPARAMVALUE element according to the spec (look above). So we  
     // just pass it as a class name. An answer must be obtained later.  
   
     _appendIParamValueElementBegin(out, name);  
     appendClassNameElement(out, qualifierName);  
     _appendIParamValueElementEnd(out);  
 }  
   
 //------------------------------------------------------------------------------  
 //  
 // appendClassNameIParameter() // appendClassNameIParameter()
 // //
 //------------------------------------------------------------------------------ //------------------------------------------------------------------------------
Line 2996 
Line 2987 
 //------------------------------------------------------------------------------ //------------------------------------------------------------------------------
 // //
 // appendEMethodResponseHeader() // appendEMethodResponseHeader()
           // MEB: CIMERROR: can only be disabled if debug is on.
   
 // //
 //     Build HTTP response header for export operation. //     Build HTTP response header for export operation.
 // //


Legend:
Removed from v.1.135  
changed lines
  Added in v.1.136.6.1

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2