Commit | Line | Data |
---|---|---|
9c55c241 PP |
1 | /* |
2 | * Copyright (C) 2017 - Philippe Proulx <pproulx@efficios.com> | |
3 | * | |
4 | * This program is free software; you can redistribute it and/or modify it | |
5 | * under the terms of the GNU General Public License, version 2 only, as | |
6 | * published by the Free Software Foundation. | |
7 | * | |
8 | * This program is distributed in the hope that it will be useful, but WITHOUT | |
9 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
10 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | |
11 | * more details. | |
12 | * | |
13 | * You should have received a copy of the GNU General Public License along with | |
14 | * this program; if not, write to the Free Software Foundation, Inc., 51 | |
15 | * Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. | |
16 | */ | |
17 | ||
18 | #ifndef _STRING_UTILS_H | |
19 | #define _STRING_UTILS_H | |
20 | ||
21 | #include <stdbool.h> | |
f181fa5a | 22 | #include <common/macros.h> |
9c55c241 | 23 | |
f181fa5a | 24 | LTTNG_HIDDEN |
9c55c241 | 25 | void strutils_normalize_star_glob_pattern(char *pattern); |
f181fa5a JG |
26 | |
27 | LTTNG_HIDDEN | |
9c55c241 | 28 | bool strutils_is_star_glob_pattern(const char *pattern); |
f181fa5a JG |
29 | |
30 | LTTNG_HIDDEN | |
9c55c241 | 31 | bool strutils_is_star_at_the_end_only_glob_pattern(const char *pattern); |
f181fa5a JG |
32 | |
33 | LTTNG_HIDDEN | |
9c55c241 | 34 | char *strutils_unescape_string(const char *input, char only_char); |
f181fa5a JG |
35 | |
36 | LTTNG_HIDDEN | |
9c55c241 | 37 | char **strutils_split(const char *input, char delim, bool escape_delim); |
f181fa5a JG |
38 | |
39 | LTTNG_HIDDEN | |
9c55c241 | 40 | void strutils_free_null_terminated_array_of_strings(char **array); |
f181fa5a JG |
41 | |
42 | LTTNG_HIDDEN | |
9c55c241 PP |
43 | size_t strutils_array_of_strings_len(char * const *array); |
44 | ||
45 | #endif /* _STRING_UTILS_H */ |