/* 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 answer_sdk import ( "encoding/json" ) // checks if the SchemaGetCommentResp type satisfies the MappedNullable interface at compile time var _ MappedNullable = &SchemaGetCommentResp{} // SchemaGetCommentResp struct for SchemaGetCommentResp type SchemaGetCommentResp struct { // comment id CommentId *string `json:"comment_id,omitempty"` // create time CreatedAt *int32 `json:"created_at,omitempty"` // current user if already vote this comment IsVote *bool `json:"is_vote,omitempty"` // MemberActions MemberActions []SchemaPermissionMemberAction `json:"member_actions,omitempty"` // object id ObjectId *string `json:"object_id,omitempty"` // original comment content OriginalText *string `json:"original_text,omitempty"` // parsed comment content ParsedText *string `json:"parsed_text,omitempty"` // reply comment id ReplyCommentId *string `json:"reply_comment_id,omitempty"` // reply user display name ReplyUserDisplayName *string `json:"reply_user_display_name,omitempty"` // reply user id ReplyUserId *string `json:"reply_user_id,omitempty"` // reply user status ReplyUserStatus *string `json:"reply_user_status,omitempty"` // reply user username ReplyUsername *string `json:"reply_username,omitempty"` // user avatar UserAvatar *string `json:"user_avatar,omitempty"` // user display name UserDisplayName *string `json:"user_display_name,omitempty"` // user id UserId *string `json:"user_id,omitempty"` // user status UserStatus *string `json:"user_status,omitempty"` // username Username *string `json:"username,omitempty"` // user vote amount VoteCount *int32 `json:"vote_count,omitempty"` } // NewSchemaGetCommentResp instantiates a new SchemaGetCommentResp 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 NewSchemaGetCommentResp() *SchemaGetCommentResp { this := SchemaGetCommentResp{} return &this } // NewSchemaGetCommentRespWithDefaults instantiates a new SchemaGetCommentResp 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 NewSchemaGetCommentRespWithDefaults() *SchemaGetCommentResp { this := SchemaGetCommentResp{} return &this } // GetCommentId returns the CommentId field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetCommentId() string { if o == nil || IsNil(o.CommentId) { var ret string return ret } return *o.CommentId } // GetCommentIdOk returns a tuple with the CommentId field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetCommentIdOk() (*string, bool) { if o == nil || IsNil(o.CommentId) { return nil, false } return o.CommentId, true } // HasCommentId returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasCommentId() bool { if o != nil && !IsNil(o.CommentId) { return true } return false } // SetCommentId gets a reference to the given string and assigns it to the CommentId field. func (o *SchemaGetCommentResp) SetCommentId(v string) { o.CommentId = &v } // GetCreatedAt returns the CreatedAt field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetCreatedAt() int32 { if o == nil || IsNil(o.CreatedAt) { var ret int32 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 *SchemaGetCommentResp) GetCreatedAtOk() (*int32, 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 *SchemaGetCommentResp) HasCreatedAt() bool { if o != nil && !IsNil(o.CreatedAt) { return true } return false } // SetCreatedAt gets a reference to the given int32 and assigns it to the CreatedAt field. func (o *SchemaGetCommentResp) SetCreatedAt(v int32) { o.CreatedAt = &v } // GetIsVote returns the IsVote field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetIsVote() bool { if o == nil || IsNil(o.IsVote) { var ret bool return ret } return *o.IsVote } // GetIsVoteOk returns a tuple with the IsVote field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetIsVoteOk() (*bool, bool) { if o == nil || IsNil(o.IsVote) { return nil, false } return o.IsVote, true } // HasIsVote returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasIsVote() bool { if o != nil && !IsNil(o.IsVote) { return true } return false } // SetIsVote gets a reference to the given bool and assigns it to the IsVote field. func (o *SchemaGetCommentResp) SetIsVote(v bool) { o.IsVote = &v } // GetMemberActions returns the MemberActions field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetMemberActions() []SchemaPermissionMemberAction { if o == nil || IsNil(o.MemberActions) { var ret []SchemaPermissionMemberAction return ret } return o.MemberActions } // GetMemberActionsOk returns a tuple with the MemberActions field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetMemberActionsOk() ([]SchemaPermissionMemberAction, bool) { if o == nil || IsNil(o.MemberActions) { return nil, false } return o.MemberActions, true } // HasMemberActions returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasMemberActions() bool { if o != nil && !IsNil(o.MemberActions) { return true } return false } // SetMemberActions gets a reference to the given []SchemaPermissionMemberAction and assigns it to the MemberActions field. func (o *SchemaGetCommentResp) SetMemberActions(v []SchemaPermissionMemberAction) { o.MemberActions = v } // GetObjectId returns the ObjectId field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetObjectId() string { if o == nil || IsNil(o.ObjectId) { var ret string return ret } return *o.ObjectId } // GetObjectIdOk returns a tuple with the ObjectId field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetObjectIdOk() (*string, bool) { if o == nil || IsNil(o.ObjectId) { return nil, false } return o.ObjectId, true } // HasObjectId returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasObjectId() bool { if o != nil && !IsNil(o.ObjectId) { return true } return false } // SetObjectId gets a reference to the given string and assigns it to the ObjectId field. func (o *SchemaGetCommentResp) SetObjectId(v string) { o.ObjectId = &v } // GetOriginalText returns the OriginalText field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetOriginalText() string { if o == nil || IsNil(o.OriginalText) { var ret string return ret } return *o.OriginalText } // GetOriginalTextOk returns a tuple with the OriginalText field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetOriginalTextOk() (*string, bool) { if o == nil || IsNil(o.OriginalText) { return nil, false } return o.OriginalText, true } // HasOriginalText returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasOriginalText() bool { if o != nil && !IsNil(o.OriginalText) { return true } return false } // SetOriginalText gets a reference to the given string and assigns it to the OriginalText field. func (o *SchemaGetCommentResp) SetOriginalText(v string) { o.OriginalText = &v } // GetParsedText returns the ParsedText field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetParsedText() string { if o == nil || IsNil(o.ParsedText) { var ret string return ret } return *o.ParsedText } // GetParsedTextOk returns a tuple with the ParsedText field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetParsedTextOk() (*string, bool) { if o == nil || IsNil(o.ParsedText) { return nil, false } return o.ParsedText, true } // HasParsedText returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasParsedText() bool { if o != nil && !IsNil(o.ParsedText) { return true } return false } // SetParsedText gets a reference to the given string and assigns it to the ParsedText field. func (o *SchemaGetCommentResp) SetParsedText(v string) { o.ParsedText = &v } // GetReplyCommentId returns the ReplyCommentId field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetReplyCommentId() string { if o == nil || IsNil(o.ReplyCommentId) { var ret string return ret } return *o.ReplyCommentId } // GetReplyCommentIdOk returns a tuple with the ReplyCommentId field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetReplyCommentIdOk() (*string, bool) { if o == nil || IsNil(o.ReplyCommentId) { return nil, false } return o.ReplyCommentId, true } // HasReplyCommentId returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasReplyCommentId() bool { if o != nil && !IsNil(o.ReplyCommentId) { return true } return false } // SetReplyCommentId gets a reference to the given string and assigns it to the ReplyCommentId field. func (o *SchemaGetCommentResp) SetReplyCommentId(v string) { o.ReplyCommentId = &v } // GetReplyUserDisplayName returns the ReplyUserDisplayName field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetReplyUserDisplayName() string { if o == nil || IsNil(o.ReplyUserDisplayName) { var ret string return ret } return *o.ReplyUserDisplayName } // GetReplyUserDisplayNameOk returns a tuple with the ReplyUserDisplayName field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetReplyUserDisplayNameOk() (*string, bool) { if o == nil || IsNil(o.ReplyUserDisplayName) { return nil, false } return o.ReplyUserDisplayName, true } // HasReplyUserDisplayName returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasReplyUserDisplayName() bool { if o != nil && !IsNil(o.ReplyUserDisplayName) { return true } return false } // SetReplyUserDisplayName gets a reference to the given string and assigns it to the ReplyUserDisplayName field. func (o *SchemaGetCommentResp) SetReplyUserDisplayName(v string) { o.ReplyUserDisplayName = &v } // GetReplyUserId returns the ReplyUserId field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetReplyUserId() string { if o == nil || IsNil(o.ReplyUserId) { var ret string return ret } return *o.ReplyUserId } // GetReplyUserIdOk returns a tuple with the ReplyUserId field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetReplyUserIdOk() (*string, bool) { if o == nil || IsNil(o.ReplyUserId) { return nil, false } return o.ReplyUserId, true } // HasReplyUserId returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasReplyUserId() bool { if o != nil && !IsNil(o.ReplyUserId) { return true } return false } // SetReplyUserId gets a reference to the given string and assigns it to the ReplyUserId field. func (o *SchemaGetCommentResp) SetReplyUserId(v string) { o.ReplyUserId = &v } // GetReplyUserStatus returns the ReplyUserStatus field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetReplyUserStatus() string { if o == nil || IsNil(o.ReplyUserStatus) { var ret string return ret } return *o.ReplyUserStatus } // GetReplyUserStatusOk returns a tuple with the ReplyUserStatus field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetReplyUserStatusOk() (*string, bool) { if o == nil || IsNil(o.ReplyUserStatus) { return nil, false } return o.ReplyUserStatus, true } // HasReplyUserStatus returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasReplyUserStatus() bool { if o != nil && !IsNil(o.ReplyUserStatus) { return true } return false } // SetReplyUserStatus gets a reference to the given string and assigns it to the ReplyUserStatus field. func (o *SchemaGetCommentResp) SetReplyUserStatus(v string) { o.ReplyUserStatus = &v } // GetReplyUsername returns the ReplyUsername field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetReplyUsername() string { if o == nil || IsNil(o.ReplyUsername) { var ret string return ret } return *o.ReplyUsername } // GetReplyUsernameOk returns a tuple with the ReplyUsername field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetReplyUsernameOk() (*string, bool) { if o == nil || IsNil(o.ReplyUsername) { return nil, false } return o.ReplyUsername, true } // HasReplyUsername returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasReplyUsername() bool { if o != nil && !IsNil(o.ReplyUsername) { return true } return false } // SetReplyUsername gets a reference to the given string and assigns it to the ReplyUsername field. func (o *SchemaGetCommentResp) SetReplyUsername(v string) { o.ReplyUsername = &v } // GetUserAvatar returns the UserAvatar field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetUserAvatar() string { if o == nil || IsNil(o.UserAvatar) { var ret string return ret } return *o.UserAvatar } // GetUserAvatarOk returns a tuple with the UserAvatar field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetUserAvatarOk() (*string, bool) { if o == nil || IsNil(o.UserAvatar) { return nil, false } return o.UserAvatar, true } // HasUserAvatar returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasUserAvatar() bool { if o != nil && !IsNil(o.UserAvatar) { return true } return false } // SetUserAvatar gets a reference to the given string and assigns it to the UserAvatar field. func (o *SchemaGetCommentResp) SetUserAvatar(v string) { o.UserAvatar = &v } // GetUserDisplayName returns the UserDisplayName field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetUserDisplayName() string { if o == nil || IsNil(o.UserDisplayName) { var ret string return ret } return *o.UserDisplayName } // GetUserDisplayNameOk returns a tuple with the UserDisplayName field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetUserDisplayNameOk() (*string, bool) { if o == nil || IsNil(o.UserDisplayName) { return nil, false } return o.UserDisplayName, true } // HasUserDisplayName returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasUserDisplayName() bool { if o != nil && !IsNil(o.UserDisplayName) { return true } return false } // SetUserDisplayName gets a reference to the given string and assigns it to the UserDisplayName field. func (o *SchemaGetCommentResp) SetUserDisplayName(v string) { o.UserDisplayName = &v } // GetUserId returns the UserId field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetUserId() string { if o == nil || IsNil(o.UserId) { var ret string return ret } return *o.UserId } // GetUserIdOk returns a tuple with the UserId field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetUserIdOk() (*string, bool) { if o == nil || IsNil(o.UserId) { return nil, false } return o.UserId, true } // HasUserId returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasUserId() bool { if o != nil && !IsNil(o.UserId) { return true } return false } // SetUserId gets a reference to the given string and assigns it to the UserId field. func (o *SchemaGetCommentResp) SetUserId(v string) { o.UserId = &v } // GetUserStatus returns the UserStatus field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetUserStatus() string { if o == nil || IsNil(o.UserStatus) { var ret string return ret } return *o.UserStatus } // GetUserStatusOk returns a tuple with the UserStatus field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetUserStatusOk() (*string, bool) { if o == nil || IsNil(o.UserStatus) { return nil, false } return o.UserStatus, true } // HasUserStatus returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasUserStatus() bool { if o != nil && !IsNil(o.UserStatus) { return true } return false } // SetUserStatus gets a reference to the given string and assigns it to the UserStatus field. func (o *SchemaGetCommentResp) SetUserStatus(v string) { o.UserStatus = &v } // GetUsername returns the Username field value if set, zero value otherwise. func (o *SchemaGetCommentResp) 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 *SchemaGetCommentResp) 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 *SchemaGetCommentResp) 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 *SchemaGetCommentResp) SetUsername(v string) { o.Username = &v } // GetVoteCount returns the VoteCount field value if set, zero value otherwise. func (o *SchemaGetCommentResp) GetVoteCount() int32 { if o == nil || IsNil(o.VoteCount) { var ret int32 return ret } return *o.VoteCount } // GetVoteCountOk returns a tuple with the VoteCount field value if set, nil otherwise // and a boolean to check if the value has been set. func (o *SchemaGetCommentResp) GetVoteCountOk() (*int32, bool) { if o == nil || IsNil(o.VoteCount) { return nil, false } return o.VoteCount, true } // HasVoteCount returns a boolean if a field has been set. func (o *SchemaGetCommentResp) HasVoteCount() bool { if o != nil && !IsNil(o.VoteCount) { return true } return false } // SetVoteCount gets a reference to the given int32 and assigns it to the VoteCount field. func (o *SchemaGetCommentResp) SetVoteCount(v int32) { o.VoteCount = &v } func (o SchemaGetCommentResp) MarshalJSON() ([]byte, error) { toSerialize,err := o.ToMap() if err != nil { return []byte{}, err } return json.Marshal(toSerialize) } func (o SchemaGetCommentResp) ToMap() (map[string]interface{}, error) { toSerialize := map[string]interface{}{} if !IsNil(o.CommentId) { toSerialize["comment_id"] = o.CommentId } if !IsNil(o.CreatedAt) { toSerialize["created_at"] = o.CreatedAt } if !IsNil(o.IsVote) { toSerialize["is_vote"] = o.IsVote } if !IsNil(o.MemberActions) { toSerialize["member_actions"] = o.MemberActions } if !IsNil(o.ObjectId) { toSerialize["object_id"] = o.ObjectId } if !IsNil(o.OriginalText) { toSerialize["original_text"] = o.OriginalText } if !IsNil(o.ParsedText) { toSerialize["parsed_text"] = o.ParsedText } if !IsNil(o.ReplyCommentId) { toSerialize["reply_comment_id"] = o.ReplyCommentId } if !IsNil(o.ReplyUserDisplayName) { toSerialize["reply_user_display_name"] = o.ReplyUserDisplayName } if !IsNil(o.ReplyUserId) { toSerialize["reply_user_id"] = o.ReplyUserId } if !IsNil(o.ReplyUserStatus) { toSerialize["reply_user_status"] = o.ReplyUserStatus } if !IsNil(o.ReplyUsername) { toSerialize["reply_username"] = o.ReplyUsername } if !IsNil(o.UserAvatar) { toSerialize["user_avatar"] = o.UserAvatar } if !IsNil(o.UserDisplayName) { toSerialize["user_display_name"] = o.UserDisplayName } if !IsNil(o.UserId) { toSerialize["user_id"] = o.UserId } if !IsNil(o.UserStatus) { toSerialize["user_status"] = o.UserStatus } if !IsNil(o.Username) { toSerialize["username"] = o.Username } if !IsNil(o.VoteCount) { toSerialize["vote_count"] = o.VoteCount } return toSerialize, nil } type NullableSchemaGetCommentResp struct { value *SchemaGetCommentResp isSet bool } func (v NullableSchemaGetCommentResp) Get() *SchemaGetCommentResp { return v.value } func (v *NullableSchemaGetCommentResp) Set(val *SchemaGetCommentResp) { v.value = val v.isSet = true } func (v NullableSchemaGetCommentResp) IsSet() bool { return v.isSet } func (v *NullableSchemaGetCommentResp) Unset() { v.value = nil v.isSet = false } func NewNullableSchemaGetCommentResp(val *SchemaGetCommentResp) *NullableSchemaGetCommentResp { return &NullableSchemaGetCommentResp{value: val, isSet: true} } func (v NullableSchemaGetCommentResp) MarshalJSON() ([]byte, error) { return json.Marshal(v.value) } func (v *NullableSchemaGetCommentResp) UnmarshalJSON(src []byte) error { v.isSet = true return json.Unmarshal(src, &v.value) }