1 Star 0 Fork 0

MrCoder/openapi

Create your Gitee Account
Explore and code with more than 13.5 million developers,Free private repositories !:)
Sign up
文件
Clone or Download
model_pc_event_exposure_subsc.go 14.95 KB
Copy Edit Raw Blame History
MrCoder authored 2023-12-22 15:27 +08:00 . update
/*
Npcf_EventExposure
PCF Event Exposure Service. © 2022, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
API version: 1.2.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package OpenAPI_Npcf_EventExposure
import (
"encoding/json"
"fmt"
)
// checks if the PcEventExposureSubsc type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &PcEventExposureSubsc{}
// PcEventExposureSubsc Represents an Individual Policy Events Subscription resource.
type PcEventExposureSubsc struct {
EventSubs []PcEvent `json:"eventSubs"`
EventsRepInfo *ReportingInformation `json:"eventsRepInfo,omitempty"`
// String identifying a group of devices network internal globally unique ID which identifies a set of IMSIs, as specified in clause 19.9 of 3GPP TS 23.003.
GroupId *string `json:"groupId,omitempty"`
FilterDnns []string `json:"filterDnns,omitempty"`
FilterSnssais []Snssai `json:"filterSnssais,omitempty"`
SnssaiDnns []SnssaiDnnCombination `json:"snssaiDnns,omitempty"`
FilterServices []ServiceIdentification `json:"filterServices,omitempty"`
// String providing an URI formatted according to RFC 3986.
NotifUri string `json:"notifUri"`
NotifId string `json:"notifId"`
EventNotifs []PcEventNotification `json:"eventNotifs,omitempty"`
// A string used to indicate the features supported by an API that is used as defined in clause 6.6 in 3GPP TS 29.500. The string shall contain a bitmask indicating supported features in hexadecimal representation Each character in the string shall take a value of \"0\" to \"9\", \"a\" to \"f\" or \"A\" to \"F\" and shall represent the support of 4 features as described in table 5.2.2-3. The most significant character representing the highest-numbered features shall appear first in the string, and the character representing features 1 to 4 shall appear last in the string. The list of features and their numbering (starting with 1) are defined separately for each API. If the string contains a lower number of characters than there are defined features for an API, all features that would be represented by characters that are not present in the string are not supported.
SuppFeat *string `json:"suppFeat,omitempty"`
}
type _PcEventExposureSubsc PcEventExposureSubsc
// NewPcEventExposureSubsc instantiates a new PcEventExposureSubsc 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 NewPcEventExposureSubsc(eventSubs []PcEvent, notifUri string, notifId string) *PcEventExposureSubsc {
this := PcEventExposureSubsc{}
this.EventSubs = eventSubs
this.NotifUri = notifUri
this.NotifId = notifId
return &this
}
// NewPcEventExposureSubscWithDefaults instantiates a new PcEventExposureSubsc 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 NewPcEventExposureSubscWithDefaults() *PcEventExposureSubsc {
this := PcEventExposureSubsc{}
return &this
}
// GetEventSubs returns the EventSubs field value
func (o *PcEventExposureSubsc) GetEventSubs() []PcEvent {
if o == nil {
var ret []PcEvent
return ret
}
return o.EventSubs
}
// GetEventSubsOk returns a tuple with the EventSubs field value
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetEventSubsOk() ([]PcEvent, bool) {
if o == nil {
return nil, false
}
return o.EventSubs, true
}
// SetEventSubs sets field value
func (o *PcEventExposureSubsc) SetEventSubs(v []PcEvent) {
o.EventSubs = v
}
// GetEventsRepInfo returns the EventsRepInfo field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetEventsRepInfo() ReportingInformation {
if o == nil || IsNil(o.EventsRepInfo) {
var ret ReportingInformation
return ret
}
return *o.EventsRepInfo
}
// GetEventsRepInfoOk returns a tuple with the EventsRepInfo field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetEventsRepInfoOk() (*ReportingInformation, bool) {
if o == nil || IsNil(o.EventsRepInfo) {
return nil, false
}
return o.EventsRepInfo, true
}
// HasEventsRepInfo returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasEventsRepInfo() bool {
if o != nil && !IsNil(o.EventsRepInfo) {
return true
}
return false
}
// SetEventsRepInfo gets a reference to the given ReportingInformation and assigns it to the EventsRepInfo field.
func (o *PcEventExposureSubsc) SetEventsRepInfo(v ReportingInformation) {
o.EventsRepInfo = &v
}
// GetGroupId returns the GroupId field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetGroupId() string {
if o == nil || IsNil(o.GroupId) {
var ret string
return ret
}
return *o.GroupId
}
// GetGroupIdOk returns a tuple with the GroupId field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetGroupIdOk() (*string, bool) {
if o == nil || IsNil(o.GroupId) {
return nil, false
}
return o.GroupId, true
}
// HasGroupId returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasGroupId() bool {
if o != nil && !IsNil(o.GroupId) {
return true
}
return false
}
// SetGroupId gets a reference to the given string and assigns it to the GroupId field.
func (o *PcEventExposureSubsc) SetGroupId(v string) {
o.GroupId = &v
}
// GetFilterDnns returns the FilterDnns field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetFilterDnns() []string {
if o == nil || IsNil(o.FilterDnns) {
var ret []string
return ret
}
return o.FilterDnns
}
// GetFilterDnnsOk returns a tuple with the FilterDnns field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetFilterDnnsOk() ([]string, bool) {
if o == nil || IsNil(o.FilterDnns) {
return nil, false
}
return o.FilterDnns, true
}
// HasFilterDnns returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasFilterDnns() bool {
if o != nil && !IsNil(o.FilterDnns) {
return true
}
return false
}
// SetFilterDnns gets a reference to the given []string and assigns it to the FilterDnns field.
func (o *PcEventExposureSubsc) SetFilterDnns(v []string) {
o.FilterDnns = v
}
// GetFilterSnssais returns the FilterSnssais field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetFilterSnssais() []Snssai {
if o == nil || IsNil(o.FilterSnssais) {
var ret []Snssai
return ret
}
return o.FilterSnssais
}
// GetFilterSnssaisOk returns a tuple with the FilterSnssais field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetFilterSnssaisOk() ([]Snssai, bool) {
if o == nil || IsNil(o.FilterSnssais) {
return nil, false
}
return o.FilterSnssais, true
}
// HasFilterSnssais returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasFilterSnssais() bool {
if o != nil && !IsNil(o.FilterSnssais) {
return true
}
return false
}
// SetFilterSnssais gets a reference to the given []Snssai and assigns it to the FilterSnssais field.
func (o *PcEventExposureSubsc) SetFilterSnssais(v []Snssai) {
o.FilterSnssais = v
}
// GetSnssaiDnns returns the SnssaiDnns field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetSnssaiDnns() []SnssaiDnnCombination {
if o == nil || IsNil(o.SnssaiDnns) {
var ret []SnssaiDnnCombination
return ret
}
return o.SnssaiDnns
}
// GetSnssaiDnnsOk returns a tuple with the SnssaiDnns field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetSnssaiDnnsOk() ([]SnssaiDnnCombination, bool) {
if o == nil || IsNil(o.SnssaiDnns) {
return nil, false
}
return o.SnssaiDnns, true
}
// HasSnssaiDnns returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasSnssaiDnns() bool {
if o != nil && !IsNil(o.SnssaiDnns) {
return true
}
return false
}
// SetSnssaiDnns gets a reference to the given []SnssaiDnnCombination and assigns it to the SnssaiDnns field.
func (o *PcEventExposureSubsc) SetSnssaiDnns(v []SnssaiDnnCombination) {
o.SnssaiDnns = v
}
// GetFilterServices returns the FilterServices field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetFilterServices() []ServiceIdentification {
if o == nil || IsNil(o.FilterServices) {
var ret []ServiceIdentification
return ret
}
return o.FilterServices
}
// GetFilterServicesOk returns a tuple with the FilterServices field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetFilterServicesOk() ([]ServiceIdentification, bool) {
if o == nil || IsNil(o.FilterServices) {
return nil, false
}
return o.FilterServices, true
}
// HasFilterServices returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasFilterServices() bool {
if o != nil && !IsNil(o.FilterServices) {
return true
}
return false
}
// SetFilterServices gets a reference to the given []ServiceIdentification and assigns it to the FilterServices field.
func (o *PcEventExposureSubsc) SetFilterServices(v []ServiceIdentification) {
o.FilterServices = v
}
// GetNotifUri returns the NotifUri field value
func (o *PcEventExposureSubsc) GetNotifUri() string {
if o == nil {
var ret string
return ret
}
return o.NotifUri
}
// GetNotifUriOk returns a tuple with the NotifUri field value
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetNotifUriOk() (*string, bool) {
if o == nil {
return nil, false
}
return &o.NotifUri, true
}
// SetNotifUri sets field value
func (o *PcEventExposureSubsc) SetNotifUri(v string) {
o.NotifUri = v
}
// GetNotifId returns the NotifId field value
func (o *PcEventExposureSubsc) GetNotifId() string {
if o == nil {
var ret string
return ret
}
return o.NotifId
}
// GetNotifIdOk returns a tuple with the NotifId field value
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetNotifIdOk() (*string, bool) {
if o == nil {
return nil, false
}
return &o.NotifId, true
}
// SetNotifId sets field value
func (o *PcEventExposureSubsc) SetNotifId(v string) {
o.NotifId = v
}
// GetEventNotifs returns the EventNotifs field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetEventNotifs() []PcEventNotification {
if o == nil || IsNil(o.EventNotifs) {
var ret []PcEventNotification
return ret
}
return o.EventNotifs
}
// GetEventNotifsOk returns a tuple with the EventNotifs field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetEventNotifsOk() ([]PcEventNotification, bool) {
if o == nil || IsNil(o.EventNotifs) {
return nil, false
}
return o.EventNotifs, true
}
// HasEventNotifs returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasEventNotifs() bool {
if o != nil && !IsNil(o.EventNotifs) {
return true
}
return false
}
// SetEventNotifs gets a reference to the given []PcEventNotification and assigns it to the EventNotifs field.
func (o *PcEventExposureSubsc) SetEventNotifs(v []PcEventNotification) {
o.EventNotifs = v
}
// GetSuppFeat returns the SuppFeat field value if set, zero value otherwise.
func (o *PcEventExposureSubsc) GetSuppFeat() string {
if o == nil || IsNil(o.SuppFeat) {
var ret string
return ret
}
return *o.SuppFeat
}
// GetSuppFeatOk returns a tuple with the SuppFeat field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *PcEventExposureSubsc) GetSuppFeatOk() (*string, bool) {
if o == nil || IsNil(o.SuppFeat) {
return nil, false
}
return o.SuppFeat, true
}
// HasSuppFeat returns a boolean if a field has been set.
func (o *PcEventExposureSubsc) HasSuppFeat() bool {
if o != nil && !IsNil(o.SuppFeat) {
return true
}
return false
}
// SetSuppFeat gets a reference to the given string and assigns it to the SuppFeat field.
func (o *PcEventExposureSubsc) SetSuppFeat(v string) {
o.SuppFeat = &v
}
func (o PcEventExposureSubsc) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o PcEventExposureSubsc) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
toSerialize["eventSubs"] = o.EventSubs
if !IsNil(o.EventsRepInfo) {
toSerialize["eventsRepInfo"] = o.EventsRepInfo
}
if !IsNil(o.GroupId) {
toSerialize["groupId"] = o.GroupId
}
if !IsNil(o.FilterDnns) {
toSerialize["filterDnns"] = o.FilterDnns
}
if !IsNil(o.FilterSnssais) {
toSerialize["filterSnssais"] = o.FilterSnssais
}
if !IsNil(o.SnssaiDnns) {
toSerialize["snssaiDnns"] = o.SnssaiDnns
}
if !IsNil(o.FilterServices) {
toSerialize["filterServices"] = o.FilterServices
}
toSerialize["notifUri"] = o.NotifUri
toSerialize["notifId"] = o.NotifId
if !IsNil(o.EventNotifs) {
toSerialize["eventNotifs"] = o.EventNotifs
}
if !IsNil(o.SuppFeat) {
toSerialize["suppFeat"] = o.SuppFeat
}
return toSerialize, nil
}
func (o *PcEventExposureSubsc) 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{
"eventSubs",
"notifUri",
"notifId",
}
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)
}
}
varPcEventExposureSubsc := _PcEventExposureSubsc{}
err = json.Unmarshal(bytes, &varPcEventExposureSubsc)
if err != nil {
return err
}
*o = PcEventExposureSubsc(varPcEventExposureSubsc)
return err
}
type NullablePcEventExposureSubsc struct {
value *PcEventExposureSubsc
isSet bool
}
func (v NullablePcEventExposureSubsc) Get() *PcEventExposureSubsc {
return v.value
}
func (v *NullablePcEventExposureSubsc) Set(val *PcEventExposureSubsc) {
v.value = val
v.isSet = true
}
func (v NullablePcEventExposureSubsc) IsSet() bool {
return v.isSet
}
func (v *NullablePcEventExposureSubsc) Unset() {
v.value = nil
v.isSet = false
}
func NewNullablePcEventExposureSubsc(val *PcEventExposureSubsc) *NullablePcEventExposureSubsc {
return &NullablePcEventExposureSubsc{value: val, isSet: true}
}
func (v NullablePcEventExposureSubsc) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullablePcEventExposureSubsc) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/konglinglong/openapi.git
git@gitee.com:konglinglong/openapi.git
konglinglong
openapi
openapi
e403a3c726a4

Search