datapaths: Refactor stats replies
datapaths: Refactor stats replies

There are multiple improvements here:
* Always specify reply type instead of using type guessing
* Move stats handlers to methods instead of nested functions
  (Zen of Python: flat is better than nested; Also useful for subclassing)
* Log and send errors rather than raise exceptions

kulawczukmarcin/mypox,noxrepo/pox,chenyuntc/pox,MurphyMc/pox,kpengboy/pox-exercise,pthien92/sdn,adusia/pox,PrincetonUniversity/pox,MurphyMc/pox,andiwundsam/_of_normalize,denovogroup/pox,MurphyMc/pox,diogommartins/pox,pthien92/sdn,noxrepo/pox,jacobq/csci5221-viro-project,chenyuntc/pox,waltznetworks/pox,denovogroup/pox,xAKLx/pox,adusia/pox,PrincetonUniversity/pox,xAKLx/pox,jacobq/csci5221-viro-project,kulawczukmarcin/mypox,kulawczukmarcin/mypox,kpengboy/pox-exercise,noxrepo/pox,denovogroup/pox,waltznetworks/pox,carlye566/IoT-POX,diogommartins/pox,kpengboy/pox-exercise,chenyuntc/pox,pthien92/sdn,carlye566/IoT-POX,PrincetonUniversity/pox,xAKLx/pox,noxrepo/pox,diogommartins/pox,VamsikrishnaNallabothu/pox,MurphyMc/pox,chenyuntc/pox,andiwundsam/_of_normalize,xAKLx/pox,diogommartins/pox,waltznetworks/pox,kpengboy/pox-exercise,adusia/pox,PrincetonUniversity/pox,xAKLx/pox,carlye566/IoT-POX,chenyuntc/pox,kulawczukmarcin/mypox,pthien92/sdn,PrincetonUniversity/pox,adusia/pox,VamsikrishnaNallabothu/pox,MurphyMc/pox,VamsikrishnaNallabothu/pox,VamsikrishnaNallabothu/pox,adusia/pox,waltznetworks/pox,diogommartins/pox,kulawczukmarcin/mypox,pthien92/sdn,denovogroup/pox,jacobq/csci5221-viro-project,waltznetworks/pox,jacobq/csci5221-viro-project,denovogroup/pox,andiwundsam/_of_normalize,jacobq/csci5221-viro-project,andiwundsam/_of_normalize,carlye566/IoT-POX,kpengboy/pox-exercise,VamsikrishnaNallabothu/pox,carlye566/IoT-POX