add a countPacketsInQueue() method to server

This commit is contained in:
Bastian Schroll 2018-01-12 18:58:14 +01:00
parent 2e515ff15d
commit 03e2f6091e

View file

@ -141,6 +141,13 @@ class TCPServer(socketserver.ThreadingMixIn, socketserver.TCPServer):
return message
return None
@staticmethod
def countPacketsInQueue():
"""!Get packets waiting in queue
@return Packets in queue"""
return len(_clients)
@staticmethod
def flushData():
"""!To flush all existing data in queue"""