Files
openapi-go-answer/model_schema_revision_audit_req.go
2023-09-26 16:20:01 +08:00

145 lines
3.6 KiB
Go

/*
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
API version: 1.0.0
*/
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
package answer_sdk
import (
"encoding/json"
)
// checks if the SchemaRevisionAuditReq type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &SchemaRevisionAuditReq{}
// SchemaRevisionAuditReq struct for SchemaRevisionAuditReq
type SchemaRevisionAuditReq struct {
// object id
Id string `json:"id"`
// approve or reject
Operation string `json:"operation"`
}
// NewSchemaRevisionAuditReq instantiates a new SchemaRevisionAuditReq 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 NewSchemaRevisionAuditReq(id string, operation string) *SchemaRevisionAuditReq {
this := SchemaRevisionAuditReq{}
this.Id = id
this.Operation = operation
return &this
}
// NewSchemaRevisionAuditReqWithDefaults instantiates a new SchemaRevisionAuditReq 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 NewSchemaRevisionAuditReqWithDefaults() *SchemaRevisionAuditReq {
this := SchemaRevisionAuditReq{}
return &this
}
// GetId returns the Id field value
func (o *SchemaRevisionAuditReq) GetId() string {
if o == nil {
var ret string
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 *SchemaRevisionAuditReq) GetIdOk() (*string, bool) {
if o == nil {
return nil, false
}
return &o.Id, true
}
// SetId sets field value
func (o *SchemaRevisionAuditReq) SetId(v string) {
o.Id = v
}
// GetOperation returns the Operation field value
func (o *SchemaRevisionAuditReq) GetOperation() string {
if o == nil {
var ret string
return ret
}
return o.Operation
}
// GetOperationOk returns a tuple with the Operation field value
// and a boolean to check if the value has been set.
func (o *SchemaRevisionAuditReq) GetOperationOk() (*string, bool) {
if o == nil {
return nil, false
}
return &o.Operation, true
}
// SetOperation sets field value
func (o *SchemaRevisionAuditReq) SetOperation(v string) {
o.Operation = v
}
func (o SchemaRevisionAuditReq) MarshalJSON() ([]byte, error) {
toSerialize,err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o SchemaRevisionAuditReq) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
toSerialize["id"] = o.Id
toSerialize["operation"] = o.Operation
return toSerialize, nil
}
type NullableSchemaRevisionAuditReq struct {
value *SchemaRevisionAuditReq
isSet bool
}
func (v NullableSchemaRevisionAuditReq) Get() *SchemaRevisionAuditReq {
return v.value
}
func (v *NullableSchemaRevisionAuditReq) Set(val *SchemaRevisionAuditReq) {
v.value = val
v.isSet = true
}
func (v NullableSchemaRevisionAuditReq) IsSet() bool {
return v.isSet
}
func (v *NullableSchemaRevisionAuditReq) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableSchemaRevisionAuditReq(val *SchemaRevisionAuditReq) *NullableSchemaRevisionAuditReq {
return &NullableSchemaRevisionAuditReq{value: val, isSet: true}
}
func (v NullableSchemaRevisionAuditReq) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableSchemaRevisionAuditReq) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}