/*
1Backend

AI-native microservices platform.

API version: 0.8.2
Contact: sales@singulatron.com
*/

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

package openapi

import (
	"encoding/json"
)

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

// PromptSvcTypesResponse struct for PromptSvcTypesResponse
type PromptSvcTypesResponse struct {
	Chunk *PromptSvcStreamChunk `json:"chunk,omitempty"`
}

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

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

// GetChunk returns the Chunk field value if set, zero value otherwise.
func (o *PromptSvcTypesResponse) GetChunk() PromptSvcStreamChunk {
	if o == nil || IsNil(o.Chunk) {
		var ret PromptSvcStreamChunk
		return ret
	}
	return *o.Chunk
}

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

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

	return false
}

// SetChunk gets a reference to the given PromptSvcStreamChunk and assigns it to the Chunk field.
func (o *PromptSvcTypesResponse) SetChunk(v PromptSvcStreamChunk) {
	o.Chunk = &v
}

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

func (o PromptSvcTypesResponse) ToMap() (map[string]interface{}, error) {
	toSerialize := map[string]interface{}{}
	if !IsNil(o.Chunk) {
		toSerialize["chunk"] = o.Chunk
	}
	return toSerialize, nil
}

type NullablePromptSvcTypesResponse struct {
	value *PromptSvcTypesResponse
	isSet bool
}

func (v NullablePromptSvcTypesResponse) Get() *PromptSvcTypesResponse {
	return v.value
}

func (v *NullablePromptSvcTypesResponse) Set(val *PromptSvcTypesResponse) {
	v.value = val
	v.isSet = true
}

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

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

func NewNullablePromptSvcTypesResponse(val *PromptSvcTypesResponse) *NullablePromptSvcTypesResponse {
	return &NullablePromptSvcTypesResponse{value: val, isSet: true}
}

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

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


