Closed NickNaso closed 7 years ago
For implementation see at these resources: https://github.com/nodejs/nan/tree/master/examples/async_pi_estimate https://nodejs.org/dist/latest-v7.x/docs/api/addons.html#addons_callbacks https://github.com/nodejs/node-addon-examples/blob/master/3_callbacks/nan/addon.cc https://github.com/fcanas/node-native-boilerplate/blob/master/functions.cc
Async method implemented with Nan support to be compatible with all Node.JS version after v0.12.
Create the execute method that has the responsability to parse and execute the ghostscript command in asynchrnous way.
function execute(GhostscriptCommend, callback) {}
It's necessary to implement the Javascript and C++ binding for the method.
Use Nan:ThrowError to dispatch errors.