You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
519 B
25 lines
519 B
#include <iostream>
|
|
|
|
#include "../lib/api.hpp"
|
|
|
|
using namespace std;
|
|
|
|
int main() {
|
|
|
|
defapi myDef({"add", "delete", "update"}, {"id", "key", "value"});
|
|
|
|
// cout << myDef.keys[2];
|
|
|
|
myDef.necessary("add", {"id", "key", "value"});
|
|
myDef.necessary("delete", {"id"});
|
|
myDef.necessary("update", {"id"});
|
|
myDef.necessary("update", {"value"});
|
|
|
|
// cout << myDef.val_matrix["delete"].empty();
|
|
|
|
api myApi(&myDef, "GET /update/?id=1&value=true HTTP/1.1");
|
|
|
|
cout << myApi.object["value"];
|
|
|
|
|
|
} |