15bool is_all_whitespace(
const std::string& s) {
16 return std::all_of(s.begin(), s.end(), [](
unsigned char c) { return std::isspace(c) != 0; });
24 const std::size_t pos = factory_string.find_first_of(
'?');
25 if (pos == std::string::npos) {
31 std::string tail = factory_string.substr(pos + 1);
33 if (tail.empty() || is_all_whitespace(tail)) {
37 if (tail.front() ==
'@') {
38 const std::string path = tail.substr(1);
40 throw ValueError(
"factory-string options: '@' indirection requires a non-empty path");