Exemple #1
0
 def get(self, method):
     if method == 'message':
         ret = messageLog.write({'msg':self.request.query})
 
         method = self.get_argument('method')
         params = self.get_argument('params')
 
         res = getattr(server, method)(params)
 
         self.write(str(res))
     if method == 'event':
         ret = com.write({'msg':self.request.query})
 
         method = self.get_argument('method')
         params = self.get_argument('params')
 
         res = getattr(server, method)(params)
 
         self.write(str(res))
     else:
         self.write('unknown method')
Exemple #2
0
 def get(self):
     ret = com.write({'msg':self.get_argument('msg')})
     self.write(ret)