Create Utilities Manager for storage of non database Based functions
This commit is contained in:
19
src/utilities.cpp
Normal file
19
src/utilities.cpp
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
#include <string>
|
||||||
|
#include <list>
|
||||||
|
#include <iostream>
|
||||||
|
#include <vector>
|
||||||
|
#include <pqxx/pqxx>
|
||||||
|
#include "crow.h"
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Utility Manager
|
||||||
|
*/
|
||||||
|
namespace Utilities {
|
||||||
|
/*
|
||||||
|
* Takes String and cuts from the start-up to the length of valueName
|
||||||
|
*/
|
||||||
|
std::string extractSingleValueFromRequestBody(std::string responseBody, std::string valueName){
|
||||||
|
return responseBody.substr(valueName.length() + 1, responseBody.length());
|
||||||
|
}
|
||||||
|
}
|
Reference in New Issue
Block a user