CrashServer: ship new library in installer
[TortoiseGit.git] / src / crashrpt / Utility.h
blobe27f72150a4efd82ae3bb956ded6652813d8d67a
1 ///////////////////////////////////////////////////////////////////////////////
2 //
3 // Module: Utility.h
4 //
5 // Desc: Misc static helper methods
6 //
7 // Copyright (c) 2003 Michael Carruth
8 //
9 ///////////////////////////////////////////////////////////////////////////////
11 #pragma once
13 #include "stdafx.h"
16 ////////////////////////////// Class Definitions /////////////////////////////
18 // ===========================================================================
19 // CUtility
20 //
21 // See the module comment at top of file.
23 namespace CUtility
26 BSTR AllocSysString(string s);
28 //-----------------------------------------------------------------------------
29 // getLastWriteFileTime
30 // Returns the time the file was last modified in a FILETIME structure.
32 // Parameters
33 // sFile Fully qualified file name
35 // Return Values
36 // FILETIME structure
38 // Remarks
40 FILETIME
41 getLastWriteFileTime(
42 string sFile
44 FILETIME
45 getLastWriteFileTime(
46 WCHAR * wszFile
48 //-----------------------------------------------------------------------------
49 // getAppName
50 // Returns the application module's file name
52 // Parameters
53 // none
55 // Return Values
56 // File name of the executable
58 // Remarks
59 // none
61 string
62 getAppName();
64 //-----------------------------------------------------------------------------
65 // getSaveFileName
66 // Presents the user with a save as dialog and returns the name selected.
68 // Parameters
69 // none
71 // Return Values
72 // Name of the file to save to, or "" if the user cancels.
74 // Remarks
75 // none
77 string
78 getSaveFileName();
80 //-----------------------------------------------------------------------------
81 // getTempFileName
82 // Returns a generated temporary file name
84 // Parameters
85 // none
87 // Return Values
88 // Temporary file name
90 // Remarks
92 string
93 getTempFileName();