Class: TencentCloud::Hunyuan::V20230901::ThreadAdditionalMessage

Inherits:
Common::AbstractModel
  • Object
show all
Defined in:
lib/v20230901/models.rb

Overview

会话额外消息

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(role = nil, content = nil, attachments = nil) ⇒ ThreadAdditionalMessage

Returns a new instance of ThreadAdditionalMessage.



2726
2727
2728
2729
2730
# File 'lib/v20230901/models.rb', line 2726

def initialize(role=nil, content=nil, attachments=nil)
  @Role = role
  @Content = content
  @Attachments = attachments
end

Instance Attribute Details

#AttachmentsObject

注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Role:

    角色

  • Content:

    内容

  • Attachments:

    附件



2724
2725
2726
# File 'lib/v20230901/models.rb', line 2724

def Attachments
  @Attachments
end

#ContentObject

注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Role:

    角色

  • Content:

    内容

  • Attachments:

    附件



2724
2725
2726
# File 'lib/v20230901/models.rb', line 2724

def Content
  @Content
end

#RoleObject

注意:此字段可能返回 null,表示取不到有效值。

Parameters:

  • Role:

    角色

  • Content:

    内容

  • Attachments:

    附件



2724
2725
2726
# File 'lib/v20230901/models.rb', line 2724

def Role
  @Role
end

Instance Method Details

#deserialize(params) ⇒ Object



2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
# File 'lib/v20230901/models.rb', line 2732

def deserialize(params)
  @Role = params['Role']
  @Content = params['Content']
  unless params['Attachments'].nil?
    @Attachments = []
    params['Attachments'].each do |i|
      threadmessageattachmentobject_tmp = ThreadMessageAttachmentObject.new
      threadmessageattachmentobject_tmp.deserialize(i)
      @Attachments << threadmessageattachmentobject_tmp
    end
  end
end