NIMRevokeMessageNotification.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. //
  2. // NIMRevokeMessageNotification.h
  3. // NIMLib
  4. //
  5. // Created by Netease.
  6. // Copyright © 2016年 Netease. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. NS_ASSUME_NONNULL_BEGIN
  10. @class NIMSession;
  11. @class NIMMessage;
  12. /**
  13. * 消息撤回通知类型
  14. */
  15. typedef NS_ENUM(NSInteger, NIMRevokeMessageNotificationType) {
  16. /**
  17. * 点对点消息撤回通知
  18. */
  19. NIMRevokeMessageNotificationTypeP2P = 7,
  20. /**
  21. * 群消息撤回通知
  22. */
  23. NIMRevokeMessageNotificationTypeTeam = 8,
  24. /**
  25. * 超大群撤回通知
  26. */
  27. NIMRevokeMessageNotificationTypeSuperTeam = 12,
  28. /**
  29. * 点对点消息单向撤回
  30. */
  31. NIMRevokeMessageNotificationTypeP2POneWay = 13,
  32. /**
  33. * 群消息单向撤回类型
  34. */
  35. NIMRevokeMessageNotificationTypeTeamOneWay = 14,
  36. };
  37. /**
  38. * 撤回通知
  39. */
  40. @interface NIMRevokeMessageNotification : NSObject
  41. /**
  42. * 撤回消息类型
  43. */
  44. @property (nonatomic,assign,readonly) NIMRevokeMessageNotificationType notificationType;
  45. /**
  46. * 撤回消息发起者
  47. */
  48. @property (nonatomic,copy,readonly) NSString *fromUserId;
  49. /**
  50. * 消息的发送者,表示撤回的这条消息是谁发的
  51. */
  52. @property (nonatomic,copy,readonly) NSString *messageFromUserId;
  53. /**
  54. * 撤回消息所属会话
  55. */
  56. @property (nonatomic,copy,readonly) NIMSession *session;
  57. /**
  58. * 撤回消息时间点
  59. * @discussion 这里的时间点指的是被撤回的那条消息到底服务器的时间,而不是撤回指令到达服务器的时间点
  60. */
  61. @property (nonatomic,assign,readonly) NSTimeInterval timestamp;
  62. /**
  63. * 撤回消息内容
  64. * @discussion 当撤回消息未被当前设备接收时,这个字段为 nil
  65. */
  66. @property (nullable,nonatomic,strong,readonly) NIMMessage *message;
  67. /**
  68. * 撤回操作是否属于漫游消息
  69. */
  70. @property (nonatomic,assign,readonly) BOOL roaming;
  71. /**
  72. * 撤回操作是否属于离线消息
  73. */
  74. @property (nonatomic,assign,readonly) BOOL offline;
  75. /**
  76. * 撤回的附言
  77. */
  78. @property(nullable, nonatomic,copy,readonly) NSString *postscript;
  79. /**
  80. * 扩展,撤回方填充
  81. */
  82. @property (nullable, nonatomic, copy, readonly) NSString *attach;
  83. /**
  84. * 扩展,服务器填充消息
  85. */
  86. @property (nonatomic, nonatomic, copy, readonly) NSString *callbackExt;
  87. @end
  88. NS_ASSUME_NONNULL_END