/**
 * 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.
 */

#include "AuthEvent.h"

namespace org {
namespace openapitools {
namespace server {
namespace model {

AuthEvent::AuthEvent() {
  m_NfInstanceId = "";
  m_Success = false;
  m_TimeStamp = "";
  m_ServingNetworkName = "";
  m_AuthRemovalInd = false;
  m_AuthRemovalIndIsSet = false;
}

AuthEvent::~AuthEvent() {}

void AuthEvent::validate() {
  // TODO: implement validation
}

void to_json(nlohmann::json &j, const AuthEvent &o) {
  j = nlohmann::json();
  j["nfInstanceId"] = o.m_NfInstanceId;
  j["success"] = o.m_Success;
  j["timeStamp"] = o.m_TimeStamp;
  j["authType"] = o.m_AuthType;
  j["servingNetworkName"] = o.m_ServingNetworkName;
  if (o.authRemovalIndIsSet())
    j["authRemovalInd"] = o.m_AuthRemovalInd;
}

void from_json(const nlohmann::json &j, AuthEvent &o) {
  j.at("nfInstanceId").get_to(o.m_NfInstanceId);
  j.at("success").get_to(o.m_Success);
  j.at("timeStamp").get_to(o.m_TimeStamp);
  j.at("authType").get_to(o.m_AuthType);
  j.at("servingNetworkName").get_to(o.m_ServingNetworkName);
  if (j.find("authRemovalInd") != j.end()) {
    j.at("authRemovalInd").get_to(o.m_AuthRemovalInd);
    o.m_AuthRemovalIndIsSet = true;
  }
}

std::string AuthEvent::getNfInstanceId() const { return m_NfInstanceId; }
void AuthEvent::setNfInstanceId(std::string const &value) {
  m_NfInstanceId = value;
}
bool AuthEvent::isSuccess() const { return m_Success; }
void AuthEvent::setSuccess(bool const value) { m_Success = value; }
std::string AuthEvent::getTimeStamp() const { return m_TimeStamp; }
void AuthEvent::setTimeStamp(std::string const &value) { m_TimeStamp = value; }
AuthType AuthEvent::getAuthType() const { return m_AuthType; }
void AuthEvent::setAuthType(AuthType const &value) { m_AuthType = value; }
std::string AuthEvent::getServingNetworkName() const {
  return m_ServingNetworkName;
}
void AuthEvent::setServingNetworkName(std::string const &value) {
  m_ServingNetworkName = value;
}
bool AuthEvent::isAuthRemovalInd() const { return m_AuthRemovalInd; }
void AuthEvent::setAuthRemovalInd(bool const value) {
  m_AuthRemovalInd = value;
  m_AuthRemovalIndIsSet = true;
}
bool AuthEvent::authRemovalIndIsSet() const { return m_AuthRemovalIndIsSet; }
void AuthEvent::unsetAuthRemovalInd() { m_AuthRemovalIndIsSet = false; }

} // namespace model
} // namespace server
} // namespace openapitools
} // namespace org
