代码拉取完成,页面将自动刷新
/*
Nudr_DataRepository API OpenAPI file
Unified Data Repository Service. © 2023, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
API version: 2.2.4
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package OpenAPI_Nudr_DR
import (
"encoding/json"
"fmt"
)
// checks if the SubscribedDefaultQos1 type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &SubscribedDefaultQos1{}
// SubscribedDefaultQos1 Provides the subsribed 5QI and the ARP, it may contain the priority level.
type SubscribedDefaultQos1 struct {
// Unsigned integer representing a 5G QoS Identifier (see clause 5.7.2.1 of 3GPP TS 23.501, within the range 0 to 255.
Var5qi int32 `json:"5qi"`
Arp Arp1 `json:"arp"`
// Unsigned integer indicating the 5QI Priority Level (see clauses 5.7.3.3 and 5.7.4 of 3GPP TS 23.501, within the range 1 to 127.Values are ordered in decreasing order of priority, i.e. with 1 as the highest priority and 127 as the lowest priority.
PriorityLevel *int32 `json:"priorityLevel,omitempty"`
}
type _SubscribedDefaultQos1 SubscribedDefaultQos1
// NewSubscribedDefaultQos1 instantiates a new SubscribedDefaultQos1 object
// This constructor will assign default values to properties that have it defined,
// and makes sure properties required by API are set, but the set of arguments
// will change when the set of required properties is changed
func NewSubscribedDefaultQos1(var5qi int32, arp Arp1) *SubscribedDefaultQos1 {
this := SubscribedDefaultQos1{}
this.Var5qi = var5qi
this.Arp = arp
return &this
}
// NewSubscribedDefaultQos1WithDefaults instantiates a new SubscribedDefaultQos1 object
// This constructor will only assign default values to properties that have it defined,
// but it doesn't guarantee that properties required by API are set
func NewSubscribedDefaultQos1WithDefaults() *SubscribedDefaultQos1 {
this := SubscribedDefaultQos1{}
return &this
}
// GetVar5qi returns the Var5qi field value
func (o *SubscribedDefaultQos1) GetVar5qi() int32 {
if o == nil {
var ret int32
return ret
}
return o.Var5qi
}
// GetVar5qiOk returns a tuple with the Var5qi field value
// and a boolean to check if the value has been set.
func (o *SubscribedDefaultQos1) GetVar5qiOk() (*int32, bool) {
if o == nil {
return nil, false
}
return &o.Var5qi, true
}
// SetVar5qi sets field value
func (o *SubscribedDefaultQos1) SetVar5qi(v int32) {
o.Var5qi = v
}
// GetArp returns the Arp field value
func (o *SubscribedDefaultQos1) GetArp() Arp1 {
if o == nil {
var ret Arp1
return ret
}
return o.Arp
}
// GetArpOk returns a tuple with the Arp field value
// and a boolean to check if the value has been set.
func (o *SubscribedDefaultQos1) GetArpOk() (*Arp1, bool) {
if o == nil {
return nil, false
}
return &o.Arp, true
}
// SetArp sets field value
func (o *SubscribedDefaultQos1) SetArp(v Arp1) {
o.Arp = v
}
// GetPriorityLevel returns the PriorityLevel field value if set, zero value otherwise.
func (o *SubscribedDefaultQos1) GetPriorityLevel() int32 {
if o == nil || IsNil(o.PriorityLevel) {
var ret int32
return ret
}
return *o.PriorityLevel
}
// GetPriorityLevelOk returns a tuple with the PriorityLevel field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *SubscribedDefaultQos1) GetPriorityLevelOk() (*int32, bool) {
if o == nil || IsNil(o.PriorityLevel) {
return nil, false
}
return o.PriorityLevel, true
}
// HasPriorityLevel returns a boolean if a field has been set.
func (o *SubscribedDefaultQos1) HasPriorityLevel() bool {
if o != nil && !IsNil(o.PriorityLevel) {
return true
}
return false
}
// SetPriorityLevel gets a reference to the given int32 and assigns it to the PriorityLevel field.
func (o *SubscribedDefaultQos1) SetPriorityLevel(v int32) {
o.PriorityLevel = &v
}
func (o SubscribedDefaultQos1) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o SubscribedDefaultQos1) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
toSerialize["5qi"] = o.Var5qi
toSerialize["arp"] = o.Arp
if !IsNil(o.PriorityLevel) {
toSerialize["priorityLevel"] = o.PriorityLevel
}
return toSerialize, nil
}
func (o *SubscribedDefaultQos1) UnmarshalJSON(bytes []byte) (err error) {
// This validates that all required properties are included in the JSON object
// by unmarshalling the object into a generic map with string keys and checking
// that every required field exists as a key in the generic map.
requiredProperties := []string{
"5qi",
"arp",
}
allProperties := make(map[string]interface{})
err = json.Unmarshal(bytes, &allProperties)
if err != nil {
return err
}
for _, requiredProperty := range requiredProperties {
if _, exists := allProperties[requiredProperty]; !exists {
return fmt.Errorf("no value given for required property %v", requiredProperty)
}
}
varSubscribedDefaultQos1 := _SubscribedDefaultQos1{}
err = json.Unmarshal(bytes, &varSubscribedDefaultQos1)
if err != nil {
return err
}
*o = SubscribedDefaultQos1(varSubscribedDefaultQos1)
return err
}
type NullableSubscribedDefaultQos1 struct {
value *SubscribedDefaultQos1
isSet bool
}
func (v NullableSubscribedDefaultQos1) Get() *SubscribedDefaultQos1 {
return v.value
}
func (v *NullableSubscribedDefaultQos1) Set(val *SubscribedDefaultQos1) {
v.value = val
v.isSet = true
}
func (v NullableSubscribedDefaultQos1) IsSet() bool {
return v.isSet
}
func (v *NullableSubscribedDefaultQos1) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableSubscribedDefaultQos1(val *SubscribedDefaultQos1) *NullableSubscribedDefaultQos1 {
return &NullableSubscribedDefaultQos1{value: val, isSet: true}
}
func (v NullableSubscribedDefaultQos1) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableSubscribedDefaultQos1) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。