TUIMessageItem.h 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. //
  2. // TUIChatConfig.h
  3. // TUIChat
  4. //
  5. // Created by wyl on 2022/6/10.
  6. // Copyright © 2023 Tencent. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import <UIKit/UIKit.h>
  10. NS_ASSUME_NONNULL_BEGIN
  11. typedef NS_ENUM(NSInteger, TUIImageType) {
  12. TImage_Type_Origin = 1,
  13. TImage_Type_Thumb = 2,
  14. TImage_Type_Large = 4,
  15. };
  16. /////////////////////////////////////////////////////////////////////////////////
  17. //
  18. // TUIImageItem
  19. //
  20. /////////////////////////////////////////////////////////////////////////////////
  21. @interface TUIImageItem : NSObject
  22. /**
  23. * The inner ID for the image, can be used for external cache key
  24. */
  25. @property(nonatomic, strong) NSString *uuid;
  26. @property(nonatomic, strong) NSString *url;
  27. @property(nonatomic, assign) CGSize size;
  28. @property(nonatomic, assign) TUIImageType type;
  29. @end
  30. /////////////////////////////////////////////////////////////////////////////////
  31. //
  32. // TUIVideoItem
  33. //
  34. /////////////////////////////////////////////////////////////////////////////////
  35. ///
  36. @interface TUIVideoItem : NSObject
  37. /**
  38. * The internal ID of the video message, which does not need to be set, is obtained from the video instance pulled by the SDK.
  39. */
  40. @property(nonatomic, strong) NSString *uuid;
  41. /**
  42. * The video type - the suffix of the video file - is set when sending a message. For example "mp4".
  43. */
  44. @property(nonatomic, strong) NSString *type;
  45. /**
  46. * The video size, no need to set, is obtained from the instance pulled by the SDK.
  47. */
  48. @property(nonatomic, assign) NSInteger length;
  49. /**
  50. * video duration
  51. */
  52. @property(nonatomic, assign) NSInteger duration;
  53. @end
  54. /////////////////////////////////////////////////////////////////////////////////
  55. //
  56. // TUISnapshotItem
  57. //
  58. /////////////////////////////////////////////////////////////////////////////////
  59. @interface TUISnapshotItem : NSObject
  60. /**
  61. * Image ID, internal identifier, can be used for external cache key
  62. */
  63. @property(nonatomic, strong) NSString *uuid;
  64. /**
  65. * Cover image type
  66. */
  67. @property(nonatomic, strong) NSString *type;
  68. /**
  69. * The size of the cover on the UI.
  70. */
  71. @property(nonatomic, assign) CGSize size;
  72. @property(nonatomic, assign) NSInteger length;
  73. @end
  74. NS_ASSUME_NONNULL_END