VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware/ShellPkg/Include/Library/PathLib.h@ 58466

Last change on this file since 58466 was 58466, checked in by vboxsync, 9 years ago

EFI/Firmware: Merged in the svn:eol-style, svn:mime-type and trailing whitespace cleanup that was done after the initial UDK2014.SP1 import: svn merge /vendor/edk2/UDK2014.SP1 /vendor/edk2/current .

  • Property svn:eol-style set to native
File size: 1.5 KB
Line 
1/** @file
2 Provides interface to path manipulation functions.
3
4 Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
5 This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php.
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12**/
13
14#ifndef _PATH_LIB_
15#define _PATH_LIB_
16
17#include <Base.h>
18#include <Library/BaseMemoryLib.h>
19
20/**
21 Removes the last directory or file entry in a path by changing the last
22 L'\' to a CHAR_NULL.
23
24 @param[in, out] Path The pointer to the path to modify.
25
26 @retval FALSE Nothing was found to remove.
27 @retval TRUE A directory or file was removed.
28**/
29BOOLEAN
30EFIAPI
31PathRemoveLastItem(
32 IN OUT CHAR16 *Path
33 );
34
35/**
36 Function to clean up paths.
37
38 - Single periods in the path are removed.
39 - Double periods in the path are removed along with a single parent directory.
40 - Forward slashes L'/' are converted to backward slashes L'\'.
41
42 This will be done inline and the existing buffer may be larger than required
43 upon completion.
44
45 @param[in] Path The pointer to the string containing the path.
46
47 @retval NULL An error occured.
48 @return Path in all other instances.
49**/
50CHAR16*
51EFIAPI
52PathCleanUpDirectories(
53 IN CHAR16 *Path
54 );
55
56#endif //_PATH_LIB_
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette