/* * Subset of Influx API covered by Influx CLI * * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * API version: 2.0.0 */ // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. package api import ( "encoding/json" ) // TemplateSummaryNotificationRule struct for TemplateSummaryNotificationRule type TemplateSummaryNotificationRule struct { Kind string `json:"kind" yaml:"kind"` TemplateMetaName string `json:"templateMetaName" yaml:"templateMetaName"` EnvReferences []TemplateEnvReference `json:"envReferences" yaml:"envReferences"` LabelAssociations []TemplateSummaryLabel `json:"labelAssociations" yaml:"labelAssociations"` Id uint64 `json:"id" yaml:"id"` Name string `json:"name" yaml:"name"` Description *string `json:"description,omitempty" yaml:"description,omitempty"` EndpointTemplateMetaName string `json:"endpointTemplateMetaName" yaml:"endpointTemplateMetaName"` EndpointID uint64 `json:"endpointID" yaml:"endpointID"` EndpointType string `json:"endpointType" yaml:"endpointType"` Every string `json:"every" yaml:"every"` Offset string `json:"offset" yaml:"offset"` } // NewTemplateSummaryNotificationRule instantiates a new TemplateSummaryNotificationRule 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 NewTemplateSummaryNotificationRule(kind string, templateMetaName string, envReferences []TemplateEnvReference, labelAssociations []TemplateSummaryLabel, id uint64, name string, endpointTemplateMetaName string, endpointID uint64, endpointType string, every string, offset string) *TemplateSummaryNotificationRule { this := TemplateSummaryNotificationRule{} this.Kind = kind this.TemplateMetaName = templateMetaName this.EnvReferences = envReferences this.LabelAssociations = labelAssociations this.Id = id this.Name = name this.EndpointTemplateMetaName = endpointTemplateMetaName this.EndpointID = endpointID this.EndpointType = endpointType this.Every = every this.Offset = offset return &this } // NewTemplateSummaryNotificationRuleWithDefaults instantiates a new TemplateSummaryNotificationRule 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 NewTemplateSummaryNotificationRuleWithDefaults() *TemplateSummaryNotificationRule { this := TemplateSummaryNotificationRule{} return &this } // GetKind returns the Kind field value func (o *TemplateSummaryNotificationRule) GetKind() string { if o == nil { var ret string return ret } return o.Kind } // GetKindOk returns a tuple with the Kind field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetKindOk() (*string, bool) { if o == nil { return nil, false } return &o.Kind, true } // SetKind sets field value func (o *TemplateSummaryNotificationRule) SetKind(v string) { o.Kind = v } // GetTemplateMetaName returns the TemplateMetaName field value func (o *TemplateSummaryNotificationRule) GetTemplateMetaName() string { if o == nil { var ret string return ret } return o.TemplateMetaName } // GetTemplateMetaNameOk returns a tuple with the TemplateMetaName field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetTemplateMetaNameOk() (*string, bool) { if o == nil { return nil, false } return &o.TemplateMetaName, true } // SetTemplateMetaName sets field value func (o *TemplateSummaryNotificationRule) SetTemplateMetaName(v string) { o.TemplateMetaName = v } // GetEnvReferences returns the EnvReferences field value func (o *TemplateSummaryNotificationRule) GetEnvReferences() []TemplateEnvReference { if o == nil { var ret []TemplateEnvReference return ret } return o.EnvReferences } // GetEnvReferencesOk returns a tuple with the EnvReferences field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetEnvReferencesOk() (*[]TemplateEnvReference, bool) { if o == nil { return nil, false } return &o.EnvReferences, true } // SetEnvReferences sets field value func (o *TemplateSummaryNotificationRule) SetEnvReferences(v []TemplateEnvReference) { o.EnvReferences = v } // GetLabelAssociations returns the LabelAssociations field value func (o *TemplateSummaryNotificationRule) GetLabelAssociations() []TemplateSummaryLabel { if o == nil { var ret []TemplateSummaryLabel return ret } return o.LabelAssociations } // GetLabelAssociationsOk returns a tuple with the LabelAssociations field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetLabelAssociationsOk() (*[]TemplateSummaryLabel, bool) { if o == nil { return nil, false } return &o.LabelAssociations, true } // SetLabelAssociations sets field value func (o *TemplateSummaryNotificationRule) SetLabelAssociations(v []TemplateSummaryLabel) { o.LabelAssociations = v } // GetId returns the Id field value func (o *TemplateSummaryNotificationRule) GetId() uint64 { if o == nil { var ret uint64 return ret } return o.Id } // GetIdOk returns a tuple with the Id field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetIdOk() (*uint64, bool) { if o == nil { return nil, false } return &o.Id, true } // SetId sets field value func (o *TemplateSummaryNotificationRule) SetId(v uint64) { o.Id = v } // GetName returns the Name field value func (o *TemplateSummaryNotificationRule) GetName() string { if o == nil { var ret string return ret } return o.Name } // GetNameOk returns a tuple with the Name field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetNameOk() (*string, bool) { if o == nil { return nil, false } return &o.Name, true } // SetName sets field value func (o *TemplateSummaryNotificationRule) SetName(v string) { o.Name = v } // GetDescription returns the Description field value if set, zero value otherwise. func (o *TemplateSummaryNotificationRule) GetDescription() string { if o == nil || o.Description == nil { var ret string return ret } return *o.Description } // GetDescriptionOk returns a tuple with the Description field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetDescriptionOk() (*string, bool) { if o == nil || o.Description == nil { return nil, false } return o.Description, true } // HasDescription returns a boolean if a field has been set. func (o *TemplateSummaryNotificationRule) HasDescription() bool { if o != nil && o.Description != nil { return true } return false } // SetDescription gets a reference to the given string and assigns it to the Description field. func (o *TemplateSummaryNotificationRule) SetDescription(v string) { o.Description = &v } // GetEndpointTemplateMetaName returns the EndpointTemplateMetaName field value func (o *TemplateSummaryNotificationRule) GetEndpointTemplateMetaName() string { if o == nil { var ret string return ret } return o.EndpointTemplateMetaName } // GetEndpointTemplateMetaNameOk returns a tuple with the EndpointTemplateMetaName field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetEndpointTemplateMetaNameOk() (*string, bool) { if o == nil { return nil, false } return &o.EndpointTemplateMetaName, true } // SetEndpointTemplateMetaName sets field value func (o *TemplateSummaryNotificationRule) SetEndpointTemplateMetaName(v string) { o.EndpointTemplateMetaName = v } // GetEndpointID returns the EndpointID field value func (o *TemplateSummaryNotificationRule) GetEndpointID() uint64 { if o == nil { var ret uint64 return ret } return o.EndpointID } // GetEndpointIDOk returns a tuple with the EndpointID field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetEndpointIDOk() (*uint64, bool) { if o == nil { return nil, false } return &o.EndpointID, true } // SetEndpointID sets field value func (o *TemplateSummaryNotificationRule) SetEndpointID(v uint64) { o.EndpointID = v } // GetEndpointType returns the EndpointType field value func (o *TemplateSummaryNotificationRule) GetEndpointType() string { if o == nil { var ret string return ret } return o.EndpointType } // GetEndpointTypeOk returns a tuple with the EndpointType field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetEndpointTypeOk() (*string, bool) { if o == nil { return nil, false } return &o.EndpointType, true } // SetEndpointType sets field value func (o *TemplateSummaryNotificationRule) SetEndpointType(v string) { o.EndpointType = v } // GetEvery returns the Every field value func (o *TemplateSummaryNotificationRule) GetEvery() string { if o == nil { var ret string return ret } return o.Every } // GetEveryOk returns a tuple with the Every field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetEveryOk() (*string, bool) { if o == nil { return nil, false } return &o.Every, true } // SetEvery sets field value func (o *TemplateSummaryNotificationRule) SetEvery(v string) { o.Every = v } // GetOffset returns the Offset field value func (o *TemplateSummaryNotificationRule) GetOffset() string { if o == nil { var ret string return ret } return o.Offset } // GetOffsetOk returns a tuple with the Offset field value // and a boolean to check if the value has been set. func (o *TemplateSummaryNotificationRule) GetOffsetOk() (*string, bool) { if o == nil { return nil, false } return &o.Offset, true } // SetOffset sets field value func (o *TemplateSummaryNotificationRule) SetOffset(v string) { o.Offset = v } func (o TemplateSummaryNotificationRule) MarshalJSON() ([]byte, error) { toSerialize := map[string]interface{}{} if true { toSerialize["kind"] = o.Kind } if true { toSerialize["templateMetaName"] = o.TemplateMetaName } if true { toSerialize["envReferences"] = o.EnvReferences } if true { toSerialize["labelAssociations"] = o.LabelAssociations } if true { toSerialize["id"] = o.Id } if true { toSerialize["name"] = o.Name } if o.Description != nil { toSerialize["description"] = o.Description } if true { toSerialize["endpointTemplateMetaName"] = o.EndpointTemplateMetaName } if true { toSerialize["endpointID"] = o.EndpointID } if true { toSerialize["endpointType"] = o.EndpointType } if true { toSerialize["every"] = o.Every } if true { toSerialize["offset"] = o.Offset } return json.Marshal(toSerialize) } type NullableTemplateSummaryNotificationRule struct { value *TemplateSummaryNotificationRule isSet bool } func (v NullableTemplateSummaryNotificationRule) Get() *TemplateSummaryNotificationRule { return v.value } func (v *NullableTemplateSummaryNotificationRule) Set(val *TemplateSummaryNotificationRule) { v.value = val v.isSet = true } func (v NullableTemplateSummaryNotificationRule) IsSet() bool { return v.isSet } func (v *NullableTemplateSummaryNotificationRule) Unset() { v.value = nil v.isSet = false } func NewNullableTemplateSummaryNotificationRule(val *TemplateSummaryNotificationRule) *NullableTemplateSummaryNotificationRule { return &NullableTemplateSummaryNotificationRule{value: val, isSet: true} } func (v NullableTemplateSummaryNotificationRule) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } func (v *NullableTemplateSummaryNotificationRule) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) }