mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
535 lines
15 KiB
Go
535 lines
15 KiB
Go
/*
|
|
Hanzo Cloud API
|
|
|
|
The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
|
|
|
|
API version: v1
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package hanzoai
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// checks if the CaptableCaptableRound type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &CaptableCaptableRound{}
|
|
|
|
// CaptableCaptableRound struct for CaptableCaptableRound
|
|
type CaptableCaptableRound struct {
|
|
// CloseDate is the ISO date the round closed, once it has.
|
|
CloseDate *string `json:"closeDate,omitempty"`
|
|
// CreatedAt is when the round was recorded, in unix milliseconds.
|
|
CreatedAt *int64 `json:"createdAt,omitempty"`
|
|
// ID is the round id.
|
|
Id *string `json:"id,omitempty"`
|
|
// Name is the round name, e.g. \"Series A\".
|
|
Name *string `json:"name,omitempty"`
|
|
// PreMoneyValuation is the pre-money valuation, for a priced round.
|
|
PreMoneyValuation *float64 `json:"preMoneyValuation,omitempty"`
|
|
// PricePerShare is the price per share, for a priced round.
|
|
PricePerShare *float64 `json:"pricePerShare,omitempty"`
|
|
// RaisedAmount is how much has been invested so far.
|
|
RaisedAmount *float64 `json:"raisedAmount,omitempty"`
|
|
// RoundType is PRICED, SAFE or CONVERTIBLE_NOTE.
|
|
RoundType *string `json:"roundType,omitempty"`
|
|
// ShareClassID is the class a priced round issues into.
|
|
ShareClassId *string `json:"shareClassId,omitempty"`
|
|
// Status is OPEN or CLOSED.
|
|
Status *string `json:"status,omitempty"`
|
|
// TargetAmount is how much the round set out to raise.
|
|
TargetAmount *float64 `json:"targetAmount,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _CaptableCaptableRound CaptableCaptableRound
|
|
|
|
// NewCaptableCaptableRound instantiates a new CaptableCaptableRound 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 NewCaptableCaptableRound() *CaptableCaptableRound {
|
|
this := CaptableCaptableRound{}
|
|
return &this
|
|
}
|
|
|
|
// NewCaptableCaptableRoundWithDefaults instantiates a new CaptableCaptableRound 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 NewCaptableCaptableRoundWithDefaults() *CaptableCaptableRound {
|
|
this := CaptableCaptableRound{}
|
|
return &this
|
|
}
|
|
|
|
// GetCloseDate returns the CloseDate field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetCloseDate() string {
|
|
if o == nil || IsNil(o.CloseDate) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.CloseDate
|
|
}
|
|
|
|
// GetCloseDateOk returns a tuple with the CloseDate field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetCloseDateOk() (*string, bool) {
|
|
if o == nil || IsNil(o.CloseDate) {
|
|
return nil, false
|
|
}
|
|
return o.CloseDate, true
|
|
}
|
|
|
|
// HasCloseDate returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasCloseDate() bool {
|
|
if o != nil && !IsNil(o.CloseDate) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetCloseDate gets a reference to the given string and assigns it to the CloseDate field.
|
|
func (o *CaptableCaptableRound) SetCloseDate(v string) {
|
|
o.CloseDate = &v
|
|
}
|
|
|
|
// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetCreatedAt() int64 {
|
|
if o == nil || IsNil(o.CreatedAt) {
|
|
var ret int64
|
|
return ret
|
|
}
|
|
return *o.CreatedAt
|
|
}
|
|
|
|
// GetCreatedAtOk returns a tuple with the CreatedAt field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetCreatedAtOk() (*int64, bool) {
|
|
if o == nil || IsNil(o.CreatedAt) {
|
|
return nil, false
|
|
}
|
|
return o.CreatedAt, true
|
|
}
|
|
|
|
// HasCreatedAt returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasCreatedAt() bool {
|
|
if o != nil && !IsNil(o.CreatedAt) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetCreatedAt gets a reference to the given int64 and assigns it to the CreatedAt field.
|
|
func (o *CaptableCaptableRound) SetCreatedAt(v int64) {
|
|
o.CreatedAt = &v
|
|
}
|
|
|
|
// GetId returns the Id field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetId() string {
|
|
if o == nil || IsNil(o.Id) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Id
|
|
}
|
|
|
|
// GetIdOk returns a tuple with the Id field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetIdOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Id) {
|
|
return nil, false
|
|
}
|
|
return o.Id, true
|
|
}
|
|
|
|
// HasId returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasId() bool {
|
|
if o != nil && !IsNil(o.Id) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetId gets a reference to the given string and assigns it to the Id field.
|
|
func (o *CaptableCaptableRound) SetId(v string) {
|
|
o.Id = &v
|
|
}
|
|
|
|
// GetName returns the Name field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetName() string {
|
|
if o == nil || IsNil(o.Name) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Name
|
|
}
|
|
|
|
// GetNameOk returns a tuple with the Name field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetNameOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Name) {
|
|
return nil, false
|
|
}
|
|
return o.Name, true
|
|
}
|
|
|
|
// HasName returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasName() bool {
|
|
if o != nil && !IsNil(o.Name) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetName gets a reference to the given string and assigns it to the Name field.
|
|
func (o *CaptableCaptableRound) SetName(v string) {
|
|
o.Name = &v
|
|
}
|
|
|
|
// GetPreMoneyValuation returns the PreMoneyValuation field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetPreMoneyValuation() float64 {
|
|
if o == nil || IsNil(o.PreMoneyValuation) {
|
|
var ret float64
|
|
return ret
|
|
}
|
|
return *o.PreMoneyValuation
|
|
}
|
|
|
|
// GetPreMoneyValuationOk returns a tuple with the PreMoneyValuation field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetPreMoneyValuationOk() (*float64, bool) {
|
|
if o == nil || IsNil(o.PreMoneyValuation) {
|
|
return nil, false
|
|
}
|
|
return o.PreMoneyValuation, true
|
|
}
|
|
|
|
// HasPreMoneyValuation returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasPreMoneyValuation() bool {
|
|
if o != nil && !IsNil(o.PreMoneyValuation) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetPreMoneyValuation gets a reference to the given float64 and assigns it to the PreMoneyValuation field.
|
|
func (o *CaptableCaptableRound) SetPreMoneyValuation(v float64) {
|
|
o.PreMoneyValuation = &v
|
|
}
|
|
|
|
// GetPricePerShare returns the PricePerShare field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetPricePerShare() float64 {
|
|
if o == nil || IsNil(o.PricePerShare) {
|
|
var ret float64
|
|
return ret
|
|
}
|
|
return *o.PricePerShare
|
|
}
|
|
|
|
// GetPricePerShareOk returns a tuple with the PricePerShare field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetPricePerShareOk() (*float64, bool) {
|
|
if o == nil || IsNil(o.PricePerShare) {
|
|
return nil, false
|
|
}
|
|
return o.PricePerShare, true
|
|
}
|
|
|
|
// HasPricePerShare returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasPricePerShare() bool {
|
|
if o != nil && !IsNil(o.PricePerShare) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetPricePerShare gets a reference to the given float64 and assigns it to the PricePerShare field.
|
|
func (o *CaptableCaptableRound) SetPricePerShare(v float64) {
|
|
o.PricePerShare = &v
|
|
}
|
|
|
|
// GetRaisedAmount returns the RaisedAmount field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetRaisedAmount() float64 {
|
|
if o == nil || IsNil(o.RaisedAmount) {
|
|
var ret float64
|
|
return ret
|
|
}
|
|
return *o.RaisedAmount
|
|
}
|
|
|
|
// GetRaisedAmountOk returns a tuple with the RaisedAmount field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetRaisedAmountOk() (*float64, bool) {
|
|
if o == nil || IsNil(o.RaisedAmount) {
|
|
return nil, false
|
|
}
|
|
return o.RaisedAmount, true
|
|
}
|
|
|
|
// HasRaisedAmount returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasRaisedAmount() bool {
|
|
if o != nil && !IsNil(o.RaisedAmount) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetRaisedAmount gets a reference to the given float64 and assigns it to the RaisedAmount field.
|
|
func (o *CaptableCaptableRound) SetRaisedAmount(v float64) {
|
|
o.RaisedAmount = &v
|
|
}
|
|
|
|
// GetRoundType returns the RoundType field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetRoundType() string {
|
|
if o == nil || IsNil(o.RoundType) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.RoundType
|
|
}
|
|
|
|
// GetRoundTypeOk returns a tuple with the RoundType field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetRoundTypeOk() (*string, bool) {
|
|
if o == nil || IsNil(o.RoundType) {
|
|
return nil, false
|
|
}
|
|
return o.RoundType, true
|
|
}
|
|
|
|
// HasRoundType returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasRoundType() bool {
|
|
if o != nil && !IsNil(o.RoundType) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetRoundType gets a reference to the given string and assigns it to the RoundType field.
|
|
func (o *CaptableCaptableRound) SetRoundType(v string) {
|
|
o.RoundType = &v
|
|
}
|
|
|
|
// GetShareClassId returns the ShareClassId field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetShareClassId() string {
|
|
if o == nil || IsNil(o.ShareClassId) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.ShareClassId
|
|
}
|
|
|
|
// GetShareClassIdOk returns a tuple with the ShareClassId field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetShareClassIdOk() (*string, bool) {
|
|
if o == nil || IsNil(o.ShareClassId) {
|
|
return nil, false
|
|
}
|
|
return o.ShareClassId, true
|
|
}
|
|
|
|
// HasShareClassId returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasShareClassId() bool {
|
|
if o != nil && !IsNil(o.ShareClassId) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetShareClassId gets a reference to the given string and assigns it to the ShareClassId field.
|
|
func (o *CaptableCaptableRound) SetShareClassId(v string) {
|
|
o.ShareClassId = &v
|
|
}
|
|
|
|
// GetStatus returns the Status field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetStatus() string {
|
|
if o == nil || IsNil(o.Status) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Status
|
|
}
|
|
|
|
// GetStatusOk returns a tuple with the Status field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetStatusOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Status) {
|
|
return nil, false
|
|
}
|
|
return o.Status, true
|
|
}
|
|
|
|
// HasStatus returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasStatus() bool {
|
|
if o != nil && !IsNil(o.Status) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetStatus gets a reference to the given string and assigns it to the Status field.
|
|
func (o *CaptableCaptableRound) SetStatus(v string) {
|
|
o.Status = &v
|
|
}
|
|
|
|
// GetTargetAmount returns the TargetAmount field value if set, zero value otherwise.
|
|
func (o *CaptableCaptableRound) GetTargetAmount() float64 {
|
|
if o == nil || IsNil(o.TargetAmount) {
|
|
var ret float64
|
|
return ret
|
|
}
|
|
return *o.TargetAmount
|
|
}
|
|
|
|
// GetTargetAmountOk returns a tuple with the TargetAmount field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *CaptableCaptableRound) GetTargetAmountOk() (*float64, bool) {
|
|
if o == nil || IsNil(o.TargetAmount) {
|
|
return nil, false
|
|
}
|
|
return o.TargetAmount, true
|
|
}
|
|
|
|
// HasTargetAmount returns a boolean if a field has been set.
|
|
func (o *CaptableCaptableRound) HasTargetAmount() bool {
|
|
if o != nil && !IsNil(o.TargetAmount) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetTargetAmount gets a reference to the given float64 and assigns it to the TargetAmount field.
|
|
func (o *CaptableCaptableRound) SetTargetAmount(v float64) {
|
|
o.TargetAmount = &v
|
|
}
|
|
|
|
func (o CaptableCaptableRound) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o CaptableCaptableRound) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.CloseDate) {
|
|
toSerialize["closeDate"] = o.CloseDate
|
|
}
|
|
if !IsNil(o.CreatedAt) {
|
|
toSerialize["createdAt"] = o.CreatedAt
|
|
}
|
|
if !IsNil(o.Id) {
|
|
toSerialize["id"] = o.Id
|
|
}
|
|
if !IsNil(o.Name) {
|
|
toSerialize["name"] = o.Name
|
|
}
|
|
if !IsNil(o.PreMoneyValuation) {
|
|
toSerialize["preMoneyValuation"] = o.PreMoneyValuation
|
|
}
|
|
if !IsNil(o.PricePerShare) {
|
|
toSerialize["pricePerShare"] = o.PricePerShare
|
|
}
|
|
if !IsNil(o.RaisedAmount) {
|
|
toSerialize["raisedAmount"] = o.RaisedAmount
|
|
}
|
|
if !IsNil(o.RoundType) {
|
|
toSerialize["roundType"] = o.RoundType
|
|
}
|
|
if !IsNil(o.ShareClassId) {
|
|
toSerialize["shareClassId"] = o.ShareClassId
|
|
}
|
|
if !IsNil(o.Status) {
|
|
toSerialize["status"] = o.Status
|
|
}
|
|
if !IsNil(o.TargetAmount) {
|
|
toSerialize["targetAmount"] = o.TargetAmount
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *CaptableCaptableRound) UnmarshalJSON(data []byte) (err error) {
|
|
varCaptableCaptableRound := _CaptableCaptableRound{}
|
|
|
|
err = json.Unmarshal(data, &varCaptableCaptableRound)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = CaptableCaptableRound(varCaptableCaptableRound)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "closeDate")
|
|
delete(additionalProperties, "createdAt")
|
|
delete(additionalProperties, "id")
|
|
delete(additionalProperties, "name")
|
|
delete(additionalProperties, "preMoneyValuation")
|
|
delete(additionalProperties, "pricePerShare")
|
|
delete(additionalProperties, "raisedAmount")
|
|
delete(additionalProperties, "roundType")
|
|
delete(additionalProperties, "shareClassId")
|
|
delete(additionalProperties, "status")
|
|
delete(additionalProperties, "targetAmount")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableCaptableCaptableRound struct {
|
|
value *CaptableCaptableRound
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableCaptableCaptableRound) Get() *CaptableCaptableRound {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableCaptableCaptableRound) Set(val *CaptableCaptableRound) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableCaptableCaptableRound) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableCaptableCaptableRound) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableCaptableCaptableRound(val *CaptableCaptableRound) *NullableCaptableCaptableRound {
|
|
return &NullableCaptableCaptableRound{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableCaptableCaptableRound) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableCaptableCaptableRound) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|