NIM SDK API  8.5.1
Public Member Functions | Public Attributes | List of all members
nim_chatroom::ChatRoomMessage Struct Reference

聊天室消息 More...

#include <nim_chatroom_helper.h>

Public Member Functions

 ChatRoomMessage ()
 
void ParseFromJsonValue (const nim_cpp_wrapper_util::Json::Value &values)
 从JsonValue中解析得到聊天室消息 More...
 
std::string ToJsonString () const
 组装Json Value字符串 More...
 

Public Attributes

int64_t room_id_
 
std::string from_id_
 
int64_t timetag_
 
NIMChatRoomClientType from_client_type_
 
std::string from_nick_
 
std::string from_avatar_
 
std::string from_ext_
 
std::string third_party_callback_ext_
 
std::string notify_tags_
 
NIMChatRoomMsgType msg_type_
 
std::string msg_attach_
 
std::string client_msg_id_
 
std::string msg_body_
 
ChatRoomMessageSetting msg_setting_
 
int32_t sub_type_
 
std::string local_res_path_
 
std::string local_res_id_
 

Detailed Description

聊天室消息

Constructor & Destructor Documentation

◆ ChatRoomMessage()

nim_chatroom::ChatRoomMessage::ChatRoomMessage ( )
inline

构造函数

Member Function Documentation

◆ ParseFromJsonValue()

void nim_chatroom::ChatRoomMessage::ParseFromJsonValue ( const nim_cpp_wrapper_util::Json::Value &  values)
inline

从JsonValue中解析得到聊天室消息

Parameters
[in]values聊天室消息JsonValue
Returns
void

◆ ToJsonString()

std::string nim_chatroom::ChatRoomMessage::ToJsonString ( ) const
inline

组装Json Value字符串

Returns
string Json Value字符串

Member Data Documentation

◆ client_msg_id_

std::string nim_chatroom::ChatRoomMessage::client_msg_id_

客户端消息id

◆ from_avatar_

std::string nim_chatroom::ChatRoomMessage::from_avatar_

发送方头像,服务器填写,发送方不需要填写

◆ from_client_type_

NIMChatRoomClientType nim_chatroom::ChatRoomMessage::from_client_type_

消息发送方客户端类型,服务器填写,发送方不需要填写

◆ from_ext_

std::string nim_chatroom::ChatRoomMessage::from_ext_

发送方身份扩展字段,服务器填写,发送方不需要填写

◆ from_id_

std::string nim_chatroom::ChatRoomMessage::from_id_

消息发送者的账号,服务器填写,发送方不需要填写

◆ from_nick_

std::string nim_chatroom::ChatRoomMessage::from_nick_

发送方昵称,服务器填写,发送方不需要填写

◆ local_res_id_

std::string nim_chatroom::ChatRoomMessage::local_res_id_

媒体文件ID(客户端)

◆ local_res_path_

std::string nim_chatroom::ChatRoomMessage::local_res_path_

媒体文件本地绝对路径(客户端)

◆ msg_attach_

std::string nim_chatroom::ChatRoomMessage::msg_attach_

消息内容,长度限制2048,json结构, 文本消息和其他消息保持一致

◆ msg_body_

std::string nim_chatroom::ChatRoomMessage::msg_body_

文本消息内容(聊天室机器人文本消息)

◆ msg_setting_

ChatRoomMessageSetting nim_chatroom::ChatRoomMessage::msg_setting_

消息属性设置

◆ msg_type_

NIMChatRoomMsgType nim_chatroom::ChatRoomMessage::msg_type_

消息类型

◆ notify_tags_

std::string nim_chatroom::ChatRoomMessage::notify_tags_

对端发送消息或通知时携带的 notify tags 信息

◆ room_id_

int64_t nim_chatroom::ChatRoomMessage::room_id_

消息所属的聊天室id,服务器填写,发送方不需要填写

◆ sub_type_

int32_t nim_chatroom::ChatRoomMessage::sub_type_

消息的子类型,客户端定义,服务器透传

◆ third_party_callback_ext_

std::string nim_chatroom::ChatRoomMessage::third_party_callback_ext_

第三方回调回来的自定义扩展字段

◆ timetag_

int64_t nim_chatroom::ChatRoomMessage::timetag_

消息发送的时间戳(毫秒),服务器填写,发送方不需要填写


The documentation for this struct was generated from the following file: