基础库
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 
 
 

31 líneas
792 B

  1. //
  2. // ZhiyingCommNativeResult.h
  3. // hairuyi_flutter_comm
  4. //
  5. // Created by Weller on 2020/5/16.
  6. //
  7. #import <Foundation/Foundation.h>
  8. NS_ASSUME_NONNULL_BEGIN
  9. #define NativeCommandSuccess(msg) [[ZhiyingCommNativeResult alloc] initWithMsg:msg success:YES]
  10. #define NativeCommandFailed(msg) [[ZhiyingCommNativeResult alloc] initWithMsg: msg success: NO]
  11. #define NativeCommandNotImp [[ZhiyingCommNativeResult alloc] initWithMsg: @"native调用失败" success: NO]
  12. @interface ZhiyingCommNativeResult : NSObject
  13. // 状态
  14. @property (nonatomic, assign) BOOL success;
  15. // 消息
  16. @property (nonatomic, copy) NSString *msg;
  17. @property (nonatomic, strong) NSDictionary* data;
  18. - (instancetype)initWithMsg: (NSString*)msg success: (BOOL) success;
  19. - (NSDictionary*)toDict;
  20. @end
  21. NS_ASSUME_NONNULL_END