/*
Legal Entity Management API

API version: 3
*/

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

package legalentity

import (
	"encoding/json"

	"github.com/adyen/adyen-go-api-library/v21/src/common"
)

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

// FinancialReport struct for FinancialReport
type FinancialReport struct {
	// The annual turnover of the business.
	AnnualTurnover *string `json:"annualTurnover,omitempty"`
	// The balance sheet total of the business.
	BalanceSheetTotal *string `json:"balanceSheetTotal,omitempty"`
	// The currency used for the net assets and balance sheet total.
	CurrencyOfFinancialData *string `json:"currencyOfFinancialData,omitempty"`
	// The date the financial data were provided, in YYYY-MM-DD format.
	DateOfFinancialData *string `json:"dateOfFinancialData,omitempty"`
	// The number of employees of the business.
	EmployeeCount *string `json:"employeeCount,omitempty"`
	// The net assets of the business.
	NetAssets *string `json:"netAssets,omitempty"`
}

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

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

// GetAnnualTurnover returns the AnnualTurnover field value if set, zero value otherwise.
func (o *FinancialReport) GetAnnualTurnover() string {
	if o == nil || common.IsNil(o.AnnualTurnover) {
		var ret string
		return ret
	}
	return *o.AnnualTurnover
}

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

// HasAnnualTurnover returns a boolean if a field has been set.
func (o *FinancialReport) HasAnnualTurnover() bool {
	if o != nil && !common.IsNil(o.AnnualTurnover) {
		return true
	}

	return false
}

// SetAnnualTurnover gets a reference to the given string and assigns it to the AnnualTurnover field.
func (o *FinancialReport) SetAnnualTurnover(v string) {
	o.AnnualTurnover = &v
}

// GetBalanceSheetTotal returns the BalanceSheetTotal field value if set, zero value otherwise.
func (o *FinancialReport) GetBalanceSheetTotal() string {
	if o == nil || common.IsNil(o.BalanceSheetTotal) {
		var ret string
		return ret
	}
	return *o.BalanceSheetTotal
}

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

// HasBalanceSheetTotal returns a boolean if a field has been set.
func (o *FinancialReport) HasBalanceSheetTotal() bool {
	if o != nil && !common.IsNil(o.BalanceSheetTotal) {
		return true
	}

	return false
}

// SetBalanceSheetTotal gets a reference to the given string and assigns it to the BalanceSheetTotal field.
func (o *FinancialReport) SetBalanceSheetTotal(v string) {
	o.BalanceSheetTotal = &v
}

// GetCurrencyOfFinancialData returns the CurrencyOfFinancialData field value if set, zero value otherwise.
func (o *FinancialReport) GetCurrencyOfFinancialData() string {
	if o == nil || common.IsNil(o.CurrencyOfFinancialData) {
		var ret string
		return ret
	}
	return *o.CurrencyOfFinancialData
}

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

// HasCurrencyOfFinancialData returns a boolean if a field has been set.
func (o *FinancialReport) HasCurrencyOfFinancialData() bool {
	if o != nil && !common.IsNil(o.CurrencyOfFinancialData) {
		return true
	}

	return false
}

// SetCurrencyOfFinancialData gets a reference to the given string and assigns it to the CurrencyOfFinancialData field.
func (o *FinancialReport) SetCurrencyOfFinancialData(v string) {
	o.CurrencyOfFinancialData = &v
}

// GetDateOfFinancialData returns the DateOfFinancialData field value if set, zero value otherwise.
func (o *FinancialReport) GetDateOfFinancialData() string {
	if o == nil || common.IsNil(o.DateOfFinancialData) {
		var ret string
		return ret
	}
	return *o.DateOfFinancialData
}

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

// HasDateOfFinancialData returns a boolean if a field has been set.
func (o *FinancialReport) HasDateOfFinancialData() bool {
	if o != nil && !common.IsNil(o.DateOfFinancialData) {
		return true
	}

	return false
}

// SetDateOfFinancialData gets a reference to the given string and assigns it to the DateOfFinancialData field.
func (o *FinancialReport) SetDateOfFinancialData(v string) {
	o.DateOfFinancialData = &v
}

// GetEmployeeCount returns the EmployeeCount field value if set, zero value otherwise.
func (o *FinancialReport) GetEmployeeCount() string {
	if o == nil || common.IsNil(o.EmployeeCount) {
		var ret string
		return ret
	}
	return *o.EmployeeCount
}

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

// HasEmployeeCount returns a boolean if a field has been set.
func (o *FinancialReport) HasEmployeeCount() bool {
	if o != nil && !common.IsNil(o.EmployeeCount) {
		return true
	}

	return false
}

// SetEmployeeCount gets a reference to the given string and assigns it to the EmployeeCount field.
func (o *FinancialReport) SetEmployeeCount(v string) {
	o.EmployeeCount = &v
}

// GetNetAssets returns the NetAssets field value if set, zero value otherwise.
func (o *FinancialReport) GetNetAssets() string {
	if o == nil || common.IsNil(o.NetAssets) {
		var ret string
		return ret
	}
	return *o.NetAssets
}

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

// HasNetAssets returns a boolean if a field has been set.
func (o *FinancialReport) HasNetAssets() bool {
	if o != nil && !common.IsNil(o.NetAssets) {
		return true
	}

	return false
}

// SetNetAssets gets a reference to the given string and assigns it to the NetAssets field.
func (o *FinancialReport) SetNetAssets(v string) {
	o.NetAssets = &v
}

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

func (o FinancialReport) ToMap() (map[string]interface{}, error) {
	toSerialize := map[string]interface{}{}
	if !common.IsNil(o.AnnualTurnover) {
		toSerialize["annualTurnover"] = o.AnnualTurnover
	}
	if !common.IsNil(o.BalanceSheetTotal) {
		toSerialize["balanceSheetTotal"] = o.BalanceSheetTotal
	}
	if !common.IsNil(o.CurrencyOfFinancialData) {
		toSerialize["currencyOfFinancialData"] = o.CurrencyOfFinancialData
	}
	if !common.IsNil(o.DateOfFinancialData) {
		toSerialize["dateOfFinancialData"] = o.DateOfFinancialData
	}
	if !common.IsNil(o.EmployeeCount) {
		toSerialize["employeeCount"] = o.EmployeeCount
	}
	if !common.IsNil(o.NetAssets) {
		toSerialize["netAssets"] = o.NetAssets
	}
	return toSerialize, nil
}

type NullableFinancialReport struct {
	value *FinancialReport
	isSet bool
}

func (v NullableFinancialReport) Get() *FinancialReport {
	return v.value
}

func (v *NullableFinancialReport) Set(val *FinancialReport) {
	v.value = val
	v.isSet = true
}

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

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

func NewNullableFinancialReport(val *FinancialReport) *NullableFinancialReport {
	return &NullableFinancialReport{value: val, isSet: true}
}

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

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