//---------------------------------------------------------------------------- // // Copyright (C) Intel Corporation, 2007 - 2008. // // File: MPS_Utils.h // // Contents: Provides static functions for common use in the MPS // // Notes: //---------------------------------------------------------------------------- #ifndef MPS_UTILS_H #define MPS_UTILS_H #include #define MAX_ELEMENT_NAME_LENGTH 1024 /* * Converts the given string to its upper case counterpart string, and returns it. * str - a reference to the string to convert. */ ACE_TString toUpper(const ACE_TString &str); struct ACE_TString_compare { bool operator() (const ACE_TString §ionL, const ACE_TString §ionR) const { return (toUpper(sectionL).compare(toUpper(sectionR)) < 0); } }; struct ACE_TString_compare_no_toUpper { bool operator() (const ACE_TString §ionL, const ACE_TString §ionR) const { return (sectionL.compare(sectionR) < 0); } }; class LogMasks { public: LogMasks() : mask_(0) {} void setMask(unsigned long mask) { mask_ = mask; } unsigned long getMask() { return mask_; } private: unsigned long mask_; }; #endif /* MPS_UTILS_H */