mirror of
https://github.com/hanzo-go/sdk.git
synced 2026-11-20 20:13:42 +00:00
155 lines
3.8 KiB
Go
155 lines
3.8 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 GitLinkAll type satisfies the MappedNullable interface at compile time
|
|
var _ MappedNullable = &GitLinkAll{}
|
|
|
|
// GitLinkAll struct for GitLinkAll
|
|
type GitLinkAll struct {
|
|
// Owner is the GitHub account a repository named n is looked for under, as github.com/<owner>/<n>. Empty is the account the estate's table names for the org; an org it does not name must give one.
|
|
Owner *string `json:"owner,omitempty"`
|
|
AdditionalProperties map[string]interface{}
|
|
}
|
|
|
|
type _GitLinkAll GitLinkAll
|
|
|
|
// NewGitLinkAll instantiates a new GitLinkAll 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 NewGitLinkAll() *GitLinkAll {
|
|
this := GitLinkAll{}
|
|
return &this
|
|
}
|
|
|
|
// NewGitLinkAllWithDefaults instantiates a new GitLinkAll 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 NewGitLinkAllWithDefaults() *GitLinkAll {
|
|
this := GitLinkAll{}
|
|
return &this
|
|
}
|
|
|
|
// GetOwner returns the Owner field value if set, zero value otherwise.
|
|
func (o *GitLinkAll) GetOwner() string {
|
|
if o == nil || IsNil(o.Owner) {
|
|
var ret string
|
|
return ret
|
|
}
|
|
return *o.Owner
|
|
}
|
|
|
|
// GetOwnerOk returns a tuple with the Owner field value if set, nil otherwise
|
|
// and a boolean to check if the value has been set.
|
|
func (o *GitLinkAll) GetOwnerOk() (*string, bool) {
|
|
if o == nil || IsNil(o.Owner) {
|
|
return nil, false
|
|
}
|
|
return o.Owner, true
|
|
}
|
|
|
|
// HasOwner returns a boolean if a field has been set.
|
|
func (o *GitLinkAll) HasOwner() bool {
|
|
if o != nil && !IsNil(o.Owner) {
|
|
return true
|
|
}
|
|
|
|
return false
|
|
}
|
|
|
|
// SetOwner gets a reference to the given string and assigns it to the Owner field.
|
|
func (o *GitLinkAll) SetOwner(v string) {
|
|
o.Owner = &v
|
|
}
|
|
|
|
func (o GitLinkAll) MarshalJSON() ([]byte, error) {
|
|
toSerialize, err := o.ToMap()
|
|
if err != nil {
|
|
return []byte{}, err
|
|
}
|
|
return json.Marshal(toSerialize)
|
|
}
|
|
|
|
func (o GitLinkAll) ToMap() (map[string]interface{}, error) {
|
|
toSerialize := map[string]interface{}{}
|
|
if !IsNil(o.Owner) {
|
|
toSerialize["owner"] = o.Owner
|
|
}
|
|
|
|
for key, value := range o.AdditionalProperties {
|
|
toSerialize[key] = value
|
|
}
|
|
|
|
return toSerialize, nil
|
|
}
|
|
|
|
func (o *GitLinkAll) UnmarshalJSON(data []byte) (err error) {
|
|
varGitLinkAll := _GitLinkAll{}
|
|
|
|
err = json.Unmarshal(data, &varGitLinkAll)
|
|
|
|
if err != nil {
|
|
return err
|
|
}
|
|
|
|
*o = GitLinkAll(varGitLinkAll)
|
|
|
|
additionalProperties := make(map[string]interface{})
|
|
|
|
if err = json.Unmarshal(data, &additionalProperties); err == nil {
|
|
delete(additionalProperties, "owner")
|
|
o.AdditionalProperties = additionalProperties
|
|
}
|
|
|
|
return err
|
|
}
|
|
|
|
type NullableGitLinkAll struct {
|
|
value *GitLinkAll
|
|
isSet bool
|
|
}
|
|
|
|
func (v NullableGitLinkAll) Get() *GitLinkAll {
|
|
return v.value
|
|
}
|
|
|
|
func (v *NullableGitLinkAll) Set(val *GitLinkAll) {
|
|
v.value = val
|
|
v.isSet = true
|
|
}
|
|
|
|
func (v NullableGitLinkAll) IsSet() bool {
|
|
return v.isSet
|
|
}
|
|
|
|
func (v *NullableGitLinkAll) Unset() {
|
|
v.value = nil
|
|
v.isSet = false
|
|
}
|
|
|
|
func NewNullableGitLinkAll(val *GitLinkAll) *NullableGitLinkAll {
|
|
return &NullableGitLinkAll{value: val, isSet: true}
|
|
}
|
|
|
|
func (v NullableGitLinkAll) MarshalJSON() ([]byte, error) {
|
|
return json.Marshal(v.value)
|
|
}
|
|
|
|
func (v *NullableGitLinkAll) UnmarshalJSON(src []byte) error {
|
|
v.isSet = true
|
|
return json.Unmarshal(src, &v.value)
|
|
}
|