161 lines
4.4 KiB
Go
161 lines
4.4 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 openapi
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// checks if the SchemaAnswerAcceptedReq type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &SchemaAnswerAcceptedReq{}
|
|
|
|
// SchemaAnswerAcceptedReq struct for SchemaAnswerAcceptedReq
|
|
type SchemaAnswerAcceptedReq struct {
|
|
AnswerId *string `json:"answer_id,omitempty"`
|
|
QuestionId *string `json:"question_id,omitempty"`
|
|
}
|
|
|
|
// NewSchemaAnswerAcceptedReq instantiates a new SchemaAnswerAcceptedReq 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 NewSchemaAnswerAcceptedReq() *SchemaAnswerAcceptedReq {
|
|
this := SchemaAnswerAcceptedReq{}
|
|
return &this
|
|
}
|
|
|
|
// NewSchemaAnswerAcceptedReqWithDefaults instantiates a new SchemaAnswerAcceptedReq 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 NewSchemaAnswerAcceptedReqWithDefaults() *SchemaAnswerAcceptedReq {
|
|
this := SchemaAnswerAcceptedReq{}
|
|
return &this
|
|
}
|
|
|
|
// GetAnswerId returns the AnswerId field value if set, zero value otherwise.
|
|
func (o *SchemaAnswerAcceptedReq) GetAnswerId() string {
|
|
if o == nil || IsNil(o.AnswerId) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.AnswerId
|
|
}
|
|
|
|
// GetAnswerIdOk returns a tuple with the AnswerId field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SchemaAnswerAcceptedReq) GetAnswerIdOk() (*string, bool) {
|
|
if o == nil || IsNil(o.AnswerId) {
|
|
return nil, false
|
|
}
|
|
return o.AnswerId, true
|
|
}
|
|
|
|
// HasAnswerId returns a boolean if a field has been set.
|
|
func (o *SchemaAnswerAcceptedReq) HasAnswerId() bool {
|
|
if o != nil && !IsNil(o.AnswerId) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetAnswerId gets a reference to the given string and assigns it to the AnswerId field.
|
|
func (o *SchemaAnswerAcceptedReq) SetAnswerId(v string) {
|
|
o.AnswerId = &v
|
|
}
|
|
|
|
// GetQuestionId returns the QuestionId field value if set, zero value otherwise.
|
|
func (o *SchemaAnswerAcceptedReq) GetQuestionId() string {
|
|
if o == nil || IsNil(o.QuestionId) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.QuestionId
|
|
}
|
|
|
|
// GetQuestionIdOk returns a tuple with the QuestionId field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *SchemaAnswerAcceptedReq) GetQuestionIdOk() (*string, bool) {
|
|
if o == nil || IsNil(o.QuestionId) {
|
|
return nil, false
|
|
}
|
|
return o.QuestionId, true
|
|
}
|
|
|
|
// HasQuestionId returns a boolean if a field has been set.
|
|
func (o *SchemaAnswerAcceptedReq) HasQuestionId() bool {
|
|
if o != nil && !IsNil(o.QuestionId) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetQuestionId gets a reference to the given string and assigns it to the QuestionId field.
|
|
func (o *SchemaAnswerAcceptedReq) SetQuestionId(v string) {
|
|
o.QuestionId = &v
|
|
}
|
|
|
|
func (o SchemaAnswerAcceptedReq) MarshalJSON() ([]byte, error) {
|
|
toSerialize,err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o SchemaAnswerAcceptedReq) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.AnswerId) {
|
|
toSerialize["answer_id"] = o.AnswerId
|
|
}
|
|
if !IsNil(o.QuestionId) {
|
|
toSerialize["question_id"] = o.QuestionId
|
|
}
|
|
return toSerialize, nil
|
|
}
|
|
|
|
type NullableSchemaAnswerAcceptedReq struct {
|
|
value *SchemaAnswerAcceptedReq
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableSchemaAnswerAcceptedReq) Get() *SchemaAnswerAcceptedReq {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableSchemaAnswerAcceptedReq) Set(val *SchemaAnswerAcceptedReq) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableSchemaAnswerAcceptedReq) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableSchemaAnswerAcceptedReq) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableSchemaAnswerAcceptedReq(val *SchemaAnswerAcceptedReq) *NullableSchemaAnswerAcceptedReq {
|
|
return &NullableSchemaAnswerAcceptedReq{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableSchemaAnswerAcceptedReq) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableSchemaAnswerAcceptedReq) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|
|
|
|
|