Socket.io emit from a nodejs addon

I would like to do a socket.io emit from within a nodejs addon that interfaces with a required C++ DLL. Can this be done, or do I need to return the data from the DLL, and then perform the socket.io emit from the server side javascript?

I had hoped I could instaniate the socket.io object in the server side JavaScript and then pass the object in to the addon and execute the emit from the addon. Is this possible?