13#include <AUI/Common/AString.h>
14#include <AUI/Common/AStringVector.h>
19#include <fmt/format.h>
24 template<
typename T,
typename EnableIf =
void>
27 static decltype(
auto) process(T2&& arg) {
28 return std::forward<T2>(arg);
33 struct fmt<T, std::enable_if_t<std::is_base_of_v<AString, T>>> {
35 static decltype(
auto) process(T2&& arg) {
36 return arg.toStdString();
47 template <
typename... Args>
48 inline AString format(std::string_view f, Args&&...
args) {
49 return fmt::format(fmt::runtime(f),
detail::fmt<std::decay_t<Args>>::process(std::forward<Args>(
args))...);
53template<
typename... Args>
54inline AString AString::format(Args&& ...
args)
const {
60 std::string_view string;
62 template<
typename... Args>
64 return aui::format(
string, std::forward<Args>(
args)...);
79 return {std::string_view(str, len)};
Represents a Unicode character string.
Definition: AString.h:37
std::string toStdString() const noexcept
Definition: AString.cpp:338
API_AUI_CORE const ACommandLineArgs & args() noexcept
Definition: OSAndroid.cpp:29