代码拉取完成,页面将自动刷新
/*
3gpp-mbs-session
API for MBS Session Management. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
API version: 1.1.1
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package OpenAPI_MBSSession
import (
"encoding/json"
"fmt"
"time"
)
// checks if the MbsSessionEventReport type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &MbsSessionEventReport{}
// MbsSessionEventReport MBS session event report
type MbsSessionEventReport struct {
EventType MbsSessionEventType `json:"eventType"`
// string with format 'date-time' as defined in OpenAPI.
TimeStamp *time.Time `json:"timeStamp,omitempty"`
IngressTunAddrInfo *IngressTunAddrInfo `json:"ingressTunAddrInfo,omitempty"`
BroadcastDelStatus *BroadcastDeliveryStatus `json:"broadcastDelStatus,omitempty"`
}
type _MbsSessionEventReport MbsSessionEventReport
// NewMbsSessionEventReport instantiates a new MbsSessionEventReport 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 NewMbsSessionEventReport(eventType MbsSessionEventType) *MbsSessionEventReport {
this := MbsSessionEventReport{}
this.EventType = eventType
return &this
}
// NewMbsSessionEventReportWithDefaults instantiates a new MbsSessionEventReport 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 NewMbsSessionEventReportWithDefaults() *MbsSessionEventReport {
this := MbsSessionEventReport{}
return &this
}
// GetEventType returns the EventType field value
func (o *MbsSessionEventReport) GetEventType() MbsSessionEventType {
if o == nil {
var ret MbsSessionEventType
return ret
}
return o.EventType
}
// GetEventTypeOk returns a tuple with the EventType field value
// and a boolean to check if the value has been set.
func (o *MbsSessionEventReport) GetEventTypeOk() (*MbsSessionEventType, bool) {
if o == nil {
return nil, false
}
return &o.EventType, true
}
// SetEventType sets field value
func (o *MbsSessionEventReport) SetEventType(v MbsSessionEventType) {
o.EventType = v
}
// GetTimeStamp returns the TimeStamp field value if set, zero value otherwise.
func (o *MbsSessionEventReport) GetTimeStamp() time.Time {
if o == nil || IsNil(o.TimeStamp) {
var ret time.Time
return ret
}
return *o.TimeStamp
}
// GetTimeStampOk returns a tuple with the TimeStamp field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MbsSessionEventReport) GetTimeStampOk() (*time.Time, bool) {
if o == nil || IsNil(o.TimeStamp) {
return nil, false
}
return o.TimeStamp, true
}
// HasTimeStamp returns a boolean if a field has been set.
func (o *MbsSessionEventReport) HasTimeStamp() bool {
if o != nil && !IsNil(o.TimeStamp) {
return true
}
return false
}
// SetTimeStamp gets a reference to the given time.Time and assigns it to the TimeStamp field.
func (o *MbsSessionEventReport) SetTimeStamp(v time.Time) {
o.TimeStamp = &v
}
// GetIngressTunAddrInfo returns the IngressTunAddrInfo field value if set, zero value otherwise.
func (o *MbsSessionEventReport) GetIngressTunAddrInfo() IngressTunAddrInfo {
if o == nil || IsNil(o.IngressTunAddrInfo) {
var ret IngressTunAddrInfo
return ret
}
return *o.IngressTunAddrInfo
}
// GetIngressTunAddrInfoOk returns a tuple with the IngressTunAddrInfo field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MbsSessionEventReport) GetIngressTunAddrInfoOk() (*IngressTunAddrInfo, bool) {
if o == nil || IsNil(o.IngressTunAddrInfo) {
return nil, false
}
return o.IngressTunAddrInfo, true
}
// HasIngressTunAddrInfo returns a boolean if a field has been set.
func (o *MbsSessionEventReport) HasIngressTunAddrInfo() bool {
if o != nil && !IsNil(o.IngressTunAddrInfo) {
return true
}
return false
}
// SetIngressTunAddrInfo gets a reference to the given IngressTunAddrInfo and assigns it to the IngressTunAddrInfo field.
func (o *MbsSessionEventReport) SetIngressTunAddrInfo(v IngressTunAddrInfo) {
o.IngressTunAddrInfo = &v
}
// GetBroadcastDelStatus returns the BroadcastDelStatus field value if set, zero value otherwise.
func (o *MbsSessionEventReport) GetBroadcastDelStatus() BroadcastDeliveryStatus {
if o == nil || IsNil(o.BroadcastDelStatus) {
var ret BroadcastDeliveryStatus
return ret
}
return *o.BroadcastDelStatus
}
// GetBroadcastDelStatusOk returns a tuple with the BroadcastDelStatus field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *MbsSessionEventReport) GetBroadcastDelStatusOk() (*BroadcastDeliveryStatus, bool) {
if o == nil || IsNil(o.BroadcastDelStatus) {
return nil, false
}
return o.BroadcastDelStatus, true
}
// HasBroadcastDelStatus returns a boolean if a field has been set.
func (o *MbsSessionEventReport) HasBroadcastDelStatus() bool {
if o != nil && !IsNil(o.BroadcastDelStatus) {
return true
}
return false
}
// SetBroadcastDelStatus gets a reference to the given BroadcastDeliveryStatus and assigns it to the BroadcastDelStatus field.
func (o *MbsSessionEventReport) SetBroadcastDelStatus(v BroadcastDeliveryStatus) {
o.BroadcastDelStatus = &v
}
func (o MbsSessionEventReport) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o MbsSessionEventReport) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
toSerialize["eventType"] = o.EventType
if !IsNil(o.TimeStamp) {
toSerialize["timeStamp"] = o.TimeStamp
}
if !IsNil(o.IngressTunAddrInfo) {
toSerialize["ingressTunAddrInfo"] = o.IngressTunAddrInfo
}
if !IsNil(o.BroadcastDelStatus) {
toSerialize["broadcastDelStatus"] = o.BroadcastDelStatus
}
return toSerialize, nil
}
func (o *MbsSessionEventReport) 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{
"eventType",
}
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)
}
}
varMbsSessionEventReport := _MbsSessionEventReport{}
err = json.Unmarshal(bytes, &varMbsSessionEventReport)
if err != nil {
return err
}
*o = MbsSessionEventReport(varMbsSessionEventReport)
return err
}
type NullableMbsSessionEventReport struct {
value *MbsSessionEventReport
isSet bool
}
func (v NullableMbsSessionEventReport) Get() *MbsSessionEventReport {
return v.value
}
func (v *NullableMbsSessionEventReport) Set(val *MbsSessionEventReport) {
v.value = val
v.isSet = true
}
func (v NullableMbsSessionEventReport) IsSet() bool {
return v.isSet
}
func (v *NullableMbsSessionEventReport) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableMbsSessionEventReport(val *MbsSessionEventReport) *NullableMbsSessionEventReport {
return &NullableMbsSessionEventReport{value: val, isSet: true}
}
func (v NullableMbsSessionEventReport) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableMbsSessionEventReport) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。