CARLA
Loading...
Searching...
No Matches
LibCarla
source
carla
StringUtil.cpp
Go to the documentation of this file.
1
// Copyright (c) 2026 Computer Vision Center (CVC) at the Universitat Autonoma
2
// de Barcelona (UAB).
3
//
4
// This work is licensed under the terms of the MIT license.
5
// For a copy, see <https://opensource.org/licenses/MIT>.
6
7
#include "
carla/StringUtil.h
"
8
9
// @TODO: This is not great; we can implement this better.
10
11
#ifdef _WIN32
12
#include <shlwapi.h>
13
#pragma comment(lib, "Shlwapi.lib")
14
#else
15
#include <fnmatch.h>
16
#endif
// _WIN32
17
18
namespace
carla
{
19
20
bool
StringUtil::Match
(
const
char
*str,
const
char
*test) {
21
#ifdef _WIN32
22
return
PathMatchSpecA(str, test);
23
#else
24
return
0 == fnmatch(test, str, 0);
25
#endif
// _WIN32
26
}
27
28
}
// namespace carla
StringUtil.h
carla::StringUtil::Match
static bool Match(const char *str, const char *wildcard_pattern)
Match str with the Unix shell-style wildcard_pattern.
Definition
StringUtil.cpp:20
carla
This file contains definitions of common data structures used in traffic manager.
Definition
SignComponent.h:21
Generated by
1.9.8