peridot/vendor/openapi.peridot.resf.org/peridotopenapi/model_v1_build.go
Mustafa Gezen 496b60ba44
Add support for lookaside rpm import, introduce CLI and machine-to-machine callers support
Signed-off-by: Mustafa Gezen <mustafa@ctrliq.com>
2022-08-31 20:06:01 +02:00

301 lines
7.3 KiB
Go

/*
* peridot/proto/v1/batch.proto
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* API version: version not set
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package peridotopenapi
import (
"encoding/json"
"time"
)
// V1Build struct for V1Build
type V1Build struct {
Id *string `json:"id,omitempty"`
CreatedAt *time.Time `json:"createdAt,omitempty"`
Name *string `json:"name,omitempty"`
ImportRevisions *[]V1ImportRevision `json:"importRevisions,omitempty"`
TaskId *string `json:"taskId,omitempty"`
Status *V1TaskStatus `json:"status,omitempty"`
}
// NewV1Build instantiates a new V1Build 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 NewV1Build() *V1Build {
this := V1Build{}
var status V1TaskStatus = UNSPECIFIED
this.Status = &status
return &this
}
// NewV1BuildWithDefaults instantiates a new V1Build 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 NewV1BuildWithDefaults() *V1Build {
this := V1Build{}
var status V1TaskStatus = UNSPECIFIED
this.Status = &status
return &this
}
// GetId returns the Id field value if set, zero value otherwise.
func (o *V1Build) GetId() string {
if o == nil || o.Id == nil {
var ret string
return ret
}
return *o.Id
}
// GetIdOk returns a tuple with the Id field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *V1Build) GetIdOk() (*string, bool) {
if o == nil || o.Id == nil {
return nil, false
}
return o.Id, true
}
// HasId returns a boolean if a field has been set.
func (o *V1Build) HasId() bool {
if o != nil && o.Id != nil {
return true
}
return false
}
// SetId gets a reference to the given string and assigns it to the Id field.
func (o *V1Build) SetId(v string) {
o.Id = &v
}
// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise.
func (o *V1Build) GetCreatedAt() time.Time {
if o == nil || o.CreatedAt == nil {
var ret time.Time
return ret
}
return *o.CreatedAt
}
// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *V1Build) GetCreatedAtOk() (*time.Time, bool) {
if o == nil || o.CreatedAt == nil {
return nil, false
}
return o.CreatedAt, true
}
// HasCreatedAt returns a boolean if a field has been set.
func (o *V1Build) HasCreatedAt() bool {
if o != nil && o.CreatedAt != nil {
return true
}
return false
}
// SetCreatedAt gets a reference to the given time.Time and assigns it to the CreatedAt field.
func (o *V1Build) SetCreatedAt(v time.Time) {
o.CreatedAt = &v
}
// GetName returns the Name field value if set, zero value otherwise.
func (o *V1Build) GetName() string {
if o == nil || o.Name == nil {
var ret string
return ret
}
return *o.Name
}
// GetNameOk returns a tuple with the Name field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *V1Build) GetNameOk() (*string, bool) {
if o == nil || o.Name == nil {
return nil, false
}
return o.Name, true
}
// HasName returns a boolean if a field has been set.
func (o *V1Build) HasName() bool {
if o != nil && o.Name != nil {
return true
}
return false
}
// SetName gets a reference to the given string and assigns it to the Name field.
func (o *V1Build) SetName(v string) {
o.Name = &v
}
// GetImportRevisions returns the ImportRevisions field value if set, zero value otherwise.
func (o *V1Build) GetImportRevisions() []V1ImportRevision {
if o == nil || o.ImportRevisions == nil {
var ret []V1ImportRevision
return ret
}
return *o.ImportRevisions
}
// GetImportRevisionsOk returns a tuple with the ImportRevisions field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *V1Build) GetImportRevisionsOk() (*[]V1ImportRevision, bool) {
if o == nil || o.ImportRevisions == nil {
return nil, false
}
return o.ImportRevisions, true
}
// HasImportRevisions returns a boolean if a field has been set.
func (o *V1Build) HasImportRevisions() bool {
if o != nil && o.ImportRevisions != nil {
return true
}
return false
}
// SetImportRevisions gets a reference to the given []V1ImportRevision and assigns it to the ImportRevisions field.
func (o *V1Build) SetImportRevisions(v []V1ImportRevision) {
o.ImportRevisions = &v
}
// GetTaskId returns the TaskId field value if set, zero value otherwise.
func (o *V1Build) GetTaskId() string {
if o == nil || o.TaskId == nil {
var ret string
return ret
}
return *o.TaskId
}
// GetTaskIdOk returns a tuple with the TaskId field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *V1Build) GetTaskIdOk() (*string, bool) {
if o == nil || o.TaskId == nil {
return nil, false
}
return o.TaskId, true
}
// HasTaskId returns a boolean if a field has been set.
func (o *V1Build) HasTaskId() bool {
if o != nil && o.TaskId != nil {
return true
}
return false
}
// SetTaskId gets a reference to the given string and assigns it to the TaskId field.
func (o *V1Build) SetTaskId(v string) {
o.TaskId = &v
}
// GetStatus returns the Status field value if set, zero value otherwise.
func (o *V1Build) GetStatus() V1TaskStatus {
if o == nil || o.Status == nil {
var ret V1TaskStatus
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 *V1Build) GetStatusOk() (*V1TaskStatus, 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 *V1Build) HasStatus() bool {
if o != nil && o.Status != nil {
return true
}
return false
}
// SetStatus gets a reference to the given V1TaskStatus and assigns it to the Status field.
func (o *V1Build) SetStatus(v V1TaskStatus) {
o.Status = &v
}
func (o V1Build) MarshalJSON() ([]byte, error) {
toSerialize := map[string]interface{}{}
if o.Id != nil {
toSerialize["id"] = o.Id
}
if o.CreatedAt != nil {
toSerialize["createdAt"] = o.CreatedAt
}
if o.Name != nil {
toSerialize["name"] = o.Name
}
if o.ImportRevisions != nil {
toSerialize["importRevisions"] = o.ImportRevisions
}
if o.TaskId != nil {
toSerialize["taskId"] = o.TaskId
}
if o.Status != nil {
toSerialize["status"] = o.Status
}
return json.Marshal(toSerialize)
}
type NullableV1Build struct {
value *V1Build
isSet bool
}
func (v NullableV1Build) Get() *V1Build {
return v.value
}
func (v *NullableV1Build) Set(val *V1Build) {
v.value = val
v.isSet = true
}
func (v NullableV1Build) IsSet() bool {
return v.isSet
}
func (v *NullableV1Build) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableV1Build(val *V1Build) *NullableV1Build {
return &NullableV1Build{value: val, isSet: true}
}
func (v NullableV1Build) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableV1Build) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}