EMDemoOptions.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. //
  2. // EMDemoOptions.h
  3. // ChatDemo-UI3.0
  4. //
  5. // Created by XieYajie on 2018/12/17.
  6. // Copyright © 2018 XieYajie. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. static NSString *kOptions_Appkey = @"Appkey";
  10. static NSString *kOptions_ApnsCertname = @"ApnsCertname";
  11. static NSString *kOptions_HttpsOnly = @"HttpsOnly";
  12. static NSString *kOptions_SpecifyServer = @"SpecifyServer";
  13. static NSString *kOptions_IMPort = @"IMPort";
  14. static NSString *kOptions_IMServer = @"IMServer";
  15. static NSString *kOptions_RestServer = @"RestServer";
  16. static NSString *kOptions_AutoAcceptGroupInvitation = @"AutoAcceptGroupInvitation";
  17. static NSString *kOptions_AutoTransMsgFile = @"AutoTransferMessageAttachments";
  18. static NSString *kOptions_AutoDownloadThumb = @"AutoDownloadThumbnail";
  19. static NSString *kOptions_DeleteChatExitGroup = @"DeleteChatExitGroup";
  20. static NSString *kOptions_SortMessageByServerTime = @"SortMessageByServerTime";
  21. static NSString *kOptions_PriorityGetMsgFromServer = @"PriorityGetMsgFromServer";
  22. static NSString *kOptions_AutoLogin = @"AutoLogin";
  23. static NSString *kOptions_LoggedinUsername = @"LoggedinUsername";
  24. static NSString *kOptions_LoggedinPassword = @"LoggedinPassword";
  25. static NSString *kOptions_ChatTyping = @"ChatTyping";
  26. static NSString *kOptions_AutoDeliveryAck = @"AutoDeliveryAck";
  27. static NSString *kOptions_OfflineHangup = @"OfflineHangup";
  28. static NSString *kOptions_ShowCallInfo = @"ShowCallInfo";
  29. static NSString *kOptions_UseBackCamera = @"UseBackCamera";
  30. static NSString *kOptions_WillRecord = @"WillRecord";
  31. static NSString *kOptions_WillMergeStrem = @"WillMergeStrem";
  32. #define DEF_APPKEY @"easemob-demo#chatdemoui"
  33. NS_ASSUME_NONNULL_BEGIN
  34. @class EMOptions;
  35. @interface EMDemoOptions : NSObject <NSCoding, NSCopying>
  36. @property (nonatomic, copy) NSString *appkey;
  37. @property (nonatomic, copy) NSString *apnsCertName;
  38. @property (nonatomic, assign) BOOL usingHttpsOnly;
  39. @property (nonatomic) BOOL specifyServer;
  40. @property (nonatomic, assign) int chatPort;
  41. @property (nonatomic, copy) NSString *chatServer;
  42. @property (nonatomic, copy) NSString *restServer;
  43. @property (nonatomic) BOOL isDeleteMessagesWhenExitGroup;
  44. @property (nonatomic) BOOL isAutoAcceptGroupInvitation;
  45. @property (nonatomic) BOOL isAutoTransferMessageAttachments;
  46. @property (nonatomic) BOOL isAutoDownloadThumbnail;
  47. @property (nonatomic) BOOL isSortMessageByServerTime;
  48. @property (nonatomic) BOOL isPriorityGetMsgFromServer;
  49. @property (nonatomic) BOOL isAutoLogin;
  50. @property (nonatomic, strong) NSString *loggedInUsername;
  51. @property (nonatomic, strong) NSString *loggedInPassword;
  52. @property (nonatomic) BOOL isChatTyping;
  53. @property (nonatomic) BOOL isAutoDeliveryAck;
  54. @property (nonatomic) BOOL isOfflineHangup;
  55. @property (nonatomic) BOOL isShowCallInfo;
  56. @property (nonatomic) BOOL isUseBackCamera;
  57. @property (nonatomic) BOOL willRecord;
  58. @property (nonatomic) BOOL willMergeStrem;
  59. + (instancetype)sharedOptions;
  60. + (void)reInitAndSaveServerOptions;
  61. + (void)updateAndSaveServerOptions:(NSDictionary *)aDic;
  62. - (void)archive;
  63. - (EMOptions *)toOptions;
  64. @end
  65. NS_ASSUME_NONNULL_END