WFCCFileRecord.m 701 B

12345678910111213141516171819202122232425
  1. //
  2. // WFCCFileRecord.m
  3. // WFChatClient
  4. //
  5. // Created by dali on 2020/8/2.
  6. // Copyright © 2020 WildFireChat. All rights reserved.
  7. //
  8. #import "WFCCFileRecord.h"
  9. @implementation WFCCFileRecord
  10. - (id)toJsonObj {
  11. NSMutableDictionary *dict = [[NSMutableDictionary alloc] init];
  12. dict[@"conversation"] = [self.conversation toJsonObj];
  13. [self setDict:dict key:@"messageUid" longlongValue:self.messageUid];
  14. dict[@"userId"] = self.userId;
  15. dict[@"name"] = self.name;
  16. dict[@"url"] = self.url;
  17. dict[@"size"] = @(self.size);
  18. dict[@"downloadCount"] = @(self.downloadCount);
  19. [self setDict:dict key:@"timestamp" longlongValue:self.timestamp];
  20. return dict;
  21. }
  22. @end