class Google::Apis::MybusinessqandaV1::Question
Represents a single question and some of its answers.
Attributes
Output only. The timestamp for when the question was written. Corresponds to the JSON property ‘createTime` @return [String]
Immutable. The unique name for the question. locations//questions/ This field will be ignored if set during question creation. Corresponds to the JSON property ‘name` @return [String]
Required. The text of the question. It should contain at least three words and the total length should be greater than or equal to 10 characters. The maximum length is 4096 characters. Corresponds to the JSON property ‘text` @return [String]
Output only. A list of answers to the question, sorted by upvotes. This may not be a complete list of answers depending on the request parameters ( answers_per_question) Corresponds to the JSON property ‘topAnswers` @return [Array<Google::Apis::MybusinessqandaV1::Answer>]
Output only. The total number of answers posted for this question. Corresponds to the JSON property ‘totalAnswerCount` @return [Fixnum]
Output only. The timestamp for when the question was last modified. Corresponds to the JSON property ‘updateTime` @return [String]
Output only. The number of upvotes for the question. Corresponds to the JSON property ‘upvoteCount` @return [Fixnum]
Public Class Methods
# File lib/google/apis/mybusinessqanda_v1/classes.rb, line 239 def initialize(**args) update!(**args) end
Public Instance Methods
Update properties of this object
# File lib/google/apis/mybusinessqanda_v1/classes.rb, line 244 def update!(**args) @author = args[:author] if args.key?(:author) @create_time = args[:create_time] if args.key?(:create_time) @name = args[:name] if args.key?(:name) @text = args[:text] if args.key?(:text) @top_answers = args[:top_answers] if args.key?(:top_answers) @total_answer_count = args[:total_answer_count] if args.key?(:total_answer_count) @update_time = args[:update_time] if args.key?(:update_time) @upvote_count = args[:upvote_count] if args.key?(:upvote_count) end