Clean up rest-dbus interface
This is the first round of making the rest-dbus interface use the
modern practices, like shared_ptr responses, and no-throw XML parsing.
While it makes the implementation better, it does not fix everything.
Change-Id: I985d45b03f1992e334f8a650f7f9392cc5fff30c
Signed-off-by: Ed Tanous <ed.tanous@intel.com>
diff --git a/include/async_resp.hpp b/include/async_resp.hpp
new file mode 100644
index 0000000..af4edeb
--- /dev/null
+++ b/include/async_resp.hpp
@@ -0,0 +1,25 @@
+#pragma once
+
+namespace bmcweb
+{
+
+/**
+ * AsyncResp
+ * Gathers data needed for response processing after async calls are done
+ */
+class AsyncResp
+{
+ public:
+ AsyncResp(crow::Response& response) : res(response)
+ {
+ }
+
+ ~AsyncResp()
+ {
+ res.end();
+ }
+
+ crow::Response& res;
+};
+
+} // namespace bmcweb
\ No newline at end of file