/**
* Nsmf_PDUSession
* SMF PDU Session 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 "QosFlowSetupItem.h"

namespace oai {
namespace smf_server {
namespace model {

QosFlowSetupItem::QosFlowSetupItem()
{
    m_Qfi = 0;
    m_Ebi = 0;
    m_EbiIsSet = false;
    m_QosFlowDescriptionIsSet = false;
    m_QosFlowProfileIsSet = false;
    
}

QosFlowSetupItem::~QosFlowSetupItem()
{
}

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

void to_json(nlohmann::json& j, const QosFlowSetupItem& o)
{
    j = nlohmann::json();
    j["qfi"] = o.m_Qfi;
    j["qosRules"] = o.m_QosRules;
    if(o.ebiIsSet())
        j["ebi"] = o.m_Ebi;
    if(o.qosFlowDescriptionIsSet())
        j["qosFlowDescription"] = o.m_QosFlowDescription;
    if(o.qosFlowProfileIsSet())
        j["qosFlowProfile"] = o.m_QosFlowProfile;
}

void from_json(const nlohmann::json& j, QosFlowSetupItem& o)
{
    j.at("qfi").get_to(o.m_Qfi);
    j.at("qosRules").get_to(o.m_QosRules);
    if(j.find("ebi") != j.end())
    {
        j.at("ebi").get_to(o.m_Ebi);
        o.m_EbiIsSet = true;
    } 
    if(j.find("qosFlowDescription") != j.end())
    {
        j.at("qosFlowDescription").get_to(o.m_QosFlowDescription);
        o.m_QosFlowDescriptionIsSet = true;
    } 
    if(j.find("qosFlowProfile") != j.end())
    {
        j.at("qosFlowProfile").get_to(o.m_QosFlowProfile);
        o.m_QosFlowProfileIsSet = true;
    } 
}

int32_t QosFlowSetupItem::getQfi() const
{
    return m_Qfi;
}
void QosFlowSetupItem::setQfi(int32_t const value)
{
    m_Qfi = value;
    
}
std::string QosFlowSetupItem::getQosRules() const
{
    return m_QosRules;
}
void QosFlowSetupItem::setQosRules(std::string const& value)
{
    m_QosRules = value;
    
}
int32_t QosFlowSetupItem::getEbi() const
{
    return m_Ebi;
}
void QosFlowSetupItem::setEbi(int32_t const value)
{
    m_Ebi = value;
    m_EbiIsSet = true;
}
bool QosFlowSetupItem::ebiIsSet() const
{
    return m_EbiIsSet;
}
void QosFlowSetupItem::unsetEbi()
{
    m_EbiIsSet = false;
}
std::string QosFlowSetupItem::getQosFlowDescription() const
{
    return m_QosFlowDescription;
}
void QosFlowSetupItem::setQosFlowDescription(std::string const& value)
{
    m_QosFlowDescription = value;
    m_QosFlowDescriptionIsSet = true;
}
bool QosFlowSetupItem::qosFlowDescriptionIsSet() const
{
    return m_QosFlowDescriptionIsSet;
}
void QosFlowSetupItem::unsetQosFlowDescription()
{
    m_QosFlowDescriptionIsSet = false;
}
QosFlowProfile QosFlowSetupItem::getQosFlowProfile() const
{
    return m_QosFlowProfile;
}
void QosFlowSetupItem::setQosFlowProfile(QosFlowProfile const& value)
{
    m_QosFlowProfile = value;
    m_QosFlowProfileIsSet = true;
}
bool QosFlowSetupItem::qosFlowProfileIsSet() const
{
    return m_QosFlowProfileIsSet;
}
void QosFlowSetupItem::unsetQosFlowProfile()
{
    m_QosFlowProfileIsSet = false;
}

}
}
}

