DataChangeNotify.cpp 5.29 KB
Newer Older
yangjian's avatar
yangjian committed
1
/**
yangjian's avatar
yangjian committed
2 3 4 5 6 7 8 9 10 11 12
 * Nudr_DataRepository API OpenAPI file
 * Unified Data Repository Service. © 2020, 3GPP Organizational Partners (ARIB,
 * ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
 *
 * The version of the OpenAPI document: 2.1.2
 *
 *
 * NOTE: This class is auto generated by OpenAPI Generator
 * (https://openapi-generator.tech). https://openapi-generator.tech Do not edit
 * the class manually.
 */
yangjian's avatar
yangjian committed
13 14 15

#include "DataChangeNotify.h"

Tien-Thinh Nguyen's avatar
Tien-Thinh Nguyen committed
16
namespace oai::udr::model {
yangjian's avatar
yangjian committed
17

yangjian's avatar
yangjian committed
18 19 20 21 22 23 24 25
DataChangeNotify::DataChangeNotify() {
  m_OriginalCallbackReferenceIsSet = false;
  m_UeId = "";
  m_UeIdIsSet = false;
  m_NotifyItemsIsSet = false;
  m_SdmSubscriptionIsSet = false;
  m_AdditionalSdmSubscriptionsIsSet = false;
  m_SubscriptionDataSubscriptionsIsSet = false;
yangjian's avatar
yangjian committed
26 27
}

yangjian's avatar
yangjian committed
28
DataChangeNotify::~DataChangeNotify() {}
yangjian's avatar
yangjian committed
29

yangjian's avatar
yangjian committed
30 31
void DataChangeNotify::validate() {
  // TODO: implement validation
yangjian's avatar
yangjian committed
32 33
}

yangjian's avatar
yangjian committed
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
void to_json(nlohmann::json &j, const DataChangeNotify &o) {
  j = nlohmann::json();
  if (o.originalCallbackReferenceIsSet() ||
      !o.m_OriginalCallbackReference.empty())
    j["originalCallbackReference"] = o.m_OriginalCallbackReference;
  if (o.ueIdIsSet())
    j["ueId"] = o.m_UeId;
  if (o.notifyItemsIsSet() || !o.m_NotifyItems.empty())
    j["notifyItems"] = o.m_NotifyItems;
  if (o.sdmSubscriptionIsSet())
    j["sdmSubscription"] = o.m_SdmSubscription;
  if (o.additionalSdmSubscriptionsIsSet() ||
      !o.m_AdditionalSdmSubscriptions.empty())
    j["additionalSdmSubscriptions"] = o.m_AdditionalSdmSubscriptions;
  if (o.subscriptionDataSubscriptionsIsSet() ||
      !o.m_SubscriptionDataSubscriptions.empty())
    j["subscriptionDataSubscriptions"] = o.m_SubscriptionDataSubscriptions;
yangjian's avatar
yangjian committed
51 52
}

yangjian's avatar
yangjian committed
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
void from_json(const nlohmann::json &j, DataChangeNotify &o) {
  if (j.find("originalCallbackReference") != j.end()) {
    j.at("originalCallbackReference").get_to(o.m_OriginalCallbackReference);
    o.m_OriginalCallbackReferenceIsSet = true;
  }
  if (j.find("ueId") != j.end()) {
    j.at("ueId").get_to(o.m_UeId);
    o.m_UeIdIsSet = true;
  }
  if (j.find("notifyItems") != j.end()) {
    j.at("notifyItems").get_to(o.m_NotifyItems);
    o.m_NotifyItemsIsSet = true;
  }
  if (j.find("sdmSubscription") != j.end()) {
    j.at("sdmSubscription").get_to(o.m_SdmSubscription);
    o.m_SdmSubscriptionIsSet = true;
  }
  if (j.find("additionalSdmSubscriptions") != j.end()) {
    j.at("additionalSdmSubscriptions").get_to(o.m_AdditionalSdmSubscriptions);
    o.m_AdditionalSdmSubscriptionsIsSet = true;
  }
  if (j.find("subscriptionDataSubscriptions") != j.end()) {
    j.at("subscriptionDataSubscriptions")
        .get_to(o.m_SubscriptionDataSubscriptions);
    o.m_SubscriptionDataSubscriptionsIsSet = true;
  }
yangjian's avatar
yangjian committed
79 80
}

yangjian's avatar
yangjian committed
81 82
std::vector<std::string> &DataChangeNotify::getOriginalCallbackReference() {
  return m_OriginalCallbackReference;
yangjian's avatar
yangjian committed
83
}
yangjian's avatar
yangjian committed
84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141
void DataChangeNotify::setOriginalCallbackReference(
    std::vector<std::string> const &value) {
  m_OriginalCallbackReference = value;
  m_OriginalCallbackReferenceIsSet = true;
}
bool DataChangeNotify::originalCallbackReferenceIsSet() const {
  return m_OriginalCallbackReferenceIsSet;
}
void DataChangeNotify::unsetOriginalCallbackReference() {
  m_OriginalCallbackReferenceIsSet = false;
}
std::string DataChangeNotify::getUeId() const { return m_UeId; }
void DataChangeNotify::setUeId(std::string const &value) {
  m_UeId = value;
  m_UeIdIsSet = true;
}
bool DataChangeNotify::ueIdIsSet() const { return m_UeIdIsSet; }
void DataChangeNotify::unsetUeId() { m_UeIdIsSet = false; }
std::vector<NotifyItem> &DataChangeNotify::getNotifyItems() {
  return m_NotifyItems;
}
void DataChangeNotify::setNotifyItems(std::vector<NotifyItem> const &value) {
  m_NotifyItems = value;
  m_NotifyItemsIsSet = true;
}
bool DataChangeNotify::notifyItemsIsSet() const { return m_NotifyItemsIsSet; }
void DataChangeNotify::unsetNotifyItems() { m_NotifyItemsIsSet = false; }
SdmSubscription DataChangeNotify::getSdmSubscription() const {
  return m_SdmSubscription;
}
void DataChangeNotify::setSdmSubscription(SdmSubscription const &value) {
  m_SdmSubscription = value;
  m_SdmSubscriptionIsSet = true;
}
bool DataChangeNotify::sdmSubscriptionIsSet() const {
  return m_SdmSubscriptionIsSet;
}
void DataChangeNotify::unsetSdmSubscription() {
  m_SdmSubscriptionIsSet = false;
}
std::vector<SdmSubscription> &
DataChangeNotify::getAdditionalSdmSubscriptions() {
  return m_AdditionalSdmSubscriptions;
}
void DataChangeNotify::setAdditionalSdmSubscriptions(
    std::vector<SdmSubscription> const &value) {
  m_AdditionalSdmSubscriptions = value;
  m_AdditionalSdmSubscriptionsIsSet = true;
}
bool DataChangeNotify::additionalSdmSubscriptionsIsSet() const {
  return m_AdditionalSdmSubscriptionsIsSet;
}
void DataChangeNotify::unsetAdditionalSdmSubscriptions() {
  m_AdditionalSdmSubscriptionsIsSet = false;
}
std::vector<SubscriptionDataSubscriptions> &
DataChangeNotify::getSubscriptionDataSubscriptions() {
  return m_SubscriptionDataSubscriptions;
yangjian's avatar
yangjian committed
142
}
yangjian's avatar
yangjian committed
143 144 145 146
void DataChangeNotify::setSubscriptionDataSubscriptions(
    std::vector<SubscriptionDataSubscriptions> const &value) {
  m_SubscriptionDataSubscriptions = value;
  m_SubscriptionDataSubscriptionsIsSet = true;
yangjian's avatar
yangjian committed
147
}
yangjian's avatar
yangjian committed
148 149
bool DataChangeNotify::subscriptionDataSubscriptionsIsSet() const {
  return m_SubscriptionDataSubscriptionsIsSet;
yangjian's avatar
yangjian committed
150
}
yangjian's avatar
yangjian committed
151 152
void DataChangeNotify::unsetSubscriptionDataSubscriptions() {
  m_SubscriptionDataSubscriptionsIsSet = false;
yangjian's avatar
yangjian committed
153 154
}

Tien-Thinh Nguyen's avatar
Tien-Thinh Nguyen committed
155
} // namespace oai::udr::model