Deskflow
1.26.0.418
Keyboard and mouse sharing utility
Toggle main menu visibility
Loading...
Searching...
No Matches
String.h
Go to the documentation of this file.
1
/*
2
* Deskflow -- mouse and keyboard sharing utility
3
* SPDX-FileCopyrightText: (C) 2025 Deskflow Developers
4
* SPDX-FileCopyrightText: (C) 2012 - 2016 Synergy App Ltd
5
* SPDX-FileCopyrightText: (C) 2002 Chris Schoeneman
6
* SPDX-License-Identifier: GPL-2.0-only WITH LicenseRef-OpenSSL-Exception
7
*/
8
9
#pragma once
10
11
#include <cstdarg>
12
#include <string>
13
15
18
namespace
deskflow::string
{
19
21
30
std::string
format
(
const
char
*fmt, ...);
31
33
36
std::string
vformat
(
const
char
*fmt, va_list);
37
39
42
std::string
sprintf
(
const
char
*fmt, ...);
43
45
48
class
CaselessCmp
49
{
50
public
:
52
bool
operator()
(
const
std::string &a,
const
std::string &b)
const
;
53
55
static
bool
less
(
const
std::string_view &a,
const
std::string_view &b);
56
58
static
bool
equal
(
const
std::string &a,
const
std::string &b);
59
61
static
bool
cmpLess
(
const
std::string::value_type &a,
const
std::string::value_type &b);
62
};
63
64
}
// namespace deskflow::string
deskflow::string::CaselessCmp
Case-insensitive comparisons.
Definition
String.h:49
deskflow::string::CaselessCmp::less
static bool less(const std::string_view &a, const std::string_view &b)
Returns true iff a is lexicographically less than b.
Definition
String.cpp:151
deskflow::string::CaselessCmp::operator()
bool operator()(const std::string &a, const std::string &b) const
Same as less().
Definition
String.cpp:146
deskflow::string::CaselessCmp::cmpLess
static bool cmpLess(const std::string::value_type &a, const std::string::value_type &b)
Returns true iff a is lexicographically less than b.
Definition
String.cpp:161
deskflow::string::CaselessCmp::equal
static bool equal(const std::string &a, const std::string &b)
Returns true iff a is lexicographically equal to b.
Definition
String.cpp:156
deskflow::string
std::string utilities
Definition
String.cpp:17
deskflow::string::vformat
std::string vformat(const char *fmt, va_list args)
Format positional arguments.
Definition
String.cpp:28
deskflow::string::format
std::string format(const char *fmt,...)
Format positional arguments.
Definition
String.cpp:19
deskflow::string::sprintf
std::string sprintf(const char *fmt,...)
Print a string using sprintf-style formatting.
Definition
String.cpp:106
src
lib
base
String.h
Generated by
1.18.0