Bitcoin Core 31.0.0
P2P Digital Currency
Loading...
Searching...
No Matches
string.cpp File Reference
#include <blockfilter.h>
#include <clientversion.h>
#include <common/args.h>
#include <common/messages.h>
#include <common/settings.h>
#include <common/system.h>
#include <common/url.h>
#include <netbase.h>
#include <outputtype.h>
#include <rpc/client.h>
#include <rpc/request.h>
#include <rpc/server.h>
#include <rpc/util.h>
#include <script/descriptor.h>
#include <script/script.h>
#include <serialize.h>
#include <streams.h>
#include <test/fuzz/FuzzedDataProvider.h>
#include <test/fuzz/fuzz.h>
#include <test/fuzz/util.h>
#include <util/fees.h>
#include <util/strencodings.h>
#include <util/string.h>
#include <util/translation.h>
#include <cassert>
#include <cstdint>
#include <cstdlib>
#include <ios>
#include <stdexcept>
#include <string>
#include <vector>
Include dependency graph for string.cpp:

Go to the source code of this file.

Functions

 FUZZ_TARGET (string)
bilingual_str AmountErrMsg (const std::string &optname, const std::string &strValue)
bilingual_str AmountHighWarn (const std::string &optname)
bool FeeModeFromString (std::string_view mode_string, FeeEstimateMode &fee_estimate_mode)
bilingual_str ResolveErrMsg (const std::string &optname, const std::string &strBind)
bool ContainsNoNUL (std::string_view str) noexcept
 Check if a string does not contain any embedded NUL (\0) characters.
template<typename C, typename S, typename UnaryOp>
auto Join (const C &container, const S &separator, UnaryOp unary_op)
 Join all container items.
std::string RemovePrefix (std::string_view str, std::string_view prefix)
std::vector< std::string > SplitString (std::string_view str, char sep)
std::string TrimString (std::string_view str, std::string_view pattern=" \f\n\r\t\v")

Function Documentation

◆ AmountErrMsg()

bilingual_str common::AmountErrMsg ( const std::string & optname,
const std::string & strValue )

Definition at line 166 of file messages.cpp.

Here is the caller graph for this function:

◆ AmountHighWarn()

bilingual_str common::AmountHighWarn ( const std::string & optname)

Definition at line 161 of file messages.cpp.

Here is the caller graph for this function:

◆ ContainsNoNUL()

bool util::ContainsNoNUL ( std::string_view str)
inlinenodiscardnoexcept

Check if a string does not contain any embedded NUL (\0) characters.

Definition at line 234 of file string.h.

Here is the caller graph for this function:

◆ FeeModeFromString()

bool common::FeeModeFromString ( std::string_view mode_string,
FeeEstimateMode & fee_estimate_mode )

Definition at line 93 of file messages.cpp.

Here is the caller graph for this function:

◆ FUZZ_TARGET()

FUZZ_TARGET ( string )

Definition at line 48 of file string.cpp.

Here is the call graph for this function:

◆ Join()

template<typename C, typename S, typename UnaryOp>
auto util::Join ( const C & container,
const S & separator,
UnaryOp unary_op )

Join all container items.

Typically used to concatenate strings but accepts containers with elements of any type.

Parameters
containerThe items to join
separatorThe separator
unary_opApply this operator to each item

Definition at line 205 of file string.h.

Here is the caller graph for this function:

◆ RemovePrefix()

std::string util::RemovePrefix ( std::string_view str,
std::string_view prefix )
inlinenodiscard

Definition at line 190 of file string.h.

Here is the caller graph for this function:

◆ ResolveErrMsg()

bilingual_str common::ResolveErrMsg ( const std::string & optname,
const std::string & strBind )

Definition at line 151 of file messages.cpp.

Here is the caller graph for this function:

◆ SplitString()

std::vector< std::string > util::SplitString ( std::string_view str,
char sep )
inlinenodiscard

Definition at line 149 of file string.h.

Here is the caller graph for this function:

◆ TrimString()

std::string util::TrimString ( std::string_view str,
std::string_view pattern = " \f\n\r\t\v" )
inlinenodiscard

Definition at line 169 of file string.h.

Here is the caller graph for this function: