MCPcopy Create free account
hub / github.com/NPP-JSONViewer/JSON-Viewer / IsNumber

Method IsNumber

src/UtilityLib/Utility.cpp:283–294  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

281}
282
283bool CUtility::IsNumber(const std::wstring& str)
284{
285 return !str.empty()
286 && std::find_if(
287 str.begin(),
288 str.end(),
289 [](wchar_t c)
290 {
291 return !std::isdigit(c);
292 })
293 == str.end();
294}
295
296auto CUtility::GetNumber(const std::wstring& str) -> std::optional<int>
297{

Callers 1

TESTFunction · 0.80

Calls

no outgoing calls

Tested by 1

TESTFunction · 0.64