github.com/optim-corp/cios-golang-sdk@v0.5.1/cios/model_multiple_life_cycle.go (about)

     1  /*
     2   * Cios Openapi
     3   *
     4   * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
     5   *
     6   * API version: 1.0.1
     7   */
     8  
     9  // Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
    10  
    11  package cios
    12  
    13  import (
    14  	"encoding/json"
    15  )
    16  
    17  // MultipleLifeCycle struct for MultipleLifeCycle
    18  type MultipleLifeCycle struct {
    19  	Total int64 `json:"total"`
    20  	Lifecycles []LifeCycle `json:"lifecycles"`
    21  }
    22  
    23  // NewMultipleLifeCycle instantiates a new MultipleLifeCycle object
    24  // This constructor will assign default values to properties that have it defined,
    25  // and makes sure properties required by API are set, but the set of arguments
    26  // will change when the set of required properties is changed
    27  func NewMultipleLifeCycle(total int64, lifecycles []LifeCycle, ) *MultipleLifeCycle {
    28  	this := MultipleLifeCycle{}
    29  	this.Total = total
    30  	this.Lifecycles = lifecycles
    31  	return &this
    32  }
    33  
    34  // NewMultipleLifeCycleWithDefaults instantiates a new MultipleLifeCycle object
    35  // This constructor will only assign default values to properties that have it defined,
    36  // but it doesn't guarantee that properties required by API are set
    37  func NewMultipleLifeCycleWithDefaults() *MultipleLifeCycle {
    38  	this := MultipleLifeCycle{}
    39  	return &this
    40  }
    41  
    42  // GetTotal returns the Total field value
    43  func (o *MultipleLifeCycle) GetTotal() int64 {
    44  	if o == nil  {
    45  		var ret int64
    46  		return ret
    47  	}
    48  
    49  	return o.Total
    50  }
    51  
    52  // GetTotalOk returns a tuple with the Total field value
    53  // and a boolean to check if the value has been set.
    54  func (o *MultipleLifeCycle) GetTotalOk() (*int64, bool) {
    55  	if o == nil  {
    56  		return nil, false
    57  	}
    58  	return &o.Total, true
    59  }
    60  
    61  // SetTotal sets field value
    62  func (o *MultipleLifeCycle) SetTotal(v int64) {
    63  	o.Total = v
    64  }
    65  
    66  // GetLifecycles returns the Lifecycles field value
    67  func (o *MultipleLifeCycle) GetLifecycles() []LifeCycle {
    68  	if o == nil  {
    69  		var ret []LifeCycle
    70  		return ret
    71  	}
    72  
    73  	return o.Lifecycles
    74  }
    75  
    76  // GetLifecyclesOk returns a tuple with the Lifecycles field value
    77  // and a boolean to check if the value has been set.
    78  func (o *MultipleLifeCycle) GetLifecyclesOk() (*[]LifeCycle, bool) {
    79  	if o == nil  {
    80  		return nil, false
    81  	}
    82  	return &o.Lifecycles, true
    83  }
    84  
    85  // SetLifecycles sets field value
    86  func (o *MultipleLifeCycle) SetLifecycles(v []LifeCycle) {
    87  	o.Lifecycles = v
    88  }
    89  
    90  func (o MultipleLifeCycle) MarshalJSON() ([]byte, error) {
    91  	toSerialize := map[string]interface{}{}
    92  	if true {
    93  		toSerialize["total"] = o.Total
    94  	}
    95  	if true {
    96  		toSerialize["lifecycles"] = o.Lifecycles
    97  	}
    98  	return json.Marshal(toSerialize)
    99  }
   100  
   101  type NullableMultipleLifeCycle struct {
   102  	value *MultipleLifeCycle
   103  	isSet bool
   104  }
   105  
   106  func (v NullableMultipleLifeCycle) Get() *MultipleLifeCycle {
   107  	return v.value
   108  }
   109  
   110  func (v *NullableMultipleLifeCycle) Set(val *MultipleLifeCycle) {
   111  	v.value = val
   112  	v.isSet = true
   113  }
   114  
   115  func (v NullableMultipleLifeCycle) IsSet() bool {
   116  	return v.isSet
   117  }
   118  
   119  func (v *NullableMultipleLifeCycle) Unset() {
   120  	v.value = nil
   121  	v.isSet = false
   122  }
   123  
   124  func NewNullableMultipleLifeCycle(val *MultipleLifeCycle) *NullableMultipleLifeCycle {
   125  	return &NullableMultipleLifeCycle{value: val, isSet: true}
   126  }
   127  
   128  func (v NullableMultipleLifeCycle) MarshalJSON() ([]byte, error) {
   129  	return json.Marshal(v.value)
   130  }
   131  
   132  func (v *NullableMultipleLifeCycle) UnmarshalJSON(src []byte) error {
   133  	v.isSet = true
   134  	return json.Unmarshal(src, &v.value)
   135  }
   136  
   137