mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#2797 Ensemble curves. Support for text ensemble parameters. Unit test
This commit is contained in:
@@ -76,6 +76,24 @@ double RiaStdStringTools::toDouble(const std::string& s)
|
||||
return doubleValue;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaStdStringTools::containsAlphabetic(const std::string& s)
|
||||
{
|
||||
return std::find_if(s.begin(), s.end(), [](char c) { return isalpha(c); }) != s.end();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaStdStringTools::startsWithAlphabetic(const std::string& s)
|
||||
{
|
||||
if (s.empty()) return false;
|
||||
|
||||
return isalpha(s[0]);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user