]>
Commit | Line | Data |
---|---|---|
f3c0d7a5 A |
1 | // © 2016 and later: Unicode, Inc. and others. |
2 | // License & terms of use: http://www.unicode.org/copyright.html | |
729e4ab9 A |
3 | |
4 | /* | |
5 | ************************************************************************ | |
51004dcb | 6 | * Copyright (c) 2007-2012, International Business Machines |
729e4ab9 A |
7 | * Corporation and others. All Rights Reserved. |
8 | ************************************************************************ | |
9 | */ | |
10 | ||
11 | /** C++ Utilities to aid in debugging **/ | |
12 | ||
13 | #ifndef _DBGUTIL_H | |
14 | #define _DBGUTIL_H | |
15 | ||
16 | #include "unicode/utypes.h" | |
17 | #include "udbgutil.h" | |
18 | #include "unicode/unistr.h" | |
19 | ||
20 | #if !UCONFIG_NO_FORMATTING | |
21 | ||
51004dcb | 22 | U_TOOLUTIL_API const icu::UnicodeString& U_EXPORT2 |
729e4ab9 A |
23 | udbg_enumString(UDebugEnumType type, int32_t field); |
24 | ||
25 | /** | |
26 | * @return enum offset, or UDBG_INVALID_ENUM on error | |
27 | */ | |
28 | U_CAPI int32_t U_EXPORT2 | |
4388f060 | 29 | udbg_enumByString(UDebugEnumType type, const icu::UnicodeString& string); |
729e4ab9 A |
30 | |
31 | /** | |
32 | * Convert a UnicodeString (with ascii digits) into a number. | |
33 | * @param s string | |
34 | * @return numerical value, or 0 on error | |
35 | */ | |
4388f060 | 36 | U_CAPI int32_t U_EXPORT2 udbg_stoi(const icu::UnicodeString &s); |
729e4ab9 | 37 | |
4388f060 | 38 | U_CAPI double U_EXPORT2 udbg_stod(const icu::UnicodeString &s); |
729e4ab9 | 39 | |
4388f060 A |
40 | U_CAPI icu::UnicodeString * U_EXPORT2 |
41 | udbg_escape(const icu::UnicodeString &s, icu::UnicodeString *dst); | |
729e4ab9 A |
42 | |
43 | #endif | |
44 | ||
45 | #endif |