NIMCardDataSourceProtocol.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. //
  2. // NIMCardDataSourceProtocol.h
  3. // NIM
  4. //
  5. // Created by chris on 15/3/5.
  6. // Copyright (c) 2015年 Netease. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import <UIKit/UIKit.h>
  10. #import <NIMSDK/NIMSDK.h>
  11. typedef NS_ENUM(NSInteger, NIMKitCardHeaderOpeator){
  12. CardHeaderOpeatorNone = 0,
  13. CardHeaderOpeatorAdd = (1UL << 0),
  14. CardHeaderOpeatorRemove = (1UL << 1),
  15. };
  16. typedef NS_ENUM(NSInteger, NIMKitTeamCardRowItemType) {
  17. TeamCardRowItemTypeCommon,
  18. TeamCardRowItemTypeTeamMember,
  19. TeamCardRowItemTypeRedButton,
  20. TeamCardRowItemTypeBlueButton,
  21. TeamCardRowItemTypeSwitch,
  22. TeamCardRowItemTypeCheckMark,
  23. };
  24. @protocol NIMKitCardHeaderData <NSObject>
  25. - (UIImage*)imageNormal;
  26. - (NSString*)title;
  27. @optional
  28. - (NSString*)imageUrl;
  29. - (NSString*)memberId;
  30. - (NIMKitCardHeaderOpeator)opera;
  31. @end
  32. @protocol NTESCardBodyData <NSObject>
  33. - (NSString*)title;
  34. - (NIMKitTeamCardRowItemType)type;
  35. - (CGFloat)rowHeight;
  36. @optional
  37. - (NSString*)subTitle;
  38. - (SEL)action;
  39. - (BOOL)actionDisabled;
  40. - (BOOL)switchOn;
  41. - (id)value;
  42. @end