From 68b0d50ec7f34ebb89c47be8a98f689b819cc8f4 Mon Sep 17 00:00:00 2001 From: github-actions Date: Thu, 22 Aug 2024 06:36:51 +0000 Subject: [PATCH] Generated v1.0.0-beta.34 --- CHANGELOG.md | 7 +++++ README.md | 2 +- docs/BillingResponseLineItem.md | 12 +++++++- docs/LineItemData.md | 12 +++++++- fastly/configuration.go | 2 +- fastly/model_billing_response_line_item.go | 32 ++++++++++++++-------- fastly/model_line_item_data.go | 32 ++++++++++++++-------- sig.json | 2 +- 8 files changed, 74 insertions(+), 27 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ef3657d..988d058 100755 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [v1.0.0-beta.34](https://github.com/fastly/fastly-go/releases/tag/release/v1.0.0-beta.34) (2024-08-21) + +**Bug fixes:** + +- bugfix(py): Add dependencies to pyproject.toml. +- fix(billing): make rate-per-unit nullable + ## [v1.0.0-beta.33](https://github.com/fastly/fastly-go/releases/tag/release/v1.0.0-beta.33) (2024-08-08) **Bug fixes:** diff --git a/README.md b/README.md index be7e690..77e69e7 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ Add the following to your project's `go.mod`: ```go.mod require ( - github.com/fastly/fastly-go 1.0.0-beta.33 + github.com/fastly/fastly-go 1.0.0-beta.34 ) ``` diff --git a/docs/BillingResponseLineItem.md b/docs/BillingResponseLineItem.md index 350e1ed..689e766 100644 --- a/docs/BillingResponseLineItem.md +++ b/docs/BillingResponseLineItem.md @@ -16,7 +16,7 @@ Name | Type | Description | Notes **LineNumber** | Pointer to **int32** | | [optional] **PlanName** | Pointer to **string** | | [optional] **PlanNo** | Pointer to **float32** | | [optional] -**RatePerUnit** | Pointer to **float32** | | [optional] +**RatePerUnit** | Pointer to **NullableFloat32** | | [optional] **RateScheduleNo** | Pointer to **NullableFloat32** | | [optional] **RateScheduleTierNo** | Pointer to **NullableFloat32** | | [optional] **ServiceName** | Pointer to **string** | | [optional] @@ -409,6 +409,16 @@ SetRatePerUnit sets RatePerUnit field to given value. HasRatePerUnit returns a boolean if a field has been set. +### SetRatePerUnitNil + +`func (o *BillingResponseLineItem) SetRatePerUnitNil(b bool)` + + SetRatePerUnitNil sets the value for RatePerUnit to be an explicit nil + +### UnsetRatePerUnit +`func (o *BillingResponseLineItem) UnsetRatePerUnit()` + +UnsetRatePerUnit ensures that no value is present for RatePerUnit, not even an explicit nil ### GetRateScheduleNo `func (o *BillingResponseLineItem) GetRateScheduleNo() float32` diff --git a/docs/LineItemData.md b/docs/LineItemData.md index 5377ba4..4ce5201 100644 --- a/docs/LineItemData.md +++ b/docs/LineItemData.md @@ -13,7 +13,7 @@ Name | Type | Description | Notes **LineNumber** | Pointer to **int32** | | [optional] **PlanName** | Pointer to **string** | | [optional] **PlanNo** | Pointer to **float32** | | [optional] -**RatePerUnit** | Pointer to **float32** | | [optional] +**RatePerUnit** | Pointer to **NullableFloat32** | | [optional] **RateScheduleNo** | Pointer to **NullableFloat32** | | [optional] **RateScheduleTierNo** | Pointer to **NullableFloat32** | | [optional] **ServiceName** | Pointer to **string** | | [optional] @@ -301,6 +301,16 @@ SetRatePerUnit sets RatePerUnit field to given value. HasRatePerUnit returns a boolean if a field has been set. +### SetRatePerUnitNil + +`func (o *LineItemData) SetRatePerUnitNil(b bool)` + + SetRatePerUnitNil sets the value for RatePerUnit to be an explicit nil + +### UnsetRatePerUnit +`func (o *LineItemData) UnsetRatePerUnit()` + +UnsetRatePerUnit ensures that no value is present for RatePerUnit, not even an explicit nil ### GetRateScheduleNo `func (o *LineItemData) GetRateScheduleNo() float32` diff --git a/fastly/configuration.go b/fastly/configuration.go index 300f593..3f3dfbb 100644 --- a/fastly/configuration.go +++ b/fastly/configuration.go @@ -105,7 +105,7 @@ type Configuration struct { func NewConfiguration() *Configuration { cfg := &Configuration{ DefaultHeader: make(map[string]string), - UserAgent: "fastly-go/1.0.0-beta.33", + UserAgent: "fastly-go/1.0.0-beta.34", Debug: false, Servers: ServerConfigurations{ { diff --git a/fastly/model_billing_response_line_item.go b/fastly/model_billing_response_line_item.go index 118071d..4792639 100644 --- a/fastly/model_billing_response_line_item.go +++ b/fastly/model_billing_response_line_item.go @@ -36,7 +36,7 @@ type BillingResponseLineItem struct { LineNumber *int32 `json:"line_number,omitempty"` PlanName *string `json:"plan_name,omitempty"` PlanNo *float32 `json:"plan_no,omitempty"` - RatePerUnit *float32 `json:"rate_per_unit,omitempty"` + RatePerUnit NullableFloat32 `json:"rate_per_unit,omitempty"` RateScheduleNo NullableFloat32 `json:"rate_schedule_no,omitempty"` RateScheduleTierNo NullableFloat32 `json:"rate_schedule_tier_no,omitempty"` ServiceName *string `json:"service_name,omitempty"` @@ -490,36 +490,46 @@ func (o *BillingResponseLineItem) SetPlanNo(v float32) { o.PlanNo = &v } -// GetRatePerUnit returns the RatePerUnit field value if set, zero value otherwise. +// GetRatePerUnit returns the RatePerUnit field value if set, zero value otherwise (both if not set or set to explicit null). func (o *BillingResponseLineItem) GetRatePerUnit() float32 { - if o == nil || o.RatePerUnit == nil { + if o == nil || o.RatePerUnit.Get() == nil { var ret float32 return ret } - return *o.RatePerUnit + return *o.RatePerUnit.Get() } // GetRatePerUnitOk returns a tuple with the RatePerUnit field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *BillingResponseLineItem) GetRatePerUnitOk() (*float32, bool) { - if o == nil || o.RatePerUnit == nil { + if o == nil { return nil, false } - return o.RatePerUnit, true + return o.RatePerUnit.Get(), o.RatePerUnit.IsSet() } // HasRatePerUnit returns a boolean if a field has been set. func (o *BillingResponseLineItem) HasRatePerUnit() bool { - if o != nil && o.RatePerUnit != nil { + if o != nil && o.RatePerUnit.IsSet() { return true } return false } -// SetRatePerUnit gets a reference to the given float32 and assigns it to the RatePerUnit field. +// SetRatePerUnit gets a reference to the given NullableFloat32 and assigns it to the RatePerUnit field. func (o *BillingResponseLineItem) SetRatePerUnit(v float32) { - o.RatePerUnit = &v + o.RatePerUnit.Set(&v) +} +// SetRatePerUnitNil sets the value for RatePerUnit to be an explicit nil +func (o *BillingResponseLineItem) SetRatePerUnitNil() { + o.RatePerUnit.Set(nil) +} + +// UnsetRatePerUnit ensures that no value is present for RatePerUnit, not even an explicit nil +func (o *BillingResponseLineItem) UnsetRatePerUnit() { + o.RatePerUnit.Unset() } // GetRateScheduleNo returns the RateScheduleNo field value if set, zero value otherwise (both if not set or set to explicit null). @@ -826,8 +836,8 @@ func (o BillingResponseLineItem) MarshalJSON() ([]byte, error) { if o.PlanNo != nil { toSerialize["plan_no"] = o.PlanNo } - if o.RatePerUnit != nil { - toSerialize["rate_per_unit"] = o.RatePerUnit + if o.RatePerUnit.IsSet() { + toSerialize["rate_per_unit"] = o.RatePerUnit.Get() } if o.RateScheduleNo.IsSet() { toSerialize["rate_schedule_no"] = o.RateScheduleNo.Get() diff --git a/fastly/model_line_item_data.go b/fastly/model_line_item_data.go index df2a37e..1976648 100644 --- a/fastly/model_line_item_data.go +++ b/fastly/model_line_item_data.go @@ -29,7 +29,7 @@ type LineItemData struct { LineNumber *int32 `json:"line_number,omitempty"` PlanName *string `json:"plan_name,omitempty"` PlanNo *float32 `json:"plan_no,omitempty"` - RatePerUnit *float32 `json:"rate_per_unit,omitempty"` + RatePerUnit NullableFloat32 `json:"rate_per_unit,omitempty"` RateScheduleNo NullableFloat32 `json:"rate_schedule_no,omitempty"` RateScheduleTierNo NullableFloat32 `json:"rate_schedule_tier_no,omitempty"` ServiceName *string `json:"service_name,omitempty"` @@ -357,36 +357,46 @@ func (o *LineItemData) SetPlanNo(v float32) { o.PlanNo = &v } -// GetRatePerUnit returns the RatePerUnit field value if set, zero value otherwise. +// GetRatePerUnit returns the RatePerUnit field value if set, zero value otherwise (both if not set or set to explicit null). func (o *LineItemData) GetRatePerUnit() float32 { - if o == nil || o.RatePerUnit == nil { + if o == nil || o.RatePerUnit.Get() == nil { var ret float32 return ret } - return *o.RatePerUnit + return *o.RatePerUnit.Get() } // GetRatePerUnitOk returns a tuple with the RatePerUnit field value if set, nil otherwise // and a boolean to check if the value has been set. +// NOTE: If the value is an explicit nil, `nil, true` will be returned func (o *LineItemData) GetRatePerUnitOk() (*float32, bool) { - if o == nil || o.RatePerUnit == nil { + if o == nil { return nil, false } - return o.RatePerUnit, true + return o.RatePerUnit.Get(), o.RatePerUnit.IsSet() } // HasRatePerUnit returns a boolean if a field has been set. func (o *LineItemData) HasRatePerUnit() bool { - if o != nil && o.RatePerUnit != nil { + if o != nil && o.RatePerUnit.IsSet() { return true } return false } -// SetRatePerUnit gets a reference to the given float32 and assigns it to the RatePerUnit field. +// SetRatePerUnit gets a reference to the given NullableFloat32 and assigns it to the RatePerUnit field. func (o *LineItemData) SetRatePerUnit(v float32) { - o.RatePerUnit = &v + o.RatePerUnit.Set(&v) +} +// SetRatePerUnitNil sets the value for RatePerUnit to be an explicit nil +func (o *LineItemData) SetRatePerUnitNil() { + o.RatePerUnit.Set(nil) +} + +// UnsetRatePerUnit ensures that no value is present for RatePerUnit, not even an explicit nil +func (o *LineItemData) UnsetRatePerUnit() { + o.RatePerUnit.Unset() } // GetRateScheduleNo returns the RateScheduleNo field value if set, zero value otherwise (both if not set or set to explicit null). @@ -684,8 +694,8 @@ func (o LineItemData) MarshalJSON() ([]byte, error) { if o.PlanNo != nil { toSerialize["plan_no"] = o.PlanNo } - if o.RatePerUnit != nil { - toSerialize["rate_per_unit"] = o.RatePerUnit + if o.RatePerUnit.IsSet() { + toSerialize["rate_per_unit"] = o.RatePerUnit.Get() } if o.RateScheduleNo.IsSet() { toSerialize["rate_schedule_no"] = o.RateScheduleNo.Get() diff --git a/sig.json b/sig.json index 67771c6..442b4f5 100644 --- a/sig.json +++ b/sig.json @@ -1 +1 @@ -{"G": "01161630", "D": "80b361d0"} +{"G": "6c487eff", "D": "8fce7d1c"}