1 Star 0 Fork 0

MrCoder / openapi

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
model_subscription.go 5.16 KB
一键复制 编辑 原始数据 按行查看 历史
MrCoder 提交于 2023-12-22 15:27 . update
/*
Fault Supervision MnS
OAS 3.0.1 definition of the Fault Supervision MnS © 2023, 3GPP Organizational Partners (ARIB, ATIS, CCSA, ETSI, TSDSI, TTA, TTC). All rights reserved.
API version: 17.3.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package OpenAPI_FaultMnS
import (
"encoding/json"
)
// checks if the Subscription type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &Subscription{}
// Subscription struct for Subscription
type Subscription struct {
ConsumerReference *string `json:"consumerReference,omitempty"`
TimeTick *int32 `json:"timeTick,omitempty"`
// The filter format shall be compliant to XPath 1.0.
Filter *string `json:"filter,omitempty"`
}
// NewSubscription instantiates a new Subscription 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 NewSubscription() *Subscription {
this := Subscription{}
return &this
}
// NewSubscriptionWithDefaults instantiates a new Subscription 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 NewSubscriptionWithDefaults() *Subscription {
this := Subscription{}
return &this
}
// GetConsumerReference returns the ConsumerReference field value if set, zero value otherwise.
func (o *Subscription) GetConsumerReference() string {
if o == nil || IsNil(o.ConsumerReference) {
var ret string
return ret
}
return *o.ConsumerReference
}
// GetConsumerReferenceOk returns a tuple with the ConsumerReference field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Subscription) GetConsumerReferenceOk() (*string, bool) {
if o == nil || IsNil(o.ConsumerReference) {
return nil, false
}
return o.ConsumerReference, true
}
// HasConsumerReference returns a boolean if a field has been set.
func (o *Subscription) HasConsumerReference() bool {
if o != nil && !IsNil(o.ConsumerReference) {
return true
}
return false
}
// SetConsumerReference gets a reference to the given string and assigns it to the ConsumerReference field.
func (o *Subscription) SetConsumerReference(v string) {
o.ConsumerReference = &v
}
// GetTimeTick returns the TimeTick field value if set, zero value otherwise.
func (o *Subscription) GetTimeTick() int32 {
if o == nil || IsNil(o.TimeTick) {
var ret int32
return ret
}
return *o.TimeTick
}
// GetTimeTickOk returns a tuple with the TimeTick field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Subscription) GetTimeTickOk() (*int32, bool) {
if o == nil || IsNil(o.TimeTick) {
return nil, false
}
return o.TimeTick, true
}
// HasTimeTick returns a boolean if a field has been set.
func (o *Subscription) HasTimeTick() bool {
if o != nil && !IsNil(o.TimeTick) {
return true
}
return false
}
// SetTimeTick gets a reference to the given int32 and assigns it to the TimeTick field.
func (o *Subscription) SetTimeTick(v int32) {
o.TimeTick = &v
}
// GetFilter returns the Filter field value if set, zero value otherwise.
func (o *Subscription) GetFilter() string {
if o == nil || IsNil(o.Filter) {
var ret string
return ret
}
return *o.Filter
}
// GetFilterOk returns a tuple with the Filter field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *Subscription) GetFilterOk() (*string, bool) {
if o == nil || IsNil(o.Filter) {
return nil, false
}
return o.Filter, true
}
// HasFilter returns a boolean if a field has been set.
func (o *Subscription) HasFilter() bool {
if o != nil && !IsNil(o.Filter) {
return true
}
return false
}
// SetFilter gets a reference to the given string and assigns it to the Filter field.
func (o *Subscription) SetFilter(v string) {
o.Filter = &v
}
func (o Subscription) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o Subscription) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.ConsumerReference) {
toSerialize["consumerReference"] = o.ConsumerReference
}
if !IsNil(o.TimeTick) {
toSerialize["timeTick"] = o.TimeTick
}
if !IsNil(o.Filter) {
toSerialize["filter"] = o.Filter
}
return toSerialize, nil
}
type NullableSubscription struct {
value *Subscription
isSet bool
}
func (v NullableSubscription) Get() *Subscription {
return v.value
}
func (v *NullableSubscription) Set(val *Subscription) {
v.value = val
v.isSet = true
}
func (v NullableSubscription) IsSet() bool {
return v.isSet
}
func (v *NullableSubscription) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableSubscription(val *Subscription) *NullableSubscription {
return &NullableSubscription{value: val, isSet: true}
}
func (v NullableSubscription) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableSubscription) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}
Go
1
https://gitee.com/konglinglong/openapi.git
git@gitee.com:konglinglong/openapi.git
konglinglong
openapi
openapi
e403a3c726a4

搜索帮助