[NEWINFLIB]
[reactos.git] / reactos / lib / newinflib / infros.h
1 /*
2 * PROJECT: .inf file parser
3 * LICENSE: GPL - See COPYING in the top level directory
4 * PROGRAMMER: Royce Mitchell III
5 * Eric Kohl
6 * Ge van Geldorp <gvg@reactos.org>
7 */
8
9 #pragma once
10
11 #ifdef __cplusplus
12 extern "C" {
13 #endif /* __cplusplus */
14
15 #include <infcommon.h>
16
17 extern VOID InfSetHeap(PVOID Heap);
18 extern NTSTATUS InfOpenBufferedFile(PHINF InfHandle,
19 PVOID Buffer,
20 ULONG BufferSize,
21 LANGID LanguageId,
22 PULONG ErrorLine);
23 extern NTSTATUS InfOpenFile(PHINF InfHandle,
24 PUNICODE_STRING FileName,
25 LANGID LanguageId,
26 PULONG ErrorLine);
27 extern NTSTATUS InfWriteFile(HINF InfHandle,
28 PUNICODE_STRING FileName,
29 PUNICODE_STRING HeaderComment);
30 extern VOID InfCloseFile(HINF InfHandle);
31 extern BOOLEAN InfFindFirstLine(HINF InfHandle,
32 PCWSTR Section,
33 PCWSTR Key,
34 PINFCONTEXT *Context);
35 extern BOOLEAN InfFindNextLine(PINFCONTEXT ContextIn,
36 PINFCONTEXT ContextOut);
37 extern BOOLEAN InfFindFirstMatchLine(PINFCONTEXT ContextIn,
38 PCWSTR Key,
39 PINFCONTEXT ContextOut);
40 extern BOOLEAN InfFindNextMatchLine(PINFCONTEXT ContextIn,
41 PCWSTR Key,
42 PINFCONTEXT ContextOut);
43 extern LONG InfGetLineCount(HINF InfHandle,
44 PCWSTR Section);
45 extern LONG InfGetFieldCount(PINFCONTEXT Context);
46 extern BOOLEAN InfGetBinaryField(PINFCONTEXT Context,
47 ULONG FieldIndex,
48 PUCHAR ReturnBuffer,
49 ULONG ReturnBufferSize,
50 PULONG RequiredSize);
51 extern BOOLEAN InfGetIntField(PINFCONTEXT Context,
52 ULONG FieldIndex,
53 INT *IntegerValue);
54 extern BOOLEAN InfGetMultiSzField(PINFCONTEXT Context,
55 ULONG FieldIndex,
56 PWSTR ReturnBuffer,
57 ULONG ReturnBufferSize,
58 PULONG RequiredSize);
59 extern BOOLEAN InfGetStringField(PINFCONTEXT Context,
60 ULONG FieldIndex,
61 PWSTR ReturnBuffer,
62 ULONG ReturnBufferSize,
63 PULONG RequiredSize);
64 extern BOOLEAN InfGetData(PINFCONTEXT Context,
65 PWCHAR *Key,
66 PWCHAR *Data);
67 extern BOOLEAN InfGetDataField(PINFCONTEXT Context,
68 ULONG FieldIndex,
69 PWCHAR *Data);
70 extern BOOLEAN InfFindOrAddSection(HINF InfHandle,
71 PCWSTR Section,
72 PINFCONTEXT *Context);
73 extern BOOLEAN InfAddLine(PINFCONTEXT Context, PCWSTR Key);
74 extern BOOLEAN InfAddField(PINFCONTEXT Context, PCWSTR Data);
75 extern VOID InfFreeContext(PINFCONTEXT Context);
76
77 #ifdef __cplusplus
78 }
79 #endif /* __cplusplus */
80
81 /* EOF */