ReactOS  0.4.12-dev-14-gd0c8636
fileutils.h
Go to the documentation of this file.
1 /*
2  * PROJECT: ReactOS Applications
3  * LICENSE: LGPL - See COPYING in the top level directory
4  * FILE: base/applications/msconfig_new/fileutils.h
5  * PURPOSE: File Utility Functions
6  * COPYRIGHT: Copyright 2011-2012 Hermes BELUSCA - MAITO <hermes.belusca@sfr.fr>
7  */
8 
9 #ifndef __FILEUTILS_H__
10 #define __FILEUTILS_H__
11 
12 #pragma once
13 
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17 
18 //
19 // NOTE: A function called "FileExists" with the very same prototype
20 // already exists in the PSDK headers (in setupapi.h)
21 //
22 BOOL
23 MyFileExists(IN LPCWSTR lpszFilePath,
24  OUT PWIN32_FIND_DATAW pFindData OPTIONAL);
25 
27 typedef LRESULT
29  IN LPCWSTR FileNamesQuery,
30  IN LPCWSTR ExpandedFileNamesQuery,
31  IN PWIN32_FIND_DATAW pfind_data,
34 
35 #define QUERY_FILES_TABLE_ROUTINE(fnName) \
36  LRESULT (fnName)(IN LPCWSTR Path, \
37  IN LPCWSTR FileNamesQuery, \
38  IN LPCWSTR ExpandedFileNamesQuery, \
39  IN PWIN32_FIND_DATAW pfind_data, \
40  IN PVOID Context, \
41  IN PVOID EntryContext)
42 
43 typedef struct __tagQUERY_FILES_TABLE
44 {
47  // Other fields ?
49 
50 LRESULT
52  IN LPCWSTR FileNamesQuery,
53  IN PQUERY_FILES_TABLE QueryTable,
54  IN PVOID Context);
55 
57 
58 BOOL BackupIniFile(IN LPCWSTR lpszIniFile);
59 
60 #ifdef __cplusplus
61 } // extern "C"
62 #endif
63 
64 #endif // __FILEUTILS_H__
_In_ PCWSTR _Inout_ _At_ QueryTable _Pre_unknown_ PRTL_QUERY_REGISTRY_TABLE QueryTable
Definition: rtlfuncs.h:3988
#define IN
Definition: typedefs.h:38
#define LRESULT
Definition: msvc.h:49
const WCHAR * LPCWSTR
Definition: xmlstorage.h:185
PQUERY_FILES_TABLE_ROUTINE QueryRoutine
Definition: fileutils.h:45
_In_ PCWSTR _Inout_ _At_ QueryTable EntryContext
Definition: rtlfuncs.h:3988
struct __tagQUERY_FILES_TABLE * PQUERY_FILES_TABLE
BOOL MyFileExists(IN LPCWSTR lpszFilePath, OUT PWIN32_FIND_DATAW pFindData OPTIONAL)
Definition: fileutils.c:18
unsigned int BOOL
Definition: ntddk_ex.h:94
LRESULT FileQueryFiles(IN LPCWSTR Path, IN LPCWSTR FileNamesQuery, IN PQUERY_FILES_TABLE QueryTable, IN PVOID Context)
Definition: fileutils.c:46
struct __tagQUERY_FILES_TABLE QUERY_FILES_TABLE
BOOL BackupIniFile(IN LPCWSTR lpszIniFile)
Definition: fileutils.c:93
LRESULT(* PQUERY_FILES_TABLE_ROUTINE)(IN LPCWSTR Path, IN LPCWSTR FileNamesQuery, IN LPCWSTR ExpandedFileNamesQuery, IN PWIN32_FIND_DATAW pfind_data, IN PVOID Context, IN PVOID EntryContext)
Definition: fileutils.h:28
PRTL_UNICODE_STRING_BUFFER Path
#define OUT
Definition: typedefs.h:39
struct tagContext Context
Definition: acpixf.h:1027
LONG_PTR LRESULT
Definition: windef.h:209
PULONG MinorVersion OPTIONAL
Definition: CrossNt.h:68