Kylin/HttpProxy/TemplateMatchs.cpp
2023-12-30 00:03:40 +08:00

13 lines
442 B
C++

#include "TemplateMatchs.h"
TemplateMatchStorageBase::const_reference TemplateMatchStorageBase::at(boost::core::string_view id) const {
for (std::size_t i = 0; i < size(); ++i) {
if (ids()[i] == id) return matches()[i];
}
boost::throw_exception(std::out_of_range(""));
}
TemplateMatchStorageBase::const_reference TemplateMatchStorageBase::operator[](boost::core::string_view id) const {
return at(id);
}