Not that easy, but you could do something like what parserOnHeadersComplete does in _http_common.js together with connectionListener in _http_server.js. If you're really into it.
On 24 August 2013 19:31, Chris Ackerman <[email protected]> wrote: > I have a net.Server listening and on 'data' emit, depending on the contents > of the buffer, I may want to emulate a 'request' event passing > IncomingMessage and ServerResponse instances. Looking at the node source lib > sub directory, it looks like there's no sanctioned way to create the > IncomingMessage from userland. If I could, then creating a ServerResponse > would be trivial since it can be constructed from the request. > > Is there some way to create an IncomingMessage instance from a Buffer that > I'm missing? > > -- > -- > Job Board: http://jobs.nodejs.org/ > Posting guidelines: > https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines > You received this message because you are subscribed to the Google > Groups "nodejs" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/nodejs?hl=en?hl=en > > --- > You received this message because you are subscribed to the Google Groups > "nodejs" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. -- DU -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
