/**
 * 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 "ValidTimePeriod.h"

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

ValidTimePeriod::ValidTimePeriod() {
  m_StartTime = "";
  m_StartTimeIsSet = false;
  m_EndTime = "";
  m_EndTimeIsSet = false;
}

ValidTimePeriod::~ValidTimePeriod() {}

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

void to_json(nlohmann::json &j, const ValidTimePeriod &o) {
  j = nlohmann::json();
  if (o.startTimeIsSet())
    j["startTime"] = o.m_StartTime;
  if (o.endTimeIsSet())
    j["endTime"] = o.m_EndTime;
}

void from_json(const nlohmann::json &j, ValidTimePeriod &o) {
  if (j.find("startTime") != j.end()) {
    j.at("startTime").get_to(o.m_StartTime);
    o.m_StartTimeIsSet = true;
  }
  if (j.find("endTime") != j.end()) {
    j.at("endTime").get_to(o.m_EndTime);
    o.m_EndTimeIsSet = true;
  }
}

std::string ValidTimePeriod::getStartTime() const { return m_StartTime; }
void ValidTimePeriod::setStartTime(std::string const &value) {
  m_StartTime = value;
  m_StartTimeIsSet = true;
}
bool ValidTimePeriod::startTimeIsSet() const { return m_StartTimeIsSet; }
void ValidTimePeriod::unsetStartTime() { m_StartTimeIsSet = false; }
std::string ValidTimePeriod::getEndTime() const { return m_EndTime; }
void ValidTimePeriod::setEndTime(std::string const &value) {
  m_EndTime = value;
  m_EndTimeIsSet = true;
}
bool ValidTimePeriod::endTimeIsSet() const { return m_EndTimeIsSet; }
void ValidTimePeriod::unsetEndTime() { m_EndTimeIsSet = false; }

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