]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Universal/RegularExpressionDxe/RegularExpressionDxe.h
MdeModulePkg: Use new added Perf macros
[mirror_edk2.git] / MdeModulePkg / Universal / RegularExpressionDxe / RegularExpressionDxe.h
index 46734718c8e56ff8edd58daeeaa28defa80bda27..0defa56e810cf477760d89e0e1b4ec1d480fb72b 100644 (file)
@@ -1,9 +1,7 @@
-/**\r
-  @file\r
-\r
+/** @file\r
   EFI_REGULAR_EXPRESSION_PROTOCOL Header File.\r
 \r
-  Copyright (c) 2015, Hewlett Packard Enterprise Development, L.P.<BR>\r
+  (C) Copyright 2015 Hewlett Packard Enterprise Development LP<BR>\r
   \r
   This program and the accompanying materials are licensed and made available\r
   under the terms and conditions of the BSD License that accompanies this\r
 \r
   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT\r
   WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
+\r
 **/\r
 \r
+#ifndef __REGULAR_EXPRESSIONDXE_H__\r
+#define __REGULAR_EXPRESSIONDXE_H__\r
+\r
 #include "Oniguruma/oniguruma.h"\r
 \r
 #include <Uefi.h>\r
 #include <Library/DebugLib.h>\r
 #include <Library/BaseLib.h>\r
 \r
-#define ARRAY_SIZE(Array) (sizeof(Array) / sizeof(*Array))\r
-\r
 /**\r
   Checks if the input string matches to the regular expression pattern.\r
 \r
-  This          A pointer to the EFI_REGULAR_EXPRESSION_PROTOCOL instance.\r
-                Type EFI_REGULAR_EXPRESSION_PROTOCOL is defined in Section\r
-                XYZ.\r
-\r
-  String        A pointer to a NULL terminated string to match against the\r
-                regular expression string specified by Pattern.\r
-\r
-  Pattern       A pointer to a NULL terminated string that represents the\r
-                regular expression.\r
-\r
-  SyntaxType    A pointer to the EFI_REGEX_SYNTAX_TYPE that identifies the\r
-                regular expression syntax type to use. May be NULL in which\r
-                case the function will use its default regular expression\r
-                syntax type.\r
-\r
-  Result        On return, points to TRUE if String fully matches against\r
-                the regular expression Pattern using the regular expression\r
-                SyntaxType. Otherwise, points to FALSE.\r
-\r
-  Captures      A Pointer to an array of EFI_REGEX_CAPTURE objects to receive\r
-                the captured groups in the event of a match. The full\r
-                sub-string match is put in Captures[0], and the results of N\r
-                capturing groups are put in Captures[1:N]. If Captures is\r
-                NULL, then this function doesn't allocate the memory for the\r
-                array and does not build up the elements. It only returns the\r
-                number of matching patterns in CapturesCount. If Captures is\r
-                not NULL, this function returns a pointer to an array and\r
-                builds up the elements in the array. CapturesCount is also\r
-                updated to the number of matching patterns found. It is the\r
-                caller's responsibility to free the memory pool in Captures\r
-                and in each CapturePtr in the array elements.\r
-\r
-  CapturesCount On output, CapturesCount is the number of matching patterns\r
+  @param This          A pointer to the EFI_REGULAR_EXPRESSION_PROTOCOL instance.\r
+                       Type EFI_REGULAR_EXPRESSION_PROTOCOL is defined in Section\r
+                       XYZ.\r
+\r
+  @param String        A pointer to a NULL terminated string to match against the\r
+                       regular expression string specified by Pattern.\r
+\r
+  @param Pattern       A pointer to a NULL terminated string that represents the\r
+                       regular expression.\r
+\r
+  @param SyntaxType    A pointer to the EFI_REGEX_SYNTAX_TYPE that identifies the\r
+                       regular expression syntax type to use. May be NULL in which\r
+                       case the function will use its default regular expression\r
+                       syntax type.\r
+\r
+  @param Result        On return, points to TRUE if String fully matches against\r
+                       the regular expression Pattern using the regular expression\r
+                       SyntaxType. Otherwise, points to FALSE.\r
+\r
+  @param Captures      A Pointer to an array of EFI_REGEX_CAPTURE objects to receive\r
+                       the captured groups in the event of a match. The full\r
+                       sub-string match is put in Captures[0], and the results of N\r
+                       capturing groups are put in Captures[1:N]. If Captures is\r
+                       NULL, then this function doesn't allocate the memory for the\r
+                       array and does not build up the elements. It only returns the\r
+                       number of matching patterns in CapturesCount. If Captures is\r
+                       not NULL, this function returns a pointer to an array and\r
+                       builds up the elements in the array. CapturesCount is also\r
+                       updated to the number of matching patterns found. It is the\r
+                       caller's responsibility to free the memory pool in Captures\r
+                       and in each CapturePtr in the array elements.\r
+\r
+  @param CapturesCount On output, CapturesCount is the number of matching patterns\r
                 found in String. Zero means no matching patterns were found\r
                 in the string.\r
 \r
@@ -91,23 +91,23 @@ RegularExpressionMatch (
   Returns information about the regular expression syntax types supported\r
   by the implementation.\r
 \r
-  This                     A pointer to the EFI_REGULAR_EXPRESSION_PROTOCOL\r
-                           instance.\r
+  @param This                     A pointer to the EFI_REGULAR_EXPRESSION_PROTOCOL\r
+                                  instance.\r
 \r
-  RegExSyntaxTypeListSize  On input, the size in bytes of RegExSyntaxTypeList.\r
-                           On output with a return code of EFI_SUCCESS, the\r
-                           size in bytes of the data returned in\r
-                           RegExSyntaxTypeList. On output with a return code\r
-                           of EFI_BUFFER_TOO_SMALL, the size of\r
-                           RegExSyntaxTypeList required to obtain the list.\r
+  @param RegExSyntaxTypeListSize  On input, the size in bytes of RegExSyntaxTypeList.\r
+                                  On output with a return code of EFI_SUCCESS, the\r
+                                  size in bytes of the data returned in\r
+                                  RegExSyntaxTypeList. On output with a return code\r
+                                  of EFI_BUFFER_TOO_SMALL, the size of\r
+                                  RegExSyntaxTypeList required to obtain the list.\r
 \r
-  RegExSyntaxTypeList      A caller-allocated memory buffer filled by the\r
-                           driver with one EFI_REGEX_SYNTAX_TYPE element\r
-                           for each supported Regular expression syntax\r
-                           type. The list must not change across multiple\r
-                           calls to the same driver. The first syntax\r
-                           type in the list is the default type for the\r
-                           driver.\r
+  @param RegExSyntaxTypeList      A caller-allocated memory buffer filled by the\r
+                                  driver with one EFI_REGEX_SYNTAX_TYPE element\r
+                                  for each supported Regular expression syntax\r
+                                  type. The list must not change across multiple\r
+                                  calls to the same driver. The first syntax\r
+                                  type in the list is the default type for the\r
+                                  driver.\r
 \r
   @retval EFI_SUCCESS            The regular expression syntax types list\r
                                  was returned successfully.\r
@@ -127,4 +127,4 @@ RegularExpressionGetInfo (
   OUT    EFI_REGEX_SYNTAX_TYPE           *RegExSyntaxTypeList\r
   );\r
 \r
-\r
+#endif\r