⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 historyqueueproperty.cpp

📁 java开源的企业总线.xmlBlaster
💻 CPP
字号:
/*------------------------------------------------------------------------------Name:      HistoryQueueProperty.cppProject:   xmlBlaster.orgCopyright: xmlBlaster.org, see xmlBlaster-LICENSE file------------------------------------------------------------------------------*//** * Helper class holding history queue properties. * <p /> * See ConnectQos for XML sysntax. * @see org.xmlBlaster.client.qos.ConnectQos */#include <util/qos/storage/HistoryQueueProperty.h>#include <util/lexical_cast.h>#include <util/Constants.h>#include <util/Global.h>using namespace org::xmlBlaster::util;using namespace std;namespace org { namespace xmlBlaster { namespace util { namespace qos { namespace storage {HistoryQueueProperty::HistoryQueueProperty(Global& global, const string& nodeId)   : QueuePropertyBase(global, nodeId){   ME = "HistoryQueueProperty";   setRelating(Constants::RELATING_HISTORY);   QueuePropertyBase::initialize(Constants::RELATING_HISTORY);}HistoryQueueProperty::HistoryQueueProperty(const QueuePropertyBase& prop)   : QueuePropertyBase(prop){}HistoryQueueProperty& HistoryQueueProperty::operator =(const QueuePropertyBase& prop){   copy(prop);   return *this;}string HistoryQueueProperty::getSettings(){   string ret;   ret += "type=" + getType() + " onOverflow=" + getOnOverflow() + " onFailure=" + getOnFailure() + " maxEntries=" + lexical_cast<std::string>(getMaxEntries());   return ret;}bool HistoryQueueProperty::onOverflowDeadMessage(){   if (Constants::ONOVERFLOW_DEADMESSAGE == getOnOverflow())      return true;   return false;}}}}}} // namespace#ifdef _XMLBLASTER_CLASSTESTusing namespace std;using namespace org::xmlBlaster::util::qos::storage;int main(int args, char* argv[]){   try {      Global& glob = Global::getInstance();      glob.initialize(args, argv);      HistoryQueueProperty prop(glob, "");      cout << prop.toXml() << endl;   }   catch (...) {      cerr << "an exception occured in the main thread" << endl;   }}#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -