Commit eb7f144f authored by Tien-Thinh Nguyen's avatar Tien-Thinh Nguyen

Code cleanup/Apply Clang-format

parent 8471a3b5
...@@ -126,6 +126,7 @@ void smf_qos_flow::deallocate_ressources() { ...@@ -126,6 +126,7 @@ void smf_qos_flow::deallocate_ressources() {
void smf_pdu_session::get_pdu_session_id(uint32_t& psi) const { void smf_pdu_session::get_pdu_session_id(uint32_t& psi) const {
psi = pdu_session_id; psi = pdu_session_id;
} }
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
uint32_t smf_pdu_session::get_pdu_session_id() const { uint32_t smf_pdu_session::get_pdu_session_id() const {
return pdu_session_id; return pdu_session_id;
...@@ -3641,7 +3642,7 @@ void smf_context::trigger_ddds(scid_t scid, uint8_t http_version) { ...@@ -3641,7 +3642,7 @@ void smf_context::trigger_ddds(scid_t scid, uint8_t http_version) {
} }
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
void smf_context::handle_ddds( scid_t scid, uint8_t http_version) { void smf_context::handle_ddds(scid_t scid, uint8_t http_version) {
Logger::smf_app().debug( Logger::smf_app().debug(
"Send request to N11 to triger FlexCN, " "Send request to N11 to triger FlexCN, "
"SMF Context ID " SCID_FMT " ", "SMF Context ID " SCID_FMT " ",
...@@ -3701,7 +3702,8 @@ void smf_context::handle_ddds( scid_t scid, uint8_t http_version) { ...@@ -3701,7 +3702,8 @@ void smf_context::handle_ddds( scid_t scid, uint8_t http_version) {
// DDDS Status // DDDS Status
// TODO: where to get this information in SMF??? // TODO: where to get this information in SMF???
oai::smf_server::model::DddStatus ddds = oai::smf_server::model::DddStatus(); oai::smf_server::model::DddStatus ddds =
oai::smf_server::model::DddStatus();
ev_notif.set_Ddds(ddds); ev_notif.set_Ddds(ddds);
itti_msg->event_notifs.push_back(ev_notif); itti_msg->event_notifs.push_back(ev_notif);
} }
...@@ -3719,7 +3721,6 @@ void smf_context::handle_ddds( scid_t scid, uint8_t http_version) { ...@@ -3719,7 +3721,6 @@ void smf_context::handle_ddds( scid_t scid, uint8_t http_version) {
} }
} }
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
void smf_context::handle_ue_ip_change(scid_t scid, uint8_t http_version) { void smf_context::handle_ue_ip_change(scid_t scid, uint8_t http_version) {
Logger::smf_app().debug( Logger::smf_app().debug(
...@@ -4103,7 +4104,6 @@ void smf_context::handle_plmn_change(scid_t scid, uint8_t http_version) { ...@@ -4103,7 +4104,6 @@ void smf_context::handle_plmn_change(scid_t scid, uint8_t http_version) {
} }
} }
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
void smf_context::update_qos_info( void smf_context::update_qos_info(
std::shared_ptr<smf_pdu_session>& sp, std::shared_ptr<smf_pdu_session>& sp,
......
...@@ -634,8 +634,7 @@ class smf_context : public std::enable_shared_from_this<smf_context> { ...@@ -634,8 +634,7 @@ class smf_context : public std::enable_shared_from_this<smf_context> {
ee_ue_ip_change_connection.disconnect(); ee_ue_ip_change_connection.disconnect();
if (ee_plmn_change_connection.connected()) if (ee_plmn_change_connection.connected())
ee_plmn_change_connection.disconnect(); ee_plmn_change_connection.disconnect();
if (ee_ddds_connection.connected()) if (ee_ddds_connection.connected()) ee_ddds_connection.disconnect();
ee_ddds_connection.disconnect();
if (ee_flexcn.connected()) ee_flexcn.disconnect(); if (ee_flexcn.connected()) ee_flexcn.disconnect();
} }
......
...@@ -80,8 +80,7 @@ class smf_event { ...@@ -80,8 +80,7 @@ class smf_event {
const ee_plmn_change_sig_t::slot_type& sig); const ee_plmn_change_sig_t::slot_type& sig);
// download link data status // download link data status
bs2::connection subscribe_ee_ddds( bs2::connection subscribe_ee_ddds(const ee_ddds_sig_t::slot_type& sig);
const ee_ddds_sig_t::slot_type& sig);
bs2::connection subscribe_ee_flexcn_event( bs2::connection subscribe_ee_flexcn_event(
const ee_flexcn_sig_t::slot_type& sig); const ee_flexcn_sig_t::slot_type& sig);
......
...@@ -984,19 +984,19 @@ smf_event_t event_notification::get_smf_event() const { ...@@ -984,19 +984,19 @@ smf_event_t event_notification::get_smf_event() const {
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
// ddds change // ddds change
void event_notification::set_Ddds(oai::smf_server::model::DddStatus const& value){ void event_notification::set_Ddds(
oai::smf_server::model::DddStatus const& value) {
m_DddStatus = value; m_DddStatus = value;
m_DddStatusIsSet = true; m_DddStatusIsSet = true;
} }
oai::smf_server::model::DddStatus event_notification::get_ddds() const{ oai::smf_server::model::DddStatus event_notification::get_ddds() const {
return m_DddStatus; return m_DddStatus;
} }
bool event_notification::is_ddds_is_set() const{ bool event_notification::is_ddds_is_set() const {
return m_DddStatusIsSet; return m_DddStatusIsSet;
} }
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------
void event_notification::set_timestamp(const std::string& ss) { void event_notification::set_timestamp(const std::string& ss) {
m_timestamp = ss; m_timestamp = ss;
...@@ -1061,16 +1061,17 @@ bool event_notification::is_re_ipv4_addr_is_set() const { ...@@ -1061,16 +1061,17 @@ bool event_notification::is_re_ipv4_addr_is_set() const {
} }
// m_PlmnId // m_PlmnId
void event_notification::set_PlmnId(oai::smf_server::model::PlmnId const& value){ void event_notification::set_PlmnId(
oai::smf_server::model::PlmnId const& value) {
m_PlmnId = value; m_PlmnId = value;
m_PlmnIdIsSet = true; m_PlmnIdIsSet = true;
} }
oai::smf_server::model::PlmnId event_notification::get_plmnid() const{ oai::smf_server::model::PlmnId event_notification::get_plmnid() const {
return m_PlmnId; return m_PlmnId;
} }
bool event_notification::is_plmnid_is_set() const{ bool event_notification::is_plmnid_is_set() const {
return m_PlmnIdIsSet; return m_PlmnIdIsSet;
} }
......
...@@ -47,8 +47,6 @@ extern "C" { ...@@ -47,8 +47,6 @@ extern "C" {
#include "QOSRules.h" #include "QOSRules.h"
} }
// using namespace oai::smf_server::model;
typedef enum { typedef enum {
PDU_SESSION_MSG_TYPE_NONE = -1, PDU_SESSION_MSG_TYPE_NONE = -1,
PDU_SESSION_MSG_TYPE_FIRST = 0, PDU_SESSION_MSG_TYPE_FIRST = 0,
...@@ -634,7 +632,6 @@ class event_notification { ...@@ -634,7 +632,6 @@ class event_notification {
oai::smf_server::model::DddStatus get_ddds() const; oai::smf_server::model::DddStatus get_ddds() const;
bool is_ddds_is_set() const; bool is_ddds_is_set() const;
void set_pdu_session_id(const pdu_session_id_t value); void set_pdu_session_id(const pdu_session_id_t value);
pdu_session_id_t get_pdu_session_id() const; pdu_session_id_t get_pdu_session_id() const;
bool is_psi_is_set() const; bool is_psi_is_set() const;
......
...@@ -1127,10 +1127,10 @@ void session_update_sm_context_procedure::handle_itti_msg( ...@@ -1127,10 +1127,10 @@ void session_update_sm_context_procedure::handle_itti_msg(
sps->set_upCnx_state(upCnx_state_e::UPCNX_STATE_ACTIVATED); sps->set_upCnx_state(upCnx_state_e::UPCNX_STATE_ACTIVATED);
// Trigger Event_exposure event // Trigger Event_exposure event
std::string str_scid = n11_trigger.get()->scid; std::string str_scid = n11_trigger.get()->scid;
//TODO: validate the str_scid // TODO: validate the str_scid
// //
scid_t scid = (scid_t) std::stoul (str_scid,nullptr,0); scid_t scid = (scid_t) std::stoul(str_scid, nullptr, 0);
sc.get()->trigger_ue_ip_change(scid, 1); sc.get()->trigger_ue_ip_change(scid, 1);
sc.get()->trigger_plmn_change(scid, 1); sc.get()->trigger_plmn_change(scid, 1);
sc.get()->trigger_ddds(scid, 1); sc.get()->trigger_ddds(scid, 1);
......
...@@ -43,7 +43,6 @@ ...@@ -43,7 +43,6 @@
#include "smf.h" #include "smf.h"
#include "smf_app.hpp" #include "smf_app.hpp"
#include "smf_config.hpp" #include "smf_config.hpp"
#include "PlmnId.h"
extern "C" { extern "C" {
#include "dynamic_memory_check.h" #include "dynamic_memory_check.h"
...@@ -514,7 +513,8 @@ void smf_sbi::notify_subscribed_event( ...@@ -514,7 +513,8 @@ void smf_sbi::notify_subscribed_event(
// add support for ddds // add support for ddds
if (i.is_ddds_is_set()) { if (i.is_ddds_is_set()) {
//TODO: change this one to the real value when finished the event for ddds // TODO: change this one to the real value when finished the event for
// ddds
// event_notif["dddStatus"] = i.get_ddds(); // event_notif["dddStatus"] = i.get_ddds();
event_notif["dddStatus"] = "TRANSMITTED"; event_notif["dddStatus"] = "TRANSMITTED";
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment