mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
459 lines
14 KiB
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 DataroomDataroomLinkCreate type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &DataroomDataroomLinkCreate{}
|
|
|
|
// DataroomDataroomLinkCreate struct for DataroomDataroomLinkCreate
|
|
type DataroomDataroomLinkCreate struct {
|
|
AllowDownload interface{} `json:"allowDownload,omitempty"`
|
|
// AllowList narrows which addresses pass the email gate. Optional; an entry may be a full address (\"[email protected]\"), an \"@domain.com\" suffix, or a bare \"domain.com\". An omitted or EMPTY list admits everyone, so a link with no list enforces the email gate alone.
|
|
AllowList []interface{} `json:"allowList,omitempty"`
|
|
DataroomId interface{} `json:"dataroomId,omitempty"`
|
|
// DenyList rejects addresses, in the same three forms as the allow list. Optional. It is checked BEFORE the allow list, so deny always wins.
|
|
DenyList []interface{} `json:"denyList,omitempty"`
|
|
DocumentId interface{} `json:"documentId,omitempty"`
|
|
EmailProtected interface{} `json:"emailProtected,omitempty"`
|
|
ExpiresAt interface{} `json:"expiresAt,omitempty"`
|
|
Name interface{} `json:"name,omitempty"`
|
|
Password interface{} `json:"password,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _DataroomDataroomLinkCreate DataroomDataroomLinkCreate
|
|
|
|
// NewDataroomDataroomLinkCreate instantiates a new DataroomDataroomLinkCreate 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 NewDataroomDataroomLinkCreate() *DataroomDataroomLinkCreate {
|
|
this := DataroomDataroomLinkCreate{}
|
|
return &this
|
|
}
|
|
|
|
// NewDataroomDataroomLinkCreateWithDefaults instantiates a new DataroomDataroomLinkCreate 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 NewDataroomDataroomLinkCreateWithDefaults() *DataroomDataroomLinkCreate {
|
|
this := DataroomDataroomLinkCreate{}
|
|
return &this
|
|
}
|
|
|
|
// GetAllowDownload returns the AllowDownload field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetAllowDownload() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
return ret
|
|
}
|
|
return o.AllowDownload
|
|
}
|
|
|
|
// GetAllowDownloadOk returns a tuple with the AllowDownload 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 *DataroomDataroomLinkCreate) GetAllowDownloadOk() (*interface{}, bool) {
|
|
if o == nil || IsNil(o.AllowDownload) {
|
|
return nil, false
|
|
}
|
|
return &o.AllowDownload, true
|
|
}
|
|
|
|
// HasAllowDownload returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasAllowDownload() bool {
|
|
if o != nil && !IsNil(o.AllowDownload) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetAllowDownload gets a reference to the given interface{} and assigns it to the AllowDownload field.
|
|
func (o *DataroomDataroomLinkCreate) SetAllowDownload(v interface{}) {
|
|
o.AllowDownload = v
|
|
}
|
|
|
|
// GetAllowList returns the AllowList field value if set, zero value otherwise.
|
|
func (o *DataroomDataroomLinkCreate) GetAllowList() []interface{} {
|
|
if o == nil || IsNil(o.AllowList) {
|
|
var ret []interface{}
|
|
return ret
|
|
}
|
|
return o.AllowList
|
|
}
|
|
|
|
// GetAllowListOk returns a tuple with the AllowList field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *DataroomDataroomLinkCreate) GetAllowListOk() ([]interface{}, bool) {
|
|
if o == nil || IsNil(o.AllowList) {
|
|
return nil, false
|
|
}
|
|
return o.AllowList, true
|
|
}
|
|
|
|
// HasAllowList returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasAllowList() bool {
|
|
if o != nil && !IsNil(o.AllowList) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetAllowList gets a reference to the given []interface{} and assigns it to the AllowList field.
|
|
func (o *DataroomDataroomLinkCreate) SetAllowList(v []interface{}) {
|
|
o.AllowList = v
|
|
}
|
|
|
|
// GetDataroomId returns the DataroomId field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetDataroomId() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
return ret
|
|
}
|
|
return o.DataroomId
|
|
}
|
|
|
|
// GetDataroomIdOk returns a tuple with the DataroomId 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 *DataroomDataroomLinkCreate) GetDataroomIdOk() (*interface{}, bool) {
|
|
if o == nil || IsNil(o.DataroomId) {
|
|
return nil, false
|
|
}
|
|
return &o.DataroomId, true
|
|
}
|
|
|
|
// HasDataroomId returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasDataroomId() bool {
|
|
if o != nil && !IsNil(o.DataroomId) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetDataroomId gets a reference to the given interface{} and assigns it to the DataroomId field.
|
|
func (o *DataroomDataroomLinkCreate) SetDataroomId(v interface{}) {
|
|
o.DataroomId = v
|
|
}
|
|
|
|
// GetDenyList returns the DenyList field value if set, zero value otherwise.
|
|
func (o *DataroomDataroomLinkCreate) GetDenyList() []interface{} {
|
|
if o == nil || IsNil(o.DenyList) {
|
|
var ret []interface{}
|
|
return ret
|
|
}
|
|
return o.DenyList
|
|
}
|
|
|
|
// GetDenyListOk returns a tuple with the DenyList field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *DataroomDataroomLinkCreate) GetDenyListOk() ([]interface{}, bool) {
|
|
if o == nil || IsNil(o.DenyList) {
|
|
return nil, false
|
|
}
|
|
return o.DenyList, true
|
|
}
|
|
|
|
// HasDenyList returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasDenyList() bool {
|
|
if o != nil && !IsNil(o.DenyList) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetDenyList gets a reference to the given []interface{} and assigns it to the DenyList field.
|
|
func (o *DataroomDataroomLinkCreate) SetDenyList(v []interface{}) {
|
|
o.DenyList = v
|
|
}
|
|
|
|
// GetDocumentId returns the DocumentId field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetDocumentId() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
return ret
|
|
}
|
|
return o.DocumentId
|
|
}
|
|
|
|
// GetDocumentIdOk returns a tuple with the DocumentId 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 *DataroomDataroomLinkCreate) GetDocumentIdOk() (*interface{}, bool) {
|
|
if o == nil || IsNil(o.DocumentId) {
|
|
return nil, false
|
|
}
|
|
return &o.DocumentId, true
|
|
}
|
|
|
|
// HasDocumentId returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasDocumentId() bool {
|
|
if o != nil && !IsNil(o.DocumentId) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetDocumentId gets a reference to the given interface{} and assigns it to the DocumentId field.
|
|
func (o *DataroomDataroomLinkCreate) SetDocumentId(v interface{}) {
|
|
o.DocumentId = v
|
|
}
|
|
|
|
// GetEmailProtected returns the EmailProtected field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetEmailProtected() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
return ret
|
|
}
|
|
return o.EmailProtected
|
|
}
|
|
|
|
// GetEmailProtectedOk returns a tuple with the EmailProtected 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 *DataroomDataroomLinkCreate) GetEmailProtectedOk() (*interface{}, bool) {
|
|
if o == nil || IsNil(o.EmailProtected) {
|
|
return nil, false
|
|
}
|
|
return &o.EmailProtected, true
|
|
}
|
|
|
|
// HasEmailProtected returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasEmailProtected() bool {
|
|
if o != nil && !IsNil(o.EmailProtected) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetEmailProtected gets a reference to the given interface{} and assigns it to the EmailProtected field.
|
|
func (o *DataroomDataroomLinkCreate) SetEmailProtected(v interface{}) {
|
|
o.EmailProtected = v
|
|
}
|
|
|
|
// GetExpiresAt returns the ExpiresAt field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetExpiresAt() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
return ret
|
|
}
|
|
return o.ExpiresAt
|
|
}
|
|
|
|
// GetExpiresAtOk returns a tuple with the ExpiresAt 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 *DataroomDataroomLinkCreate) GetExpiresAtOk() (*interface{}, bool) {
|
|
if o == nil || IsNil(o.ExpiresAt) {
|
|
return nil, false
|
|
}
|
|
return &o.ExpiresAt, true
|
|
}
|
|
|
|
// HasExpiresAt returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasExpiresAt() bool {
|
|
if o != nil && !IsNil(o.ExpiresAt) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetExpiresAt gets a reference to the given interface{} and assigns it to the ExpiresAt field.
|
|
func (o *DataroomDataroomLinkCreate) SetExpiresAt(v interface{}) {
|
|
o.ExpiresAt = v
|
|
}
|
|
|
|
// GetName returns the Name field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetName() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
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.
|
|
// NOTE: If the value is an explicit nil, `nil, true` will be returned
|
|
func (o *DataroomDataroomLinkCreate) GetNameOk() (*interface{}, 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 *DataroomDataroomLinkCreate) HasName() bool {
|
|
if o != nil && !IsNil(o.Name) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetName gets a reference to the given interface{} and assigns it to the Name field.
|
|
func (o *DataroomDataroomLinkCreate) SetName(v interface{}) {
|
|
o.Name = v
|
|
}
|
|
|
|
// GetPassword returns the Password field value if set, zero value otherwise (both if not set or set to explicit null).
|
|
func (o *DataroomDataroomLinkCreate) GetPassword() interface{} {
|
|
if o == nil {
|
|
var ret interface{}
|
|
return ret
|
|
}
|
|
return o.Password
|
|
}
|
|
|
|
// GetPasswordOk returns a tuple with the Password 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 *DataroomDataroomLinkCreate) GetPasswordOk() (*interface{}, bool) {
|
|
if o == nil || IsNil(o.Password) {
|
|
return nil, false
|
|
}
|
|
return &o.Password, true
|
|
}
|
|
|
|
// HasPassword returns a boolean if a field has been set.
|
|
func (o *DataroomDataroomLinkCreate) HasPassword() bool {
|
|
if o != nil && !IsNil(o.Password) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetPassword gets a reference to the given interface{} and assigns it to the Password field.
|
|
func (o *DataroomDataroomLinkCreate) SetPassword(v interface{}) {
|
|
o.Password = v
|
|
}
|
|
|
|
func (o DataroomDataroomLinkCreate) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o DataroomDataroomLinkCreate) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if o.AllowDownload != nil {
|
|
toSerialize["allowDownload"] = o.AllowDownload
|
|
}
|
|
if !IsNil(o.AllowList) {
|
|
toSerialize["allowList"] = o.AllowList
|
|
}
|
|
if o.DataroomId != nil {
|
|
toSerialize["dataroomId"] = o.DataroomId
|
|
}
|
|
if !IsNil(o.DenyList) {
|
|
toSerialize["denyList"] = o.DenyList
|
|
}
|
|
if o.DocumentId != nil {
|
|
toSerialize["documentId"] = o.DocumentId
|
|
}
|
|
if o.EmailProtected != nil {
|
|
toSerialize["emailProtected"] = o.EmailProtected
|
|
}
|
|
if o.ExpiresAt != nil {
|
|
toSerialize["expiresAt"] = o.ExpiresAt
|
|
}
|
|
if o.Name != nil {
|
|
toSerialize["name"] = o.Name
|
|
}
|
|
if o.Password != nil {
|
|
toSerialize["password"] = o.Password
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *DataroomDataroomLinkCreate) UnmarshalJSON(data []byte) (err error) {
|
|
varDataroomDataroomLinkCreate := _DataroomDataroomLinkCreate{}
|
|
|
|
err = json.Unmarshal(data, &varDataroomDataroomLinkCreate)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = DataroomDataroomLinkCreate(varDataroomDataroomLinkCreate)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "allowDownload")
|
|
delete(additionalProperties, "allowList")
|
|
delete(additionalProperties, "dataroomId")
|
|
delete(additionalProperties, "denyList")
|
|
delete(additionalProperties, "documentId")
|
|
delete(additionalProperties, "emailProtected")
|
|
delete(additionalProperties, "expiresAt")
|
|
delete(additionalProperties, "name")
|
|
delete(additionalProperties, "password")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableDataroomDataroomLinkCreate struct {
|
|
value *DataroomDataroomLinkCreate
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableDataroomDataroomLinkCreate) Get() *DataroomDataroomLinkCreate {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableDataroomDataroomLinkCreate) Set(val *DataroomDataroomLinkCreate) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableDataroomDataroomLinkCreate) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableDataroomDataroomLinkCreate) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableDataroomDataroomLinkCreate(val *DataroomDataroomLinkCreate) *NullableDataroomDataroomLinkCreate {
|
|
return &NullableDataroomDataroomLinkCreate{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableDataroomDataroomLinkCreate) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableDataroomDataroomLinkCreate) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|