BloombergLP::bdlb::StringViewUtil::endsWith

endsWith overloads

Synopses

Declared in <bdlb_stringviewutil.h>

Return true if the specified string ends with the specified character, and false otherwise.

static
bool
endsWith(
    std::string_view const& string,
    char character);
» more...

Return true if the specified string ends with the specified characters, and false otherwise.

static
bool
endsWith(
    std::string_view const& string,
    std::string_view const& characters);
» more...

Return true if string ends with the C-string characters.

static
bool
endsWith(
    std::string_view const& string,
    char const* characters);
» more...

Return Value

  • true if string ends with character, and false otherwise
  • true if string ends with characters, and false otherwise

Parameters

NameDescription
stringstring view to test
charactertrailing character to match
characterssuffix to match