{"id":1311,"date":"2015-01-20T12:33:00","date_gmt":"2015-01-20T12:33:00","guid":{"rendered":"https:\/\/ibex.tech\/visualcpp\/?p=1311"},"modified":"2022-02-17T06:24:03","modified_gmt":"2022-02-17T06:24:03","slug":"unlocking-files-used-by-your-application-so-they-can-be-moved-or-deleted","status":"publish","type":"post","link":"https:\/\/ibex.tech\/visualcpp\/file-input-output-serialization\/unlocking-files-used-by-your-application-so-they-can-be-moved-or-deleted","title":{"rendered":"Unlocking files used by your application so they can be moved or deleted"},"content":{"rendered":"<p>\nSometimes it is necessary to force the background garbage&nbsp;collector to finish up all its tasks so a file recently used can be moved or deleted:\n<\/p>\n<pre>\r\n<code>\r\n\t\/\/First force the garbage collector to finish up so the file is released from its last access\r\n\tGC::Collect();\r\n\tGC::WaitForPendingFinalizers();\r\n<\/code><\/pre>\n<p>\n&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Sometimes it is necessary to force the background garbage&nbsp;collector to finish up all its tasks so a file recently used can be moved or deleted: \/\/First force the garbage collector to finish up so the file is released from its last access GC::Collect(); GC::WaitForPendingFinalizers(); &nbsp;<\/p>\n","protected":false},"author":5,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[29],"tags":[],"class_list":["post-1311","post","type-post","status-publish","format-standard","hentry","category-file-input-output-serialization"],"_links":{"self":[{"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/posts\/1311","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/comments?post=1311"}],"version-history":[{"count":1,"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/posts\/1311\/revisions"}],"predecessor-version":[{"id":1312,"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/posts\/1311\/revisions\/1312"}],"wp:attachment":[{"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/media?parent=1311"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/categories?post=1311"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ibex.tech\/visualcpp\/wp-json\/wp\/v2\/tags?post=1311"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}