Files
sdk/model_captable_captable_equity_plan.go

459 lines
14 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 CaptableCaptableEquityPlan type satisfies the MappedNullable interface at compile time
var _ MappedNullable = &CaptableCaptableEquityPlan{}
// CaptableCaptableEquityPlan struct for CaptableCaptableEquityPlan
type CaptableCaptableEquityPlan struct {
// BoardApprovalDate is the ISO date the board approved the plan.
BoardApprovalDate *string `json:"boardApprovalDate,omitempty"`
// Comments is free-form notes on the plan.
Comments *string `json:"comments,omitempty"`
// CreatedAt is when the plan was recorded, in unix milliseconds.
CreatedAt *int64 `json:"createdAt,omitempty"`
// DefaultCancellatonBehavior is what happens to cancelled grants, RETIRE or RETURN_TO_POOL. The key is spelled as the cap-table wire spells it.
DefaultCancellatonBehavior *string `json:"defaultCancellatonBehavior,omitempty"`
// ID is the equity plan id.
Id *string `json:"id,omitempty"`
// InitialSharesReserved is how many shares the plan reserves.
InitialSharesReserved *int64 `json:"initialSharesReserved,omitempty"`
// Name is the plan name, e.g. \"2026 Stock Option Plan\".
Name *string `json:"name,omitempty"`
// PlanEffectiveDate is the ISO date the plan takes effect.
PlanEffectiveDate *string `json:"planEffectiveDate,omitempty"`
// ShareClassID is the class the reserved shares come from.
ShareClassId *string `json:"shareClassId,omitempty"`
AdditionalProperties map[string]interface{}
}
type _CaptableCaptableEquityPlan CaptableCaptableEquityPlan
// NewCaptableCaptableEquityPlan instantiates a new CaptableCaptableEquityPlan 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 NewCaptableCaptableEquityPlan() *CaptableCaptableEquityPlan {
this := CaptableCaptableEquityPlan{}
return &this
}
// NewCaptableCaptableEquityPlanWithDefaults instantiates a new CaptableCaptableEquityPlan 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 NewCaptableCaptableEquityPlanWithDefaults() *CaptableCaptableEquityPlan {
this := CaptableCaptableEquityPlan{}
return &this
}
// GetBoardApprovalDate returns the BoardApprovalDate field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) GetBoardApprovalDate() string {
if o == nil || IsNil(o.BoardApprovalDate) {
var ret string
return ret
}
return *o.BoardApprovalDate
}
// GetBoardApprovalDateOk returns a tuple with the BoardApprovalDate field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CaptableCaptableEquityPlan) GetBoardApprovalDateOk() (*string, bool) {
if o == nil || IsNil(o.BoardApprovalDate) {
return nil, false
}
return o.BoardApprovalDate, true
}
// HasBoardApprovalDate returns a boolean if a field has been set.
func (o *CaptableCaptableEquityPlan) HasBoardApprovalDate() bool {
if o != nil && !IsNil(o.BoardApprovalDate) {
return true
}
return false
}
// SetBoardApprovalDate gets a reference to the given string and assigns it to the BoardApprovalDate field.
func (o *CaptableCaptableEquityPlan) SetBoardApprovalDate(v string) {
o.BoardApprovalDate = &v
}
// GetComments returns the Comments field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) GetComments() string {
if o == nil || IsNil(o.Comments) {
var ret string
return ret
}
return *o.Comments
}
// GetCommentsOk returns a tuple with the Comments field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CaptableCaptableEquityPlan) GetCommentsOk() (*string, bool) {
if o == nil || IsNil(o.Comments) {
return nil, false
}
return o.Comments, true
}
// HasComments returns a boolean if a field has been set.
func (o *CaptableCaptableEquityPlan) HasComments() bool {
if o != nil && !IsNil(o.Comments) {
return true
}
return false
}
// SetComments gets a reference to the given string and assigns it to the Comments field.
func (o *CaptableCaptableEquityPlan) SetComments(v string) {
o.Comments = &v
}
// GetCreatedAt returns the CreatedAt field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) SetCreatedAt(v int64) {
o.CreatedAt = &v
}
// GetDefaultCancellatonBehavior returns the DefaultCancellatonBehavior field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) GetDefaultCancellatonBehavior() string {
if o == nil || IsNil(o.DefaultCancellatonBehavior) {
var ret string
return ret
}
return *o.DefaultCancellatonBehavior
}
// GetDefaultCancellatonBehaviorOk returns a tuple with the DefaultCancellatonBehavior field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CaptableCaptableEquityPlan) GetDefaultCancellatonBehaviorOk() (*string, bool) {
if o == nil || IsNil(o.DefaultCancellatonBehavior) {
return nil, false
}
return o.DefaultCancellatonBehavior, true
}
// HasDefaultCancellatonBehavior returns a boolean if a field has been set.
func (o *CaptableCaptableEquityPlan) HasDefaultCancellatonBehavior() bool {
if o != nil && !IsNil(o.DefaultCancellatonBehavior) {
return true
}
return false
}
// SetDefaultCancellatonBehavior gets a reference to the given string and assigns it to the DefaultCancellatonBehavior field.
func (o *CaptableCaptableEquityPlan) SetDefaultCancellatonBehavior(v string) {
o.DefaultCancellatonBehavior = &v
}
// GetId returns the Id field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) SetId(v string) {
o.Id = &v
}
// GetInitialSharesReserved returns the InitialSharesReserved field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) GetInitialSharesReserved() int64 {
if o == nil || IsNil(o.InitialSharesReserved) {
var ret int64
return ret
}
return *o.InitialSharesReserved
}
// GetInitialSharesReservedOk returns a tuple with the InitialSharesReserved field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CaptableCaptableEquityPlan) GetInitialSharesReservedOk() (*int64, bool) {
if o == nil || IsNil(o.InitialSharesReserved) {
return nil, false
}
return o.InitialSharesReserved, true
}
// HasInitialSharesReserved returns a boolean if a field has been set.
func (o *CaptableCaptableEquityPlan) HasInitialSharesReserved() bool {
if o != nil && !IsNil(o.InitialSharesReserved) {
return true
}
return false
}
// SetInitialSharesReserved gets a reference to the given int64 and assigns it to the InitialSharesReserved field.
func (o *CaptableCaptableEquityPlan) SetInitialSharesReserved(v int64) {
o.InitialSharesReserved = &v
}
// GetName returns the Name field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) SetName(v string) {
o.Name = &v
}
// GetPlanEffectiveDate returns the PlanEffectiveDate field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) GetPlanEffectiveDate() string {
if o == nil || IsNil(o.PlanEffectiveDate) {
var ret string
return ret
}
return *o.PlanEffectiveDate
}
// GetPlanEffectiveDateOk returns a tuple with the PlanEffectiveDate field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *CaptableCaptableEquityPlan) GetPlanEffectiveDateOk() (*string, bool) {
if o == nil || IsNil(o.PlanEffectiveDate) {
return nil, false
}
return o.PlanEffectiveDate, true
}
// HasPlanEffectiveDate returns a boolean if a field has been set.
func (o *CaptableCaptableEquityPlan) HasPlanEffectiveDate() bool {
if o != nil && !IsNil(o.PlanEffectiveDate) {
return true
}
return false
}
// SetPlanEffectiveDate gets a reference to the given string and assigns it to the PlanEffectiveDate field.
func (o *CaptableCaptableEquityPlan) SetPlanEffectiveDate(v string) {
o.PlanEffectiveDate = &v
}
// GetShareClassId returns the ShareClassId field value if set, zero value otherwise.
func (o *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) 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 *CaptableCaptableEquityPlan) SetShareClassId(v string) {
o.ShareClassId = &v
}
func (o CaptableCaptableEquityPlan) MarshalJSON() ([]byte, error) {
toSerialize, err := o.ToMap()
if err != nil {
return []byte{}, err
}
return json.Marshal(toSerialize)
}
func (o CaptableCaptableEquityPlan) ToMap() (map[string]interface{}, error) {
toSerialize := map[string]interface{}{}
if !IsNil(o.BoardApprovalDate) {
toSerialize["boardApprovalDate"] = o.BoardApprovalDate
}
if !IsNil(o.Comments) {
toSerialize["comments"] = o.Comments
}
if !IsNil(o.CreatedAt) {
toSerialize["createdAt"] = o.CreatedAt
}
if !IsNil(o.DefaultCancellatonBehavior) {
toSerialize["defaultCancellatonBehavior"] = o.DefaultCancellatonBehavior
}
if !IsNil(o.Id) {
toSerialize["id"] = o.Id
}
if !IsNil(o.InitialSharesReserved) {
toSerialize["initialSharesReserved"] = o.InitialSharesReserved
}
if !IsNil(o.Name) {
toSerialize["name"] = o.Name
}
if !IsNil(o.PlanEffectiveDate) {
toSerialize["planEffectiveDate"] = o.PlanEffectiveDate
}
if !IsNil(o.ShareClassId) {
toSerialize["shareClassId"] = o.ShareClassId
}
for key, value := range o.AdditionalProperties {
toSerialize[key] = value
}
return toSerialize, nil
}
func (o *CaptableCaptableEquityPlan) UnmarshalJSON(data []byte) (err error) {
varCaptableCaptableEquityPlan := _CaptableCaptableEquityPlan{}
err = json.Unmarshal(data, &varCaptableCaptableEquityPlan)
if err != nil {
return err
}
*o = CaptableCaptableEquityPlan(varCaptableCaptableEquityPlan)
additionalProperties := make(map[string]interface{})
if err = json.Unmarshal(data, &additionalProperties); err == nil {
delete(additionalProperties, "boardApprovalDate")
delete(additionalProperties, "comments")
delete(additionalProperties, "createdAt")
delete(additionalProperties, "defaultCancellatonBehavior")
delete(additionalProperties, "id")
delete(additionalProperties, "initialSharesReserved")
delete(additionalProperties, "name")
delete(additionalProperties, "planEffectiveDate")
delete(additionalProperties, "shareClassId")
o.AdditionalProperties = additionalProperties
}
return err
}
type NullableCaptableCaptableEquityPlan struct {
value *CaptableCaptableEquityPlan
isSet bool
}
func (v NullableCaptableCaptableEquityPlan) Get() *CaptableCaptableEquityPlan {
return v.value
}
func (v *NullableCaptableCaptableEquityPlan) Set(val *CaptableCaptableEquityPlan) {
v.value = val
v.isSet = true
}
func (v NullableCaptableCaptableEquityPlan) IsSet() bool {
return v.isSet
}
func (v *NullableCaptableCaptableEquityPlan) Unset() {
v.value = nil
v.isSet = false
}
func NewNullableCaptableCaptableEquityPlan(val *CaptableCaptableEquityPlan) *NullableCaptableCaptableEquityPlan {
return &NullableCaptableCaptableEquityPlan{value: val, isSet: true}
}
func (v NullableCaptableCaptableEquityPlan) MarshalJSON() ([]byte, error) {
return json.Marshal(v.value)
}
func (v *NullableCaptableCaptableEquityPlan) UnmarshalJSON(src []byte) error {
v.isSet = true
return json.Unmarshal(src, &v.value)
}