/*
Digital Certificates API

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

API version: 2.0.0
*/

// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.

package digital_certificates

import (
	"encoding/json"
)

// checks if the DC400 type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &DC400{}

// DC400 struct for DC400
type DC400 struct {
	Errors []map[string]interface{} `json:"errors,omitempty"`
	SchemaVersion *int32 `json:"schema_version,omitempty"`
}

// NewDC400 instantiates a new DC400 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 NewDC400() *DC400 {
	this := DC400{}
	return &this
}

// NewDC400WithDefaults instantiates a new DC400 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 NewDC400WithDefaults() *DC400 {
	this := DC400{}
	return &this
}

// GetErrors returns the Errors field value if set, zero value otherwise.
func (o *DC400) GetErrors() []map[string]interface{} {
	if o == nil || IsNil(o.Errors) {
		var ret []map[string]interface{}
		return ret
	}
	return o.Errors
}

// GetErrorsOk returns a tuple with the Errors field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DC400) GetErrorsOk() ([]map[string]interface{}, bool) {
	if o == nil || IsNil(o.Errors) {
		return nil, false
	}
	return o.Errors, true
}

// HasErrors returns a boolean if a field has been set.
func (o *DC400) HasErrors() bool {
	if o != nil && !IsNil(o.Errors) {
		return true
	}

	return false
}

// SetErrors gets a reference to the given []map[string]interface{} and assigns it to the Errors field.
func (o *DC400) SetErrors(v []map[string]interface{}) {
	o.Errors = v
}

// GetSchemaVersion returns the SchemaVersion field value if set, zero value otherwise.
func (o *DC400) GetSchemaVersion() int32 {
	if o == nil || IsNil(o.SchemaVersion) {
		var ret int32
		return ret
	}
	return *o.SchemaVersion
}

// GetSchemaVersionOk returns a tuple with the SchemaVersion field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *DC400) GetSchemaVersionOk() (*int32, bool) {
	if o == nil || IsNil(o.SchemaVersion) {
		return nil, false
	}
	return o.SchemaVersion, true
}

// HasSchemaVersion returns a boolean if a field has been set.
func (o *DC400) HasSchemaVersion() bool {
	if o != nil && !IsNil(o.SchemaVersion) {
		return true
	}

	return false
}

// SetSchemaVersion gets a reference to the given int32 and assigns it to the SchemaVersion field.
func (o *DC400) SetSchemaVersion(v int32) {
	o.SchemaVersion = &v
}

func (o DC400) MarshalJSON() ([]byte, error) {
	toSerialize,err := o.ToMap()
	if err != nil {
		return []byte{}, err
	}
	return json.Marshal(toSerialize)
}

func (o DC400) ToMap() (map[string]interface{}, error) {
	toSerialize := map[string]interface{}{}
	if !IsNil(o.Errors) {
		toSerialize["errors"] = o.Errors
	}
	if !IsNil(o.SchemaVersion) {
		toSerialize["schema_version"] = o.SchemaVersion
	}
	return toSerialize, nil
}

type NullableDC400 struct {
	value *DC400
	isSet bool
}

func (v NullableDC400) Get() *DC400 {
	return v.value
}

func (v *NullableDC400) Set(val *DC400) {
	v.value = val
	v.isSet = true
}

func (v NullableDC400) IsSet() bool {
	return v.isSet
}

func (v *NullableDC400) Unset() {
	v.value = nil
	v.isSet = false
}

func NewNullableDC400(val *DC400) *NullableDC400 {
	return &NullableDC400{value: val, isSet: true}
}

func (v NullableDC400) MarshalJSON() ([]byte, error) {
	return json.Marshal(v.value)
}

func (v *NullableDC400) UnmarshalJSON(src []byte) error {
	v.isSet = true
	return json.Unmarshal(src, &v.value)
}


