mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-07-13 09:02:09 -04:00
127 lines
3.1 KiB
Go
127 lines
3.1 KiB
Go
/*
|
|
Libre Graph API
|
|
|
|
Libre Graph is a free API for cloud collaboration inspired by the MS Graph API.
|
|
|
|
API version: v1.0.8
|
|
*/
|
|
|
|
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
|
|
|
package libregraph
|
|
|
|
import (
|
|
"encoding/json"
|
|
)
|
|
|
|
// checks if the Recipient type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &Recipient{}
|
|
|
|
// Recipient Represents a recipient of an invitation.
|
|
type Recipient struct {
|
|
EmailAddress *EmailAddress `json:"emailAddress,omitempty"`
|
|
}
|
|
|
|
// NewRecipient instantiates a new Recipient 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 NewRecipient() *Recipient {
|
|
this := Recipient{}
|
|
return &this
|
|
}
|
|
|
|
// NewRecipientWithDefaults instantiates a new Recipient 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 NewRecipientWithDefaults() *Recipient {
|
|
this := Recipient{}
|
|
return &this
|
|
}
|
|
|
|
// GetEmailAddress returns the EmailAddress field value if set, zero value otherwise.
|
|
func (o *Recipient) GetEmailAddress() EmailAddress {
|
|
if o == nil || IsNil(o.EmailAddress) {
|
|
var ret EmailAddress
|
|
return ret
|
|
}
|
|
return *o.EmailAddress
|
|
}
|
|
|
|
// GetEmailAddressOk returns a tuple with the EmailAddress field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *Recipient) GetEmailAddressOk() (*EmailAddress, bool) {
|
|
if o == nil || IsNil(o.EmailAddress) {
|
|
return nil, false
|
|
}
|
|
return o.EmailAddress, true
|
|
}
|
|
|
|
// HasEmailAddress returns a boolean if a field has been set.
|
|
func (o *Recipient) HasEmailAddress() bool {
|
|
if o != nil && !IsNil(o.EmailAddress) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetEmailAddress gets a reference to the given EmailAddress and assigns it to the EmailAddress field.
|
|
func (o *Recipient) SetEmailAddress(v EmailAddress) {
|
|
o.EmailAddress = &v
|
|
}
|
|
|
|
func (o Recipient) MarshalJSON() ([]byte, error) {
|
|
toSerialize,err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o Recipient) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.EmailAddress) {
|
|
toSerialize["emailAddress"] = o.EmailAddress
|
|
}
|
|
return toSerialize, nil
|
|
}
|
|
|
|
type NullableRecipient struct {
|
|
value *Recipient
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableRecipient) Get() *Recipient {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableRecipient) Set(val *Recipient) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableRecipient) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableRecipient) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableRecipient(val *Recipient) *NullableRecipient {
|
|
return &NullableRecipient{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableRecipient) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableRecipient) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|
|
|
|
|