Refactoring project layout

This commit is contained in:
stephb9959
2021-10-19 19:45:50 -07:00
parent 816f0a6e7c
commit 2a0b45fde1
110 changed files with 1151 additions and 230 deletions

View File

@@ -0,0 +1,32 @@
//
// License type: BSD 3-Clause License
// License copy: https://github.com/Telecominfraproject/wlan-cloud-ucentralgw/blob/master/LICENSE
//
// Created by Stephane Bourque on 2021-03-04.
// Arilia Wireless Inc.
//
#include "Poco/Array.h"
#include "Poco/JSON/Stringifier.h"
#include "RESTAPI_default_configurations.h"
#include "StorageService.h"
#include "framework/RESTAPI_protocol.h"
namespace OpenWifi {
void RESTAPI_default_configurations::DoGet() {
std::vector<GWObjects::DefaultConfiguration> DefConfigs;
Storage()->GetDefaultConfigurations(QB_.Offset, QB_.Limit, DefConfigs);
Poco::JSON::Array Objects;
for (const auto &i : DefConfigs) {
Poco::JSON::Object Obj;
i.to_json(Obj);
Objects.add(Obj);
}
Poco::JSON::Object RetObj;
RetObj.set(RESTAPI::Protocol::CONFIGURATIONS, Objects);
ReturnObject(RetObj);
}
}