/*
FinFeedAPI SEC REST API

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

API version: v1
Contact: support@apibricks.io
*/

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

package openapi

import (
	"encoding/json"
)

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

// DTOSecFilingResultDto struct for DTOSecFilingResultDto
type DTOSecFilingResultDto struct {
	AccessionNumber NullableString `json:"accession_number,omitempty"`
	FormType NullableString `json:"form_type,omitempty"`
	FilingDate *string `json:"filing_date,omitempty"`
	CompanyName NullableString `json:"company_name,omitempty"`
	Cik *int64 `json:"cik,omitempty"`
	DocumentFilename NullableString `json:"document_filename,omitempty"`
	DocumentDescription NullableString `json:"document_description,omitempty"`
	SourceFile NullableString `json:"source_file,omitempty"`
}

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

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

// GetAccessionNumber returns the AccessionNumber field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *DTOSecFilingResultDto) GetAccessionNumber() string {
	if o == nil || IsNil(o.AccessionNumber.Get()) {
		var ret string
		return ret
	}
	return *o.AccessionNumber.Get()
}

// GetAccessionNumberOk returns a tuple with the AccessionNumber field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *DTOSecFilingResultDto) GetAccessionNumberOk() (*string, bool) {
	if o == nil {
		return nil, false
	}
	return o.AccessionNumber.Get(), o.AccessionNumber.IsSet()
}

// HasAccessionNumber returns a boolean if a field has been set.
func (o *DTOSecFilingResultDto) HasAccessionNumber() bool {
	if o != nil && o.AccessionNumber.IsSet() {
		return true
	}

	return false
}

// SetAccessionNumber gets a reference to the given NullableString and assigns it to the AccessionNumber field.
func (o *DTOSecFilingResultDto) SetAccessionNumber(v string) {
	o.AccessionNumber.Set(&v)
}
// SetAccessionNumberNil sets the value for AccessionNumber to be an explicit nil
func (o *DTOSecFilingResultDto) SetAccessionNumberNil() {
	o.AccessionNumber.Set(nil)
}

// UnsetAccessionNumber ensures that no value is present for AccessionNumber, not even an explicit nil
func (o *DTOSecFilingResultDto) UnsetAccessionNumber() {
	o.AccessionNumber.Unset()
}

// GetFormType returns the FormType field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *DTOSecFilingResultDto) GetFormType() string {
	if o == nil || IsNil(o.FormType.Get()) {
		var ret string
		return ret
	}
	return *o.FormType.Get()
}

// GetFormTypeOk returns a tuple with the FormType field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *DTOSecFilingResultDto) GetFormTypeOk() (*string, bool) {
	if o == nil {
		return nil, false
	}
	return o.FormType.Get(), o.FormType.IsSet()
}

// HasFormType returns a boolean if a field has been set.
func (o *DTOSecFilingResultDto) HasFormType() bool {
	if o != nil && o.FormType.IsSet() {
		return true
	}

	return false
}

// SetFormType gets a reference to the given NullableString and assigns it to the FormType field.
func (o *DTOSecFilingResultDto) SetFormType(v string) {
	o.FormType.Set(&v)
}
// SetFormTypeNil sets the value for FormType to be an explicit nil
func (o *DTOSecFilingResultDto) SetFormTypeNil() {
	o.FormType.Set(nil)
}

// UnsetFormType ensures that no value is present for FormType, not even an explicit nil
func (o *DTOSecFilingResultDto) UnsetFormType() {
	o.FormType.Unset()
}

// GetFilingDate returns the FilingDate field value if set, zero value otherwise.
func (o *DTOSecFilingResultDto) GetFilingDate() string {
	if o == nil || IsNil(o.FilingDate) {
		var ret string
		return ret
	}
	return *o.FilingDate
}

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

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

	return false
}

// SetFilingDate gets a reference to the given string and assigns it to the FilingDate field.
func (o *DTOSecFilingResultDto) SetFilingDate(v string) {
	o.FilingDate = &v
}

// GetCompanyName returns the CompanyName field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *DTOSecFilingResultDto) GetCompanyName() string {
	if o == nil || IsNil(o.CompanyName.Get()) {
		var ret string
		return ret
	}
	return *o.CompanyName.Get()
}

// GetCompanyNameOk returns a tuple with the CompanyName field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *DTOSecFilingResultDto) GetCompanyNameOk() (*string, bool) {
	if o == nil {
		return nil, false
	}
	return o.CompanyName.Get(), o.CompanyName.IsSet()
}

// HasCompanyName returns a boolean if a field has been set.
func (o *DTOSecFilingResultDto) HasCompanyName() bool {
	if o != nil && o.CompanyName.IsSet() {
		return true
	}

	return false
}

// SetCompanyName gets a reference to the given NullableString and assigns it to the CompanyName field.
func (o *DTOSecFilingResultDto) SetCompanyName(v string) {
	o.CompanyName.Set(&v)
}
// SetCompanyNameNil sets the value for CompanyName to be an explicit nil
func (o *DTOSecFilingResultDto) SetCompanyNameNil() {
	o.CompanyName.Set(nil)
}

// UnsetCompanyName ensures that no value is present for CompanyName, not even an explicit nil
func (o *DTOSecFilingResultDto) UnsetCompanyName() {
	o.CompanyName.Unset()
}

// GetCik returns the Cik field value if set, zero value otherwise.
func (o *DTOSecFilingResultDto) GetCik() int64 {
	if o == nil || IsNil(o.Cik) {
		var ret int64
		return ret
	}
	return *o.Cik
}

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

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

	return false
}

// SetCik gets a reference to the given int64 and assigns it to the Cik field.
func (o *DTOSecFilingResultDto) SetCik(v int64) {
	o.Cik = &v
}

// GetDocumentFilename returns the DocumentFilename field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *DTOSecFilingResultDto) GetDocumentFilename() string {
	if o == nil || IsNil(o.DocumentFilename.Get()) {
		var ret string
		return ret
	}
	return *o.DocumentFilename.Get()
}

// GetDocumentFilenameOk returns a tuple with the DocumentFilename field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *DTOSecFilingResultDto) GetDocumentFilenameOk() (*string, bool) {
	if o == nil {
		return nil, false
	}
	return o.DocumentFilename.Get(), o.DocumentFilename.IsSet()
}

// HasDocumentFilename returns a boolean if a field has been set.
func (o *DTOSecFilingResultDto) HasDocumentFilename() bool {
	if o != nil && o.DocumentFilename.IsSet() {
		return true
	}

	return false
}

// SetDocumentFilename gets a reference to the given NullableString and assigns it to the DocumentFilename field.
func (o *DTOSecFilingResultDto) SetDocumentFilename(v string) {
	o.DocumentFilename.Set(&v)
}
// SetDocumentFilenameNil sets the value for DocumentFilename to be an explicit nil
func (o *DTOSecFilingResultDto) SetDocumentFilenameNil() {
	o.DocumentFilename.Set(nil)
}

// UnsetDocumentFilename ensures that no value is present for DocumentFilename, not even an explicit nil
func (o *DTOSecFilingResultDto) UnsetDocumentFilename() {
	o.DocumentFilename.Unset()
}

// GetDocumentDescription returns the DocumentDescription field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *DTOSecFilingResultDto) GetDocumentDescription() string {
	if o == nil || IsNil(o.DocumentDescription.Get()) {
		var ret string
		return ret
	}
	return *o.DocumentDescription.Get()
}

// GetDocumentDescriptionOk returns a tuple with the DocumentDescription field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *DTOSecFilingResultDto) GetDocumentDescriptionOk() (*string, bool) {
	if o == nil {
		return nil, false
	}
	return o.DocumentDescription.Get(), o.DocumentDescription.IsSet()
}

// HasDocumentDescription returns a boolean if a field has been set.
func (o *DTOSecFilingResultDto) HasDocumentDescription() bool {
	if o != nil && o.DocumentDescription.IsSet() {
		return true
	}

	return false
}

// SetDocumentDescription gets a reference to the given NullableString and assigns it to the DocumentDescription field.
func (o *DTOSecFilingResultDto) SetDocumentDescription(v string) {
	o.DocumentDescription.Set(&v)
}
// SetDocumentDescriptionNil sets the value for DocumentDescription to be an explicit nil
func (o *DTOSecFilingResultDto) SetDocumentDescriptionNil() {
	o.DocumentDescription.Set(nil)
}

// UnsetDocumentDescription ensures that no value is present for DocumentDescription, not even an explicit nil
func (o *DTOSecFilingResultDto) UnsetDocumentDescription() {
	o.DocumentDescription.Unset()
}

// GetSourceFile returns the SourceFile field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *DTOSecFilingResultDto) GetSourceFile() string {
	if o == nil || IsNil(o.SourceFile.Get()) {
		var ret string
		return ret
	}
	return *o.SourceFile.Get()
}

// GetSourceFileOk returns a tuple with the SourceFile field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *DTOSecFilingResultDto) GetSourceFileOk() (*string, bool) {
	if o == nil {
		return nil, false
	}
	return o.SourceFile.Get(), o.SourceFile.IsSet()
}

// HasSourceFile returns a boolean if a field has been set.
func (o *DTOSecFilingResultDto) HasSourceFile() bool {
	if o != nil && o.SourceFile.IsSet() {
		return true
	}

	return false
}

// SetSourceFile gets a reference to the given NullableString and assigns it to the SourceFile field.
func (o *DTOSecFilingResultDto) SetSourceFile(v string) {
	o.SourceFile.Set(&v)
}
// SetSourceFileNil sets the value for SourceFile to be an explicit nil
func (o *DTOSecFilingResultDto) SetSourceFileNil() {
	o.SourceFile.Set(nil)
}

// UnsetSourceFile ensures that no value is present for SourceFile, not even an explicit nil
func (o *DTOSecFilingResultDto) UnsetSourceFile() {
	o.SourceFile.Unset()
}

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

func (o DTOSecFilingResultDto) ToMap() (map[string]interface{}, error) {
	toSerialize := map[string]interface{}{}
	if o.AccessionNumber.IsSet() {
		toSerialize["accession_number"] = o.AccessionNumber.Get()
	}
	if o.FormType.IsSet() {
		toSerialize["form_type"] = o.FormType.Get()
	}
	if !IsNil(o.FilingDate) {
		toSerialize["filing_date"] = o.FilingDate
	}
	if o.CompanyName.IsSet() {
		toSerialize["company_name"] = o.CompanyName.Get()
	}
	if !IsNil(o.Cik) {
		toSerialize["cik"] = o.Cik
	}
	if o.DocumentFilename.IsSet() {
		toSerialize["document_filename"] = o.DocumentFilename.Get()
	}
	if o.DocumentDescription.IsSet() {
		toSerialize["document_description"] = o.DocumentDescription.Get()
	}
	if o.SourceFile.IsSet() {
		toSerialize["source_file"] = o.SourceFile.Get()
	}
	return toSerialize, nil
}

type NullableDTOSecFilingResultDto struct {
	value *DTOSecFilingResultDto
	isSet bool
}

func (v NullableDTOSecFilingResultDto) Get() *DTOSecFilingResultDto {
	return v.value
}

func (v *NullableDTOSecFilingResultDto) Set(val *DTOSecFilingResultDto) {
	v.value = val
	v.isSet = true
}

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

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

func NewNullableDTOSecFilingResultDto(val *DTOSecFilingResultDto) *NullableDTOSecFilingResultDto {
	return &NullableDTOSecFilingResultDto{value: val, isSet: true}
}

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

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


