| 367 | } |
| 368 | |
| 369 | String String::extract(String const& chars) { |
| 370 | StringList l = splitAny(chars, 1); |
| 371 | if (l.size() == 0) { |
| 372 | return String(); |
| 373 | } else if (l.size() == 1) { |
| 374 | clear(); |
| 375 | return l.at(0); |
| 376 | } else { |
| 377 | *this = l.at(1); |
| 378 | return l.at(0); |
| 379 | } |
| 380 | } |
| 381 | |
| 382 | String String::rextract(String const& chars) { |
| 383 | if (empty()) |
no test coverage detected