HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
FS_StaleMantraFiles.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: FS_StaleMantraFiles.h (FS Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __FS_StaleMantraFiles__
12 #define __FS_StaleMantraFiles__
13 
14 #include "FS_API.h"
15 
16 class UT_StringArray;
17 
18 /// When piping IFDs to mantra, SOHO will spool geometry and possibly other
19 /// files to $HOUDINI_TEMP_DIR/ifds/storage. It saves the geometry files to
20 /// filenames of the form: PID_XXXXX.YY, where PID is the PID of the mantra
21 /// process.
22 ///
23 /// If mantra terminates before the geometry files have been read, they are
24 /// left dangling in the temporary drive, and may cause the disk to fill up.
25 ///
26 /// This class is a convenience class for dealing with these temporary files.
28 {
29 public:
30  /// Get a list of stale files, which have no process running.
31  /// The function will fill up the @c removed array with the full path of
32  /// all files that were removed. The @c failed_files list is a list of
33  /// files which we think are stale files, but we were unable to remove.
34  ///
35  /// The @c dry_run boolean lets you call the function without actually
36  /// making changes to the file system. In this case, all files will be
37  /// lised in the @c removed list.
38  ///
39  /// The file returns @c true if there were stale files detected.
40  static bool cleanup(UT_StringArray &removed,
41  UT_StringArray &failed_files,
42  UT_StringArray *ignored_files,
43  bool dry_run);
44 };
45 
46 #endif
47 
#define FS_API
Definition: FS_API.h:10