| 71 | } |
| 72 | |
| 73 | bool |
| 74 | ConfigElements::setCapture(const String &name, const String &pattern) |
| 75 | { |
| 76 | auto it = _captures.find(name); |
| 77 | if (_captures.end() == it) { |
| 78 | auto mp = new MultiPattern(name); |
| 79 | if (nullptr != mp) { |
| 80 | _captures[name] = mp; |
| 81 | } else { |
| 82 | return false; |
| 83 | } |
| 84 | } |
| 85 | setPattern(*_captures[name], pattern.c_str()); |
| 86 | CacheKeyDebug("added capture pattern '%s' for element '%s'", pattern.c_str(), name.c_str()); |
| 87 | return true; |
| 88 | } |
| 89 | |
| 90 | void |
| 91 | ConfigElements::addCapture(const char *arg) |
nothing calls this directly
no test coverage detected