namespace samples {
public:
static constexpr std::string_view kName = "handler-multipart-sample";
using HttpHandlerBase::HttpHandlerBase;
const override;
};
const {
if (content_type != "multipart/form-data") {
return "Expected 'multipart/form-data' content type";
}
static constexpr std::string_view kPngMagicBytes = "\x89PNG\r\n\x1a\n";
return "Expecting PNG image format";
}
return fmt::format("city={} image_size={}", json_addr["city"].As<std::string>(), image.value.size());
}
}
int main(int argc, char* argv[]) {
}