absl::Substitute

Substitute overloads

Synopses

Declared in <absl/strings/substitute.h>

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(std::string_view format);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(char const* format);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6,
    /* implementation-defined */ const& a7);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6,
    /* implementation-defined */ const& a7);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6,
    /* implementation-defined */ const& a7,
    /* implementation-defined */ const& a8);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6,
    /* implementation-defined */ const& a7,
    /* implementation-defined */ const& a8);
» more...

Substitutes variables into format and returns the result.

[[nodiscard]]
std::string
Substitute(
    std::string_view format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6,
    /* implementation-defined */ const& a7,
    /* implementation-defined */ const& a8,
    /* implementation-defined */ const& a9);
» more...

Overload of Substitute() that fails to compile when the number of placeholders does not match the number of arguments.

std::string
Substitute(
    char const* format,
    /* implementation-defined */ const& a0,
    /* implementation-defined */ const& a1,
    /* implementation-defined */ const& a2,
    /* implementation-defined */ const& a3,
    /* implementation-defined */ const& a4,
    /* implementation-defined */ const& a5,
    /* implementation-defined */ const& a6,
    /* implementation-defined */ const& a7,
    /* implementation-defined */ const& a8,
    /* implementation-defined */ const& a9);
» more...

Return Value

The formatted string.

Parameters

NameDescription
formatThe format string with $0-$9 placeholders.
a0Substitution argument for $0.
a1Substitution argument for $1.
a2Substitution argument for $2.
a3Substitution argument for $3.
a4Substitution argument for $4.
a5Substitution argument for $5.
a6Substitution argument for $6.
a7Substitution argument for $7.
a8Substitution argument for $8.
a9Substitution argument for $9.