TraceLevels.cpp
Go to the documentation of this file.
1 // **********************************************************************
2 //
3 // Copyright (c) 2003-2017 ZeroC, Inc. All rights reserved.
4 //
5 // This copy of Ice is licensed to you under the terms described in the
6 // ICE_LICENSE file included in this distribution.
7 //
8 // **********************************************************************
9 
10 #include <IceStorm/TraceLevels.h>
11 
12 #include <Ice/Properties.h>
13 
14 using namespace std;
15 using namespace IceStorm;
16 
17 TraceLevels::TraceLevels(const string name, const Ice::PropertiesPtr& properties, const Ice::LoggerPtr& theLogger) :
18  topicMgr(0),
19  topicMgrCat("TopicManager"),
20  topic(0),
21  topicCat("Topic"),
22  subscriber(0),
23  subscriberCat("Subscriber"),
24  election(0),
25  electionCat("Election"),
26  replication(0),
27  replicationCat("Replication"),
28  logger(theLogger)
29 {
30  const string keyBase = name + ".Trace.";
31  const_cast<int&>(topicMgr) = properties->getPropertyAsInt(keyBase + topicMgrCat);
32  const_cast<int&>(topic) = properties->getPropertyAsInt(keyBase + topicCat);
33  const_cast<int&>(subscriber) = properties->getPropertyAsInt(keyBase + subscriberCat);
34  const_cast<int&>(election) = properties->getPropertyAsInt(keyBase + electionCat);
35 }
36 
38 {
39 }
IceStorm
Definition: DBTypes.ice:22
IceStorm::TraceLevels::topicCat
const char * topicCat
Definition: TraceLevels.h:32
IceStorm::TraceLevels::topic
const int topic
Definition: TraceLevels.h:31
IceStorm::TraceLevels::topicMgrCat
const char * topicMgrCat
Definition: TraceLevels.h:29
IceStorm::TraceLevels::~TraceLevels
virtual ~TraceLevels()
Definition: TraceLevels.cpp:37
IceStorm::TraceLevels::subscriber
const int subscriber
Definition: TraceLevels.h:34
IceInternal::Handle< ::Ice::Properties >
IceStorm::TraceLevels::electionCat
const char * electionCat
Definition: TraceLevels.h:38
TraceLevels.h
std
Definition: Application.h:66
IceStorm::TraceLevels::subscriberCat
const char * subscriberCat
Definition: TraceLevels.h:35
IceStorm::TraceLevels::election
const int election
Definition: TraceLevels.h:37
IceStorm::TraceLevels::topicMgr
const int topicMgr
Definition: TraceLevels.h:28