/**
 * Namf_Communication
 * AMF Communication Service © 2019, 3GPP Organizational Partners (ARIB, ATIS,
 * CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
 *
 * The version of the OpenAPI document: 1.1.0.alpha-1
 *
 *
 * NOTE: This class is auto generated by OpenAPI Generator
 * (https://openapi-generator.tech). https://openapi-generator.tech Do not edit
 * the class manually.
 */

#include "N2InformationTransferError.h"

namespace oai {
namespace amf {
namespace model {

N2InformationTransferError::N2InformationTransferError() {
  m_PwdErrorInfoIsSet = false;
}

N2InformationTransferError::~N2InformationTransferError() {}

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

void to_json(nlohmann::json& j, const N2InformationTransferError& o) {
  j          = nlohmann::json();
  j["error"] = o.m_Error;
  if (o.pwdErrorInfoIsSet()) j["pwdErrorInfo"] = o.m_PwdErrorInfo;
}

void from_json(const nlohmann::json& j, N2InformationTransferError& o) {
  j.at("error").get_to(o.m_Error);
  if (j.find("pwdErrorInfo") != j.end()) {
    j.at("pwdErrorInfo").get_to(o.m_PwdErrorInfo);
    o.m_PwdErrorInfoIsSet = true;
  }
}

ProblemDetails_2 N2InformationTransferError::getError() const {
  return m_Error;
}
void N2InformationTransferError::setError(ProblemDetails_2 const& value) {
  m_Error = value;
}
PWSErrorData N2InformationTransferError::getPwdErrorInfo() const {
  return m_PwdErrorInfo;
}
void N2InformationTransferError::setPwdErrorInfo(PWSErrorData const& value) {
  m_PwdErrorInfo      = value;
  m_PwdErrorInfoIsSet = true;
}
bool N2InformationTransferError::pwdErrorInfoIsSet() const {
  return m_PwdErrorInfoIsSet;
}
void N2InformationTransferError::unsetPwdErrorInfo() {
  m_PwdErrorInfoIsSet = false;
}

}  // namespace model
}  // namespace amf
}  // namespace oai
