CARLA
Static Public Member Functions | List of all members
carla::StringUtil Class Reference

#include <StringUtil.h>

Static Public Member Functions

template<typename Range1T , typename Range2T >
static bool EndsWith (const Range1T &input, const Range2T &test)
 
static bool Match (const char *str, const char *wildcard_pattern)
 Match str with the Unix shell-style wildcard_pattern. More...
 
template<typename String1T , typename String2T >
static bool Match (const String1T &str, const String2T &wildcard_pattern)
 Match str with the Unix shell-style wildcard_pattern. More...
 
template<typename Container , typename Range1T , typename Range2T >
static void Split (Container &destination, const Range1T &str, const Range2T &separators)
 
template<typename Range1T , typename Range2T >
static bool StartsWith (const Range1T &input, const Range2T &test)
 
static const char * ToConstCharPtr (const char *str)
 
template<typename StringT >
static const char * ToConstCharPtr (const StringT &str)
 
template<typename WritableRangeT >
static void ToLower (WritableRangeT &str)
 
template<typename SequenceT >
static auto ToLowerCopy (const SequenceT &str)
 
template<typename WritableRangeT >
static void ToUpper (WritableRangeT &str)
 
template<typename SequenceT >
static auto ToUpperCopy (const SequenceT &str)
 
template<typename WritableRangeT >
static void Trim (WritableRangeT &str)
 
template<typename SequenceT >
static auto TrimCopy (const SequenceT &str)
 

Detailed Description

Definition at line 13 of file StringUtil.h.

Member Function Documentation

◆ EndsWith()

template<typename Range1T , typename Range2T >
static bool carla::StringUtil::EndsWith ( const Range1T &  input,
const Range2T &  test 
)
inlinestatic

Definition at line 31 of file StringUtil.h.

◆ Match() [1/2]

bool carla::StringUtil::Match ( const char *  str,
const char *  wildcard_pattern 
)
static

Match str with the Unix shell-style wildcard_pattern.

Definition at line 17 of file StringUtil.cpp.

Referenced by carla::client::ActorList::Filter(), carla::client::World::GetTrafficLight(), carla::client::World::GetTrafficLightFromOpenDRIVE(), carla::client::World::GetTrafficSign(), carla::FileSystem::ListFolder(), Match(), carla::client::ActorBlueprint::MatchTags(), and Split().

+ Here is the caller graph for this function:

◆ Match() [2/2]

template<typename String1T , typename String2T >
static bool carla::StringUtil::Match ( const String1T &  str,
const String2T &  wildcard_pattern 
)
inlinestatic

Match str with the Unix shell-style wildcard_pattern.

Definition at line 75 of file StringUtil.h.

References Match(), and ToConstCharPtr().

+ Here is the call graph for this function:

◆ Split()

template<typename Container , typename Range1T , typename Range2T >
static void carla::StringUtil::Split ( Container &  destination,
const Range1T &  str,
const Range2T &  separators 
)
inlinestatic

Definition at line 66 of file StringUtil.h.

References Match().

Referenced by carla::client::ActorAttributeValueAccess::As< sensor::data::Color >(), carla::client::ActorBlueprint::ActorBlueprint(), and carla::opendrive::parser::ParseGeoReference().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ StartsWith()

template<typename Range1T , typename Range2T >
static bool carla::StringUtil::StartsWith ( const Range1T &  input,
const Range2T &  test 
)
inlinestatic

Definition at line 26 of file StringUtil.h.

Referenced by carla::client::detail::ActorFactory::MakeActor().

+ Here is the caller graph for this function:

◆ ToConstCharPtr() [1/2]

static const char* carla::StringUtil::ToConstCharPtr ( const char *  str)
inlinestatic

Definition at line 16 of file StringUtil.h.

Referenced by Match().

+ Here is the caller graph for this function:

◆ ToConstCharPtr() [2/2]

template<typename StringT >
static const char* carla::StringUtil::ToConstCharPtr ( const StringT &  str)
inlinestatic

Definition at line 21 of file StringUtil.h.

◆ ToLower()

template<typename WritableRangeT >
static void carla::StringUtil::ToLower ( WritableRangeT &  str)
inlinestatic

Definition at line 36 of file StringUtil.h.

Referenced by carla::road::MapBuilder::CreateRoadMark(), carla::road::element::GetColor(), carla::road::element::GetType(), carla::client::ActorAttribute::Set(), and carla::opendrive::parser::StringToLaneType().

+ Here is the caller graph for this function:

◆ ToLowerCopy()

template<typename SequenceT >
static auto carla::StringUtil::ToLowerCopy ( const SequenceT &  str)
inlinestatic

Definition at line 41 of file StringUtil.h.

Referenced by carla::client::ActorAttributeValueAccess::As().

+ Here is the caller graph for this function:

◆ ToUpper()

template<typename WritableRangeT >
static void carla::StringUtil::ToUpper ( WritableRangeT &  str)
inlinestatic

Definition at line 46 of file StringUtil.h.

◆ ToUpperCopy()

template<typename SequenceT >
static auto carla::StringUtil::ToUpperCopy ( const SequenceT &  str)
inlinestatic

Definition at line 51 of file StringUtil.h.

◆ Trim()

template<typename WritableRangeT >
static void carla::StringUtil::Trim ( WritableRangeT &  str)
inlinestatic

Definition at line 56 of file StringUtil.h.

◆ TrimCopy()

template<typename SequenceT >
static auto carla::StringUtil::TrimCopy ( const SequenceT &  str)
inlinestatic

Definition at line 61 of file StringUtil.h.


The documentation for this class was generated from the following files: