/** @file\r
Provides string functions, linked list functions, math functions, synchronization\r
- functions, and CPU architecture-specific functions.\r
+ functions, file path functions, and CPU architecture-specific functions.\r
\r
-Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>\r
Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>\r
This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
#ifndef DISABLE_NEW_DEPRECATED_INTERFACES\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Copies one Null-terminated Unicode string to another Null-terminated Unicode\r
string and returns the new Unicode string.\r
\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Copies up to a specified length from one Null-terminated Unicode string to \r
another Null-terminated Unicode string and returns the new Unicode string.\r
#ifndef DISABLE_NEW_DEPRECATED_INTERFACES\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Concatenates one Null-terminated Unicode string to another Null-terminated\r
Unicode string, and returns the concatenated Unicode string.\r
\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Concatenates up to a specified length one Null-terminated Unicode to the end \r
of another Null-terminated Unicode string, and returns the concatenated \r
#ifndef DISABLE_NEW_DEPRECATED_INTERFACES\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Copies one Null-terminated ASCII string to another Null-terminated ASCII\r
string and returns the new ASCII string.\r
\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Copies up to a specified length one Null-terminated ASCII string to another \r
Null-terminated ASCII string and returns the new ASCII string.\r
#ifndef DISABLE_NEW_DEPRECATED_INTERFACES\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Concatenates one Null-terminated ASCII string to another Null-terminated\r
ASCII string, and returns the concatenated ASCII string.\r
\r
\r
/**\r
- [ATTENTION] This function will be deprecated for security reason.\r
+ [ATTENTION] This function is deprecated for security reason.\r
\r
Concatenates up to a specified length one Null-terminated ASCII string to \r
the end of another Null-terminated ASCII string, and returns the \r
IN UINT8 Value\r
);\r
\r
+//\r
+// File Path Manipulation Functions\r
+//\r
+\r
+/**\r
+ Removes the last directory or file entry in a path by changing the last\r
+ L'\' to a CHAR_NULL.\r
+\r
+ @param[in, out] Path The pointer to the path to modify.\r
+\r
+ @retval FALSE Nothing was found to remove.\r
+ @retval TRUE A directory or file was removed.\r
+**/\r
+BOOLEAN\r
+EFIAPI\r
+PathRemoveLastItem(\r
+ IN OUT CHAR16 *Path\r
+ );\r
+\r
+/**\r
+ Function to clean up paths.\r
+ - Single periods in the path are removed.\r
+ - Double periods in the path are removed along with a single parent directory.\r
+ - Forward slashes L'/' are converted to backward slashes L'\'.\r
+\r
+ This will be done inline and the existing buffer may be larger than required\r
+ upon completion.\r
+\r
+ @param[in] Path The pointer to the string containing the path.\r
+\r
+ @return Returns Path, otherwise returns NULL to indicate that an error has occured.\r
+**/\r
+CHAR16*\r
+EFIAPI\r
+PathCleanUpDirectories(\r
+ IN CHAR16 *Path\r
+ );\r
\r
//\r
// Linked List Functions and Macros\r