RQYDTQuestionModule.h 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. //
  2. // RQYDTQuestionModule.h
  3. // jiaPei
  4. //
  5. // Created by 张嵘 on 2022/3/28.
  6. // Copyright © 2022 JCZ. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. typedef NS_ENUM(NSUInteger, RQQuestionUpdateViewType) {
  10. /// 默认
  11. RQQuestionUpdateViewType_Default,
  12. /// 下载中
  13. RQQuestionUpdateViewType_Request,
  14. /// 下载结束
  15. RQQuestionUpdateViewType_Complete,
  16. /// 题库下载
  17. RQQuestionUpdateViewType_LibDownload,
  18. /// 解释下载
  19. RQQuestionUpdateViewType_ExplainDownload,
  20. /// 解释下载中
  21. RQQuestionUpdateViewType_ExplainDownloading,
  22. /// 解释下载中
  23. RQQuestionUpdateViewType_ExplainDownloaded,
  24. };
  25. #pragma mark - Model
  26. #import "RQYDTExamRuleModel.h"
  27. #import "RQYDTQuestionModel.h"
  28. #import "RQYDTPointModel.h"
  29. #import "RQHTTPService+RQGetChapterList.h"
  30. #import "RQHTTPService+RQGetUpdateQuestion.h"
  31. #pragma mark - ViewModel
  32. #pragma mark - View
  33. #import "RQUpdateView.h"
  34. #pragma mark - Module
  35. #import "RQExerciseModule.h"
  36. #import "RQYDTUserQuestionModule.h"
  37. #import "RQYDTJSQuestionModule.h"
  38. #import "YNYDTJQQuestionModule.h"
  39. /// RQCarTypeChangeNotification
  40. FOUNDATION_EXTERN NSString * const RQCarTypeChangeNotification;
  41. #define RQ_YDTQuestion_Module [RQYDTQuestionModule sharedInstance]
  42. NS_ASSUME_NONNULL_BEGIN
  43. @interface RQYDTQuestionModule : NSObject
  44. @property (nonatomic, readwrite, assign) RQHomePageCarType carType;
  45. @property (nonatomic, readwrite, copy) NSString *carTypeStr;
  46. @property (nonatomic, readwrite, assign) RQHomePageSubjectType subject;
  47. @property (nonatomic, readwrite, copy) NSString *subjectStr;
  48. /**用户题库类型。数据库要用的。
  49. */
  50. @property (nonatomic, readwrite, copy) NSString *car_type;
  51. /**是否资格证
  52. */
  53. @property (nonatomic, readwrite, copy) NSString *isZhiGeZheng;
  54. /**科目一的顺序练习题号
  55. */
  56. @property (nonatomic, readwrite, copy) NSString *userSubj1Index;
  57. /**科目四的顺序练习题号
  58. */
  59. @property (nonatomic, readwrite, copy) NSString *userSubj4Index;
  60. /**科目一的背题题号
  61. */
  62. @property (nonatomic, readwrite, copy) NSString *user1Index;
  63. /**科目四的背题题号
  64. */
  65. @property (nonatomic, readwrite, copy) NSString *user4Index;
  66. /**
  67. * 下面全是对题号的记录 客车 货车 摩托车 教练 货运 客运 危险品 出租车
  68. */
  69. @property (nonatomic, readwrite, copy) NSString *A2Subj1Index;
  70. @property (nonatomic, readwrite, copy) NSString *A2Subj4Index;
  71. @property (nonatomic, readwrite, copy) NSString *A1Subj1Index;
  72. @property (nonatomic, readwrite, copy) NSString *A1Subj4Index;
  73. @property (nonatomic, readwrite, copy) NSString *DSubj1Index;
  74. @property (nonatomic, readwrite, copy) NSString *DSubj4Index;
  75. @property (nonatomic, readwrite, copy) NSString *coachIndex;
  76. @property (nonatomic, readwrite, copy) NSString *A1Index;
  77. @property (nonatomic, readwrite, copy) NSString *A2Index;
  78. @property (nonatomic, readwrite, copy) NSString *dangerIndex;
  79. @property (nonatomic, readwrite, copy) NSString *texiIndex;
  80. @property (nonatomic, readwrite, copy) NSString *wycIndex;
  81. /// 科目一顺序练习
  82. @property (nonatomic, readonly, copy) NSArray *subjectOneArr;
  83. /// 科目四顺序练习
  84. @property (nonatomic, readonly, copy) NSArray *subjectFourArr;
  85. /// 单例
  86. + (instancetype) sharedInstance;
  87. /// 更新题库
  88. - (void)rq_updateQuestion;
  89. - (NSInteger)getQuestionVersion;
  90. - (void)saveQuestionsWithSubjectOneArr:(NSArray *)subjectOneArr;
  91. - (void)saveQuestionsWithSubjectFourArr:(NSArray *)subjectFourArr;
  92. - (RQHomePageSubjectType)getSubjectWithSubjectName:(NSString *)subjectName;
  93. - (NSString *)getSubjectNameWithSubject:(RQHomePageSubjectType)subject;
  94. - (NSString *)getCarTypeCNNameWithCarType:(RQHomePageCarType)carType;
  95. - (NSString *)getCar_TypeNameWithCarType:(RQHomePageCarType)carType;
  96. - (NSString *)getCarTypeExamNameWithCarType:(RQHomePageCarType)carType;
  97. - (NSString *)getCarTypeCNTiKuUpdateNameWithCarType:(RQHomePageCarType)carType;
  98. - (RQHomePageCarType)getCarTypeWithCarTypeName:(NSString *)carTypeName;
  99. - (NSArray *)getQuestionWithExerciseType:(RQExerciseType)exerciseType;
  100. - (NSArray *)getQuestionWithSubject:(RQHomePageSubjectType)subject exerciseType:(RQExerciseType)exerciseType;
  101. - (NSArray *)getQuestionWithSubject:(RQHomePageSubjectType)subject exerciseType:(RQExerciseType)exerciseType isNeedMediaData:(BOOL)isNeedMediaData;
  102. - (NSInteger)getQuestionNumWithWithSubject:(RQHomePageSubjectType)subject exerciseType:(RQExerciseType)exerciseType;
  103. /// 章节练习
  104. - (NSArray *)getChapterArr;
  105. - (NSArray *)getChapterQuestionWithChapterName:(NSString *)chapterName;
  106. - (NSArray *)getChapterQuestionWithChapterName:(NSString *)chapterName exerciseType:(RQExerciseType)exerciseType;
  107. /// 强化练习(考点)
  108. - (NSArray *)getPoint;
  109. - (NSArray *)getPointQuestionWithPointID:(NSInteger)pointId;
  110. - (NSArray *)getPointQuestionWithPointID:(NSInteger)pointId exerciseType:(RQExerciseType)exerciseType;
  111. - (BOOL)isNewRuleQuestionWithQuestionId:(NSInteger)questionId;
  112. - (NSData *)getMediaDataWithMediaName:(NSString *)mediaName;
  113. /// 做到哪一题
  114. - (NSInteger)getHistoryQuestionNum;
  115. - (void)saveHistoryQuestionNumWithQuestionId:(NSInteger)questionId;
  116. @end
  117. NS_ASSUME_NONNULL_END