MCPcopy Create free account
hub / github.com/KangLin/RabbitRemoteControl / Init

Method Init

Service/Service.cpp:24–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

22}
23
24int CService::Init()
25{
26 int nRet = 0;
27 if(GetParameters())
28 {
29 nRet = LoadConfigure();
30 if(nRet) return nRet;
31 }
32
33 if(!GetParameters() || !GetParameters()->getEnable())
34 {
35 qInfo(Service) << "The service" << m_pPlugin->Name() << "is disable";
36 return -2;
37 } else
38 qInfo(Service) << "The service" << m_pPlugin->Name() << "is start";
39
40 nRet = OnInit();
41 if(0 == nRet)
42 QTimer::singleShot(0, this, SLOT(slotProcess()));
43 if(nRet > 0) return 0;
44 return nRet;
45}
46
47int CService::Clean()
48{

Callers 2

runMethod · 0.45
StartMethod · 0.45

Calls 2

getEnableMethod · 0.80
NameMethod · 0.45

Tested by

no test coverage detected