c442eb5bcb
Upgraded openapi generator version to 5.1.0 for the support of nullable values for optional fields; Added missing "Disabled" enum value to the BootSourceOverrideEnabled model in the openapi schema. Signed-off-by: James Gu <james.gu@att.com> Change-Id: Ia3e0b018be13079d2085ef61ed2e797bcfd25fd7
162 lines
4.1 KiB
Go
162 lines
4.1 KiB
Go
/*
|
|
* Redfish OAPI specification
|
|
*
|
|
* Partial Redfish OAPI specification for a limited client
|
|
*
|
|
* API version: 0.0.1
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package client
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// ProcessorSummary struct for ProcessorSummary
|
|
type ProcessorSummary struct {
|
|
Count NullableInt32 `json:"Count,omitempty"`
|
|
Status *Status `json:"Status,omitempty"`
|
|
}
|
|
|
|
// NewProcessorSummary instantiates a new ProcessorSummary 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 NewProcessorSummary() *ProcessorSummary {
|
|
this := ProcessorSummary{}
|
|
return &this
|
|
}
|
|
|
|
// NewProcessorSummaryWithDefaults instantiates a new ProcessorSummary 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 NewProcessorSummaryWithDefaults() *ProcessorSummary {
|
|
this := ProcessorSummary{}
|
|
return &this
|
|
}
|
|
|
|
// GetCount returns the Count field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *ProcessorSummary) GetCount() int32 {
|
|
if o == nil || o.Count.Get() == nil {
|
|
var ret int32
|
|
return ret
|
|
}
|
|
return *o.Count.Get()
|
|
}
|
|
|
|
// GetCountOk returns a tuple with the Count 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 *ProcessorSummary) GetCountOk() (*int32, bool) {
|
|
if o == nil {
|
|
return nil, false
|
|
}
|
|
return o.Count.Get(), o.Count.IsSet()
|
|
}
|
|
|
|
// HasCount returns a boolean if a field has been set.
|
|
func (o *ProcessorSummary) HasCount() bool {
|
|
if o != nil && o.Count.IsSet() {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetCount gets a reference to the given NullableInt32 and assigns it to the Count field.
|
|
func (o *ProcessorSummary) SetCount(v int32) {
|
|
o.Count.Set(&v)
|
|
}
|
|
// SetCountNil sets the value for Count to be an explicit nil
|
|
func (o *ProcessorSummary) SetCountNil() {
|
|
o.Count.Set(nil)
|
|
}
|
|
|
|
// UnsetCount ensures that no value is present for Count, not even an explicit nil
|
|
func (o *ProcessorSummary) UnsetCount() {
|
|
o.Count.Unset()
|
|
}
|
|
|
|
// GetStatus returns the Status field value if set, zero value otherwise.
|
|
func (o *ProcessorSummary) GetStatus() Status {
|
|
if o == nil || o.Status == nil {
|
|
var ret Status
|
|
return ret
|
|
}
|
|
return *o.Status
|
|
}
|
|
|
|
// GetStatusOk returns a tuple with the Status field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *ProcessorSummary) GetStatusOk() (*Status, bool) {
|
|
if o == nil || o.Status == nil {
|
|
return nil, false
|
|
}
|
|
return o.Status, true
|
|
}
|
|
|
|
// HasStatus returns a boolean if a field has been set.
|
|
func (o *ProcessorSummary) HasStatus() bool {
|
|
if o != nil && o.Status != nil {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetStatus gets a reference to the given Status and assigns it to the Status field.
|
|
func (o *ProcessorSummary) SetStatus(v Status) {
|
|
o.Status = &v
|
|
}
|
|
|
|
func (o ProcessorSummary) MarshalJSON() ([]byte, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if o.Count.IsSet() {
|
|
toSerialize["Count"] = o.Count.Get()
|
|
}
|
|
if o.Status != nil {
|
|
toSerialize["Status"] = o.Status
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
type NullableProcessorSummary struct {
|
|
value *ProcessorSummary
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableProcessorSummary) Get() *ProcessorSummary {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableProcessorSummary) Set(val *ProcessorSummary) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableProcessorSummary) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableProcessorSummary) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableProcessorSummary(val *ProcessorSummary) *NullableProcessorSummary {
|
|
return &NullableProcessorSummary{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableProcessorSummary) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableProcessorSummary) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|
|
|
|
|