python - Can i inherit the twisted.web.http.Request.requestReceived? -


can inherit twisted.web.http.request.requestreceived ??

in comment, said "this method not intended users".

i has inherited rawdatareceived , this:

def rawdatareceived(self, data):     self.resettimeout()     if len(data) < self.length:         self.requests[-1].content.send(data)         self.length = self.length - len(data)     else:         self.requests[-1].content.send(data[:self.length])         self._finishrequestbody(data[self.length:]) 

the self.requests[-1].content.send(data) send data in http connection. in fact, use httplib here.

all goes well, doesn't work @ last step in allcontentreceived. , it's req.requestreceived(command, path, version).

so can inherit method requestreceived. or go wrong?

my code here. can download if want me.

http://pan.baidu.com/share/link?shareid=569597&uk=926264233


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -