Exemplo n.º 1
0
def callbackCommandSendAndRunClips(data):
    print 'SEND AND RUN COMMAND'
    _clipsLock.acquire()
    clips.SendCommand(data.data, True)
    clipsFunctions.PrintOutput()
    _clipsLock.release()
    clipsFunctions.Run('')
    clipsFunctions.PrintOutput()
Exemplo n.º 2
0
def str_query_KDB(req):
    print 'QUERY IN KDB ' + req.query
    _clipsLock.acquire()
    clips.SendCommand(req.query, True)
    clipsFunctions.PrintOutput()
    _clipsLock.release()
    clipsFunctions.Run('')
    result = str(clips.StdoutStream.Read())
    print 'RESULT OF QUERY= ' + result
    print ''
    return StrQueryKDBResponse(result)
Exemplo n.º 3
0
def str_query(req):
    print 'Query in KDB' + req.query
    _clipsLock.acquire()
    clips.SendCommand(req.query, True)
    clipsFunctions.PrintOutput()
    _clipsLock.release()
    clipsFunctions.Run('')
    result = str(clips.StdoutStream.Read())
    if result.count('ROS') == 2:
        print 'ROS response'
        r = result.split('ROS')
        print r
        result = r[1]

    else:
        result = 'None'
        
    print 'Result of Query= ' + result
    print ''
    return StrQueryKDBResponse(result)
Exemplo n.º 4
0
def callbackCommandSendCLIPS(data):
    print 'SEND COMMAND'
    _clipsLock.acquire()
    clips.SendCommand(data.data, True)
    clipsFunctions.PrintOutput()
    _clipsLock.release()
Exemplo n.º 5
0
def callbackCommandSendCommand(data):
    clips.SendCommand(data.command, True)
    clipsFunctions.PrintOutput()
Exemplo n.º 6
0
def setLogLevelTest():
        _clipsLock.acquire()
        clips.SendCommand('(bind ?*logLevel* ' + 'getloglevel' + ')')
        #clipsFunctions.PrintOutput()
        _clipsLock.release()
Exemplo n.º 7
0
 def sendCommand(self):
     _clipsLock.acquire()
     clips.SendCommand(self.cmdVar.get(), True)
     clipsFunctions.PrintOutput()
     _clipsLock.release()
Exemplo n.º 8
0
 def setLogLevel(self):
     _clipsLock.acquire()
     clips.SendCommand('(bind ?*logLevel* ' + self.logLevelVar.get() + ')')
     clipsFunctions.PrintOutput()
     _clipsLock.release()