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

Diff for /pegasus/src/Pegasus/Handler/SystemLogListenerDestination/SystemLogListenerDestination.cpp between version 1.1 and 1.2

version 1.1, 2005/02/14 21:15:34 version 1.2, 2005/02/26 08:52:15
Line 73 
Line 73 
  
     String ident_name = "CIM Indication";     String ident_name = "CIM Indication";
     String indicationText;     String indicationText;
     String textFormat = String::EMPTY;  
     CIMValue textFormatValue;  
     CIMValue textFormatParamsValue;  
   
     Array<String> textFormatParams = NULL;  
  
     try     try
     {     {
         // get TextFormat from subscription          // gets formatted indication message
         Uint32 textFormatPos =          indicationText = IndicationFormatter::getFormattedIndText(
             subscription.findProperty(_PROPERTY_TEXTFORMAT);              subscription, indication, contentLanguages);
   
         // if the property TextFormat is not found,  
         // indication is constructed with default format  
         if (textFormatPos == PEG_NOT_FOUND)  
         {  
             indicationText = IndicationFormatter::formatDefaultIndicationText  
                              (indication);  
         }  
         else  
         {  
             textFormatValue = subscription.getProperty(textFormatPos).  
                 getValue();  
   
             // if the value of textFormat is NULL,  
             // indication is constructed with default format  
             if (textFormatValue.isNull())  
             {  
                 indicationText =  
                     IndicationFormatter::formatDefaultIndicationText(indication);  
             }  
             else  
             {  
                 // get TextFormatParameters from subscription  
                 Uint32 textFormatParamsPos = subscription.findProperty(  
                     _PROPERTY_TEXTFORMATPARAMETERS);  
   
                 if (textFormatParamsPos != PEG_NOT_FOUND)  
                 {  
                     textFormatParamsValue = subscription.getProperty(  
                         textFormatParamsPos).getValue();  
                 }  
   
                 // constructs indication with specified format  
                 if ((textFormatValue.getType() == CIMTYPE_STRING) &&  
                     !(textFormatValue.isArray()))  
                 {  
                     textFormatValue.get(textFormat);  
                     if (!textFormatParamsValue.isNull())  
                     {  
                         if ((textFormatParamsValue.getType() ==  
                              CIMTYPE_STRING) &&  
                             (textFormatParamsValue.isArray()))  
                         {  
                             textFormatParamsValue.get(textFormatParams);  
                         }  
                     }  
   
                     indicationText = IndicationFormatter::formatIndicationText  
                                      (textFormat,  
                                       textFormatParams,  
                                       indication,  
                                       contentLanguages);  
                 }  
                 else  
                 {  
                     indicationText =  
                         IndicationFormatter::formatDefaultIndicationText(  
                             indication);  
                 }  
             }  
         }  
  
         // default severity         // default severity
         Uint32 severity = Logger::INFORMATION;         Uint32 severity = Logger::INFORMATION;


Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2