]> git.proxmox.com Git - mirror_edk2.git/blame - Tools/CodeTools/Source/Common/EfiUtilityMsgs.h
More renames for Tool Packages
[mirror_edk2.git] / Tools / CodeTools / Source / Common / EfiUtilityMsgs.h
CommitLineData
878ddf1f 1/*++\r
2\r
3Copyright (c) 2004, Intel Corporation \r
4All rights reserved. This program and the accompanying materials \r
5are licensed and made available under the terms and conditions of the BSD License \r
6which accompanies this distribution. The full text of the license may be found at \r
7http://opensource.org/licenses/bsd-license.php \r
8 \r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
11\r
12Module Name:\r
13\r
14 EfiUtilityMsgs.h\r
15\r
16Abstract:\r
17\r
18 Defines and prototypes for common EFI utility error and debug messages.\r
19 \r
20--*/\r
21\r
878ddf1f 22#ifndef _EFI_UTILITY_MSGS_H_\r
23#define _EFI_UTILITY_MSGS_H_\r
24\r
ce53a8c3 25#include <Common/UefiBaseTypes.h>\r
26\r
878ddf1f 27//\r
28// Status codes returned by EFI utility programs and functions\r
29//\r
30#define STATUS_SUCCESS 0\r
31#define STATUS_WARNING 1\r
32#define STATUS_ERROR 2\r
33#define VOID void \r
34\r
35typedef int STATUS;\r
36\r
37#ifdef __cplusplus\r
38extern "C" {\r
39#endif\r
40//\r
41// When we call Error() or Warning(), the module keeps track of the worst\r
42// case reported. GetUtilityStatus() will get the worst-case results, which\r
43// can be used as the return value from the app.\r
44//\r
45STATUS\r
46GetUtilityStatus (\r
47 void\r
48 );\r
49\r
50//\r
51// If someone prints an error message and didn't specify a source file name,\r
52// then we print the utility name instead. However they must tell us the\r
53// utility name early on via this function.\r
54//\r
55void\r
56SetUtilityName (\r
57 CHAR8 *ProgramName\r
58 )\r
59;\r
60\r
61void\r
62Error (\r
63 CHAR8 *FileName,\r
64 UINT32 LineNumber,\r
65 UINT32 ErrorCode,\r
66 CHAR8 *OffendingText,\r
67 CHAR8 *MsgFmt,\r
68 ...\r
69 )\r
70;\r
71\r
72void\r
73Warning (\r
74 CHAR8 *FileName,\r
75 UINT32 LineNumber,\r
76 UINT32 ErrorCode,\r
77 CHAR8 *OffendingText,\r
78 CHAR8 *MsgFmt,\r
79 ...\r
80 )\r
81;\r
82\r
83void\r
84DebugMsg (\r
85 CHAR8 *FileName,\r
86 UINT32 LineNumber,\r
87 UINT32 MsgLevel,\r
88 CHAR8 *OffendingText,\r
89 CHAR8 *MsgFmt,\r
90 ...\r
91 )\r
92;\r
93\r
94void\r
95SetDebugMsgMask (\r
96 UINT32 MsgMask\r
97 )\r
98;\r
99\r
100void\r
101ParserSetPosition (\r
102 CHAR8 *SourceFileName,\r
103 UINT32 LineNum\r
104 )\r
105;\r
106\r
107void\r
108ParserError (\r
109 UINT32 ErrorCode,\r
110 CHAR8 *OffendingText,\r
111 CHAR8 *MsgFmt,\r
112 ...\r
113 )\r
114;\r
115\r
116void\r
117ParserWarning (\r
118 UINT32 ErrorCode,\r
119 CHAR8 *OffendingText,\r
120 CHAR8 *MsgFmt,\r
121 ...\r
122 )\r
123;\r
124\r
125void\r
126SetPrintLimits (\r
127 UINT32 NumErrors,\r
128 UINT32 NumWarnings,\r
129 UINT32 NumWarningsPlusErrors\r
130 )\r
131;\r
132\r
133#ifdef __cplusplus\r
134}\r
135#endif\r
136\r
137#endif // #ifndef _EFI_UTILITY_MSGS_H_\r