更新文档内容
This commit is contained in:
421
model_schema_search_object_user_info.go
Normal file
421
model_schema_search_object_user_info.go
Normal file
@@ -0,0 +1,421 @@
|
||||
/*
|
||||
No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
||||
|
||||
API version: 1.0.0
|
||||
*/
|
||||
|
||||
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
||||
|
||||
package openapi
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
)
|
||||
|
||||
// checks if the SchemaSearchObjectUserInfo type satisfies the MappedNullable interface at compile time
|
||||
var _ MappedNullable = &SchemaSearchObjectUserInfo{}
|
||||
|
||||
// SchemaSearchObjectUserInfo user info
|
||||
type SchemaSearchObjectUserInfo struct {
|
||||
// avatar
|
||||
Avatar *string `json:"avatar,omitempty"`
|
||||
// display_name
|
||||
DisplayName *string `json:"display_name,omitempty"`
|
||||
// user_id
|
||||
Id *string `json:"id,omitempty"`
|
||||
// ip info
|
||||
IpInfo *string `json:"ip_info,omitempty"`
|
||||
// location
|
||||
Location *string `json:"location,omitempty"`
|
||||
// rank
|
||||
Rank *int32 `json:"rank,omitempty"`
|
||||
// status
|
||||
Status *string `json:"status,omitempty"`
|
||||
// name
|
||||
Username *string `json:"username,omitempty"`
|
||||
// website
|
||||
Website *string `json:"website,omitempty"`
|
||||
}
|
||||
|
||||
// NewSchemaSearchObjectUserInfo instantiates a new SchemaSearchObjectUserInfo 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 NewSchemaSearchObjectUserInfo() *SchemaSearchObjectUserInfo {
|
||||
this := SchemaSearchObjectUserInfo{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// NewSchemaSearchObjectUserInfoWithDefaults instantiates a new SchemaSearchObjectUserInfo 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 NewSchemaSearchObjectUserInfoWithDefaults() *SchemaSearchObjectUserInfo {
|
||||
this := SchemaSearchObjectUserInfo{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// GetAvatar returns the Avatar field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetAvatar() string {
|
||||
if o == nil || IsNil(o.Avatar) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Avatar
|
||||
}
|
||||
|
||||
// GetAvatarOk returns a tuple with the Avatar field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetAvatarOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Avatar) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Avatar, true
|
||||
}
|
||||
|
||||
// HasAvatar returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasAvatar() bool {
|
||||
if o != nil && !IsNil(o.Avatar) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetAvatar gets a reference to the given string and assigns it to the Avatar field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetAvatar(v string) {
|
||||
o.Avatar = &v
|
||||
}
|
||||
|
||||
// GetDisplayName returns the DisplayName field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetDisplayName() string {
|
||||
if o == nil || IsNil(o.DisplayName) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.DisplayName
|
||||
}
|
||||
|
||||
// GetDisplayNameOk returns a tuple with the DisplayName field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetDisplayNameOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.DisplayName) {
|
||||
return nil, false
|
||||
}
|
||||
return o.DisplayName, true
|
||||
}
|
||||
|
||||
// HasDisplayName returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasDisplayName() bool {
|
||||
if o != nil && !IsNil(o.DisplayName) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetDisplayName gets a reference to the given string and assigns it to the DisplayName field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetDisplayName(v string) {
|
||||
o.DisplayName = &v
|
||||
}
|
||||
|
||||
// GetId returns the Id field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) 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 *SchemaSearchObjectUserInfo) 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 *SchemaSearchObjectUserInfo) 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 *SchemaSearchObjectUserInfo) SetId(v string) {
|
||||
o.Id = &v
|
||||
}
|
||||
|
||||
// GetIpInfo returns the IpInfo field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetIpInfo() string {
|
||||
if o == nil || IsNil(o.IpInfo) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.IpInfo
|
||||
}
|
||||
|
||||
// GetIpInfoOk returns a tuple with the IpInfo field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetIpInfoOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.IpInfo) {
|
||||
return nil, false
|
||||
}
|
||||
return o.IpInfo, true
|
||||
}
|
||||
|
||||
// HasIpInfo returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasIpInfo() bool {
|
||||
if o != nil && !IsNil(o.IpInfo) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetIpInfo gets a reference to the given string and assigns it to the IpInfo field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetIpInfo(v string) {
|
||||
o.IpInfo = &v
|
||||
}
|
||||
|
||||
// GetLocation returns the Location field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetLocation() string {
|
||||
if o == nil || IsNil(o.Location) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Location
|
||||
}
|
||||
|
||||
// GetLocationOk returns a tuple with the Location field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetLocationOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Location) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Location, true
|
||||
}
|
||||
|
||||
// HasLocation returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasLocation() bool {
|
||||
if o != nil && !IsNil(o.Location) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetLocation gets a reference to the given string and assigns it to the Location field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetLocation(v string) {
|
||||
o.Location = &v
|
||||
}
|
||||
|
||||
// GetRank returns the Rank field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetRank() int32 {
|
||||
if o == nil || IsNil(o.Rank) {
|
||||
var ret int32
|
||||
return ret
|
||||
}
|
||||
return *o.Rank
|
||||
}
|
||||
|
||||
// GetRankOk returns a tuple with the Rank field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetRankOk() (*int32, bool) {
|
||||
if o == nil || IsNil(o.Rank) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Rank, true
|
||||
}
|
||||
|
||||
// HasRank returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasRank() bool {
|
||||
if o != nil && !IsNil(o.Rank) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetRank gets a reference to the given int32 and assigns it to the Rank field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetRank(v int32) {
|
||||
o.Rank = &v
|
||||
}
|
||||
|
||||
// GetStatus returns the Status field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) 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 *SchemaSearchObjectUserInfo) 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 *SchemaSearchObjectUserInfo) 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 *SchemaSearchObjectUserInfo) SetStatus(v string) {
|
||||
o.Status = &v
|
||||
}
|
||||
|
||||
// GetUsername returns the Username field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetUsername() string {
|
||||
if o == nil || IsNil(o.Username) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Username
|
||||
}
|
||||
|
||||
// GetUsernameOk returns a tuple with the Username field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetUsernameOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Username) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Username, true
|
||||
}
|
||||
|
||||
// HasUsername returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasUsername() bool {
|
||||
if o != nil && !IsNil(o.Username) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetUsername gets a reference to the given string and assigns it to the Username field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetUsername(v string) {
|
||||
o.Username = &v
|
||||
}
|
||||
|
||||
// GetWebsite returns the Website field value if set, zero value otherwise.
|
||||
func (o *SchemaSearchObjectUserInfo) GetWebsite() string {
|
||||
if o == nil || IsNil(o.Website) {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Website
|
||||
}
|
||||
|
||||
// GetWebsiteOk returns a tuple with the Website field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) GetWebsiteOk() (*string, bool) {
|
||||
if o == nil || IsNil(o.Website) {
|
||||
return nil, false
|
||||
}
|
||||
return o.Website, true
|
||||
}
|
||||
|
||||
// HasWebsite returns a boolean if a field has been set.
|
||||
func (o *SchemaSearchObjectUserInfo) HasWebsite() bool {
|
||||
if o != nil && !IsNil(o.Website) {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetWebsite gets a reference to the given string and assigns it to the Website field.
|
||||
func (o *SchemaSearchObjectUserInfo) SetWebsite(v string) {
|
||||
o.Website = &v
|
||||
}
|
||||
|
||||
func (o SchemaSearchObjectUserInfo) MarshalJSON() ([]byte, error) {
|
||||
toSerialize,err := o.ToMap()
|
||||
if err != nil {
|
||||
return []byte{}, err
|
||||
}
|
||||
return json.Marshal(toSerialize)
|
||||
}
|
||||
|
||||
func (o SchemaSearchObjectUserInfo) ToMap() (map[string]interface{}, error) {
|
||||
toSerialize := map[string]interface{}{}
|
||||
if !IsNil(o.Avatar) {
|
||||
toSerialize["avatar"] = o.Avatar
|
||||
}
|
||||
if !IsNil(o.DisplayName) {
|
||||
toSerialize["display_name"] = o.DisplayName
|
||||
}
|
||||
if !IsNil(o.Id) {
|
||||
toSerialize["id"] = o.Id
|
||||
}
|
||||
if !IsNil(o.IpInfo) {
|
||||
toSerialize["ip_info"] = o.IpInfo
|
||||
}
|
||||
if !IsNil(o.Location) {
|
||||
toSerialize["location"] = o.Location
|
||||
}
|
||||
if !IsNil(o.Rank) {
|
||||
toSerialize["rank"] = o.Rank
|
||||
}
|
||||
if !IsNil(o.Status) {
|
||||
toSerialize["status"] = o.Status
|
||||
}
|
||||
if !IsNil(o.Username) {
|
||||
toSerialize["username"] = o.Username
|
||||
}
|
||||
if !IsNil(o.Website) {
|
||||
toSerialize["website"] = o.Website
|
||||
}
|
||||
return toSerialize, nil
|
||||
}
|
||||
|
||||
type NullableSchemaSearchObjectUserInfo struct {
|
||||
value *SchemaSearchObjectUserInfo
|
||||
isSet bool
|
||||
}
|
||||
|
||||
func (v NullableSchemaSearchObjectUserInfo) Get() *SchemaSearchObjectUserInfo {
|
||||
return v.value
|
||||
}
|
||||
|
||||
func (v *NullableSchemaSearchObjectUserInfo) Set(val *SchemaSearchObjectUserInfo) {
|
||||
v.value = val
|
||||
v.isSet = true
|
||||
}
|
||||
|
||||
func (v NullableSchemaSearchObjectUserInfo) IsSet() bool {
|
||||
return v.isSet
|
||||
}
|
||||
|
||||
func (v *NullableSchemaSearchObjectUserInfo) Unset() {
|
||||
v.value = nil
|
||||
v.isSet = false
|
||||
}
|
||||
|
||||
func NewNullableSchemaSearchObjectUserInfo(val *SchemaSearchObjectUserInfo) *NullableSchemaSearchObjectUserInfo {
|
||||
return &NullableSchemaSearchObjectUserInfo{value: val, isSet: true}
|
||||
}
|
||||
|
||||
func (v NullableSchemaSearchObjectUserInfo) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(v.value)
|
||||
}
|
||||
|
||||
func (v *NullableSchemaSearchObjectUserInfo) UnmarshalJSON(src []byte) error {
|
||||
v.isSet = true
|
||||
return json.Unmarshal(src, &v.value)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user