X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=Bouncer%2Fsrc%2Fxapp.hpp;fp=Bouncer%2Fsrc%2Fxapp.hpp;h=0000000000000000000000000000000000000000;hb=fbc7e3ad84fc7269233a2f0b5d416cb1c6f8a6ea;hp=e436f98f59c8bb4f98149e11055a4ed8960eeed3;hpb=eb27c05c05b5042d115480c40cffa16e7d473d80;p=ric-app%2Fbouncer.git diff --git a/Bouncer/src/xapp.hpp b/Bouncer/src/xapp.hpp deleted file mode 100644 index e436f98..0000000 --- a/Bouncer/src/xapp.hpp +++ /dev/null @@ -1,94 +0,0 @@ -/* -# ================================================================================== -# Copyright (c) 2020 HCL Technologies Limited. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# ================================================================================== -*/ - - -#pragma once - -#ifndef SRC_XAPP_HPP_ -#define SRC_XAPP_HPP_ - -#include -#include -#include -#include -#include -#include -#include -#include "xapp_rmr.hpp" -#include "xapp_sdl.hpp" -#include "rapidjson/writer.h" -#include "rapidjson/document.h" -#include "rapidjson/error/error.h" -#include -#include "msgs_proc.hpp" -#include "subs_mgmt.hpp" -#include "xapp_config.hpp" -extern "C" { -#include "rnib/rnibreader.h" -} -using namespace std; -using namespace std::placeholders; -using namespace rapidjson; - - -class Xapp{ -public: - - Xapp(XappSettings &, XappRmr &); - - ~Xapp(void); - - void stop(void); - - void startup(SubscriptionHandler &); - void shutdown(void); - - void start_xapp_receiver(XappMsgHandler &); - void Run(); - - //void sdl_data(void); - - Xapp(Xapp const &)=delete; - Xapp& operator=(Xapp const &) = delete; - - void register_handler(XappMsgHandler &fn){ - _callbacks.emplace_back(fn); - } - - //getters/setters. - void set_rnib_gnblist(void); - std::vector get_rnib_gnblist(){ return rnib_gnblist; } - -private: - void startup_subscribe_requests(void ); - void shutdown_subscribe_deletes(void); - void startup_get_policies(void ); - - - XappRmr * rmr_ref; - XappSettings * config_ref; - SubscriptionHandler *subhandler_ref; - - std::mutex *xapp_mutex; - std::vector xapp_rcv_thread; - std::vector rnib_gnblist; - std::vector _callbacks; -}; - - -#endif /* SRC_XAPP_HPP_ */