]> git.saurik.com Git - apple/icu.git/blame - icuSources/tools/toolutil/toolutil.h
ICU-3.13.tar.gz
[apple/icu.git] / icuSources / tools / toolutil / toolutil.h
CommitLineData
b75a7d8f
A
1/*
2*******************************************************************************
3*
4* Copyright (C) 1999-2000, International Business Machines
5* Corporation and others. All Rights Reserved.
6*
7*******************************************************************************
8* file name: toolutil.h
9* encoding: US-ASCII
10* tab size: 8 (not used)
11* indentation:4
12*
13* created on: 1999nov19
14* created by: Markus W. Scherer
15*
16* This file defines utility functions for ICU tools like genccode.
17*/
18
19#ifndef __TOOLUTIL_H__
20#define __TOOLUTIL_H__
21
22#include "unicode/utypes.h"
23
24
25
26/*
27 * For Windows, a path/filename may be the short (8.3) version
28 * of the "real", long one. In this case, the short one
29 * is abbreviated and contains a tilde etc.
30 * This function returns a pointer to the original pathname
31 * if it is the "real" one itself, and a pointer to a static
32 * buffer (not thread-safe) containing the long version
33 * if the pathname is indeed abbreviated.
34 *
35 * On platforms other than Windows, this function always returns
36 * the input pathname pointer.
37 *
38 * This function is especially useful in tools that are called
39 * by a batch file for loop, which yields short pathnames on Win9x.
40 */
41U_CAPI const char * U_EXPORT2
42getLongPathname(const char *pathname);
43
44/*
45 * Find the basename at the end of a pathname, i.e., the part
46 * after the last file separator, and return a pointer
47 * to this part of the pathname.
48 * If the pathname only contains a basename and no file separator,
49 * then the pathname pointer itself is returned.
50 */
51U_CAPI const char * U_EXPORT2
52findBasename(const char *filename);
53
54#endif