I haven't found anything specific, but I would expect that the Node VM is so well-behaved that it will flush and close all open file handles when it shuts down. If you want to be 100% sure, though, you can add the lifecycle method "terminate" [1] in your main app class (alongside the "main" method) and in it call .close() on the file handle. The terminate() method is executed on application shutdown.
T. [1] http://demo.qooxdoo.org/2.1.x/apiviewer/#qx.application.IApplication~terminate!method_public On 06/16/2013 07:16 PM, ga.n wrote: > Hi, > > I am writing a desktop app with qooxdoo (this the first time I use > qooxdoo) as frontend that run on top of node-webkit. > > I created a custom logger that write some info into a file. > > The logger works as intended but now I have two way: > > 1. open the file each time I need to write a log entry and close it > after writing > > 2. open the file on logger::init() store a reference to the file > handler and simply write the log entry using the file handler > > > but if I go for the second way how can I close the file handler once > the application shutdown? > > hope the above is clear (english is not my mother tongue) and thanks in > advance > ------------------------------------------------------------------------------ This SF.net email is sponsored by Windows: Build for Windows Store. http://p.sf.net/sfu/windows-dev2dev _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
