FACT++  1.0
int main ( void  )

Definition at line 107 of file test_serve.cxx.

References add_serv(), add_serv_bool(), add_serv_str(), DimServer::start(), and DimService::updateService().

108 {
109  int ival = 0;
110 // ErrorHandler errHandler;
111 // ExitHandler exHandler;
112 // DimServer::setDnsNode("axdes2.cern.ch");
113  string s1;
114  bool boolval;
115  ServWithHandler *testServ;
116 
117 /*
118  int i, arr[15000];
119  DimService *servp;
120  DimCommand *cmndp;
121  char str[132];
122 */
123  float farr[4];
124  DimService *farrp;
125 
126  s1 = "hello";
127  add_serv(ival);
128  DimService servint("TEST/INTVAL",ival);
129  add_serv_str(s1);
130  boolval = 0;
131  add_serv_bool(boolval);
132  CmndServ cmdsvr;
133 
134  testServ = new ServWithHandler("MY_NEW_TEST_SERVICE_WITH_HANDLER");
135 
136  farr[0] = 1.2;
137  farr[1] = 2.3;
138  farrp = new DimService("/PCITCO147/sensors/fan/input","F", farr, sizeof(farr));
139  DimServer::start("TEST");
140 
141 /*
142 // DimServer::autoStartOff();
143  DimServer::start("TEST");
144 
145  for(i = 0; i < 15000; i++)
146  {
147  arr[i] = i;
148  sprintf(str,"ServiceManyTest/%05d",i);
149  servp = new DimService(str,arr[i]);
150  servp->setQuality(1);
151  servp->updateService(arr[i]);
152 // DimServer::start("TEST");
153  sprintf(str,"CommandManyTest/%05d",i);
154  cmndp = new CmndServMany(str);
155 // DimServer::start("TEST");
156  }
157 */
158 
159  while(1)
160  {
161  sleep(5);
162  s1 = "hello1";
163  if(!boolval)
164  boolval = 1;
165  else
166  boolval = 0;
167  ival++;
168  servint.updateService();
169  }
170  return 0;
171 }
void add_serv_bool(const bool &boolval)
Definition: test_serve.cxx:86
void add_serv_str(const string &s1)
Definition: test_serve.cxx:79
void add_serv(const int &ival)
Definition: test_serve.cxx:72
static void start()
Definition: discpp.cxx:512

+ Here is the call graph for this function: