user.freezed.dart 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950
  1. // coverage:ignore-file
  2. // GENERATED CODE - DO NOT MODIFY BY HAND
  3. // ignore_for_file: type=lint
  4. // ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark
  5. part of 'user.dart';
  6. // **************************************************************************
  7. // FreezedGenerator
  8. // **************************************************************************
  9. T _$identity<T>(T value) => value;
  10. final _privateConstructorUsedError = UnsupportedError(
  11. 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models',
  12. );
  13. User _$UserFromJson(Map<String, dynamic> json) {
  14. return _User.fromJson(json);
  15. }
  16. /// @nodoc
  17. mixin _$User {
  18. String? get country => throw _privateConstructorUsedError;
  19. String? get countryName => throw _privateConstructorUsedError;
  20. String? get userIp => throw _privateConstructorUsedError;
  21. String? get accessToken => throw _privateConstructorUsedError;
  22. String? get refreshToken => throw _privateConstructorUsedError;
  23. String? get accountKey => throw _privateConstructorUsedError;
  24. String? get accountPassword => throw _privateConstructorUsedError;
  25. int? get createTime =>
  26. throw _privateConstructorUsedError; // API 返回 int 类型的时间戳
  27. bool? get geographyEea => throw _privateConstructorUsedError;
  28. int? get memberLevel => throw _privateConstructorUsedError; // 1设备用户 2注册用户
  29. int? get userLevel =>
  30. throw _privateConstructorUsedError; // 1试用 2免费 3会员 9999内部
  31. int? get expireTime => throw _privateConstructorUsedError; // VIP套餐到期时间
  32. int? get remainTime => throw _privateConstructorUsedError; // VIP套餐剩余时间
  33. bool? get isExpired => throw _privateConstructorUsedError; // VIP套餐是否过期
  34. bool? get isTestUser => throw _privateConstructorUsedError; // 是否是测试用户
  35. bool? get isSubscribeUser => throw _privateConstructorUsedError; // 是否是连续订阅用户
  36. Account? get account =>
  37. throw _privateConstructorUsedError; //isSubscribeUser=false 时返回最后一次购买套餐信息
  38. //isSubscribeUser=true 时返回当前订阅套餐信息
  39. ChannelPlan? get planInfo =>
  40. throw _privateConstructorUsedError; // userLevel=3时生效
  41. bool? get activated => throw _privateConstructorUsedError;
  42. /// Serializes this User to a JSON map.
  43. Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
  44. /// Create a copy of User
  45. /// with the given fields replaced by the non-null parameter values.
  46. @JsonKey(includeFromJson: false, includeToJson: false)
  47. $UserCopyWith<User> get copyWith => throw _privateConstructorUsedError;
  48. }
  49. /// @nodoc
  50. abstract class $UserCopyWith<$Res> {
  51. factory $UserCopyWith(User value, $Res Function(User) then) =
  52. _$UserCopyWithImpl<$Res, User>;
  53. @useResult
  54. $Res call({
  55. String? country,
  56. String? countryName,
  57. String? userIp,
  58. String? accessToken,
  59. String? refreshToken,
  60. String? accountKey,
  61. String? accountPassword,
  62. int? createTime,
  63. bool? geographyEea,
  64. int? memberLevel,
  65. int? userLevel,
  66. int? expireTime,
  67. int? remainTime,
  68. bool? isExpired,
  69. bool? isTestUser,
  70. bool? isSubscribeUser,
  71. Account? account,
  72. ChannelPlan? planInfo,
  73. bool? activated,
  74. });
  75. $AccountCopyWith<$Res>? get account;
  76. $ChannelPlanCopyWith<$Res>? get planInfo;
  77. }
  78. /// @nodoc
  79. class _$UserCopyWithImpl<$Res, $Val extends User>
  80. implements $UserCopyWith<$Res> {
  81. _$UserCopyWithImpl(this._value, this._then);
  82. // ignore: unused_field
  83. final $Val _value;
  84. // ignore: unused_field
  85. final $Res Function($Val) _then;
  86. /// Create a copy of User
  87. /// with the given fields replaced by the non-null parameter values.
  88. @pragma('vm:prefer-inline')
  89. @override
  90. $Res call({
  91. Object? country = freezed,
  92. Object? countryName = freezed,
  93. Object? userIp = freezed,
  94. Object? accessToken = freezed,
  95. Object? refreshToken = freezed,
  96. Object? accountKey = freezed,
  97. Object? accountPassword = freezed,
  98. Object? createTime = freezed,
  99. Object? geographyEea = freezed,
  100. Object? memberLevel = freezed,
  101. Object? userLevel = freezed,
  102. Object? expireTime = freezed,
  103. Object? remainTime = freezed,
  104. Object? isExpired = freezed,
  105. Object? isTestUser = freezed,
  106. Object? isSubscribeUser = freezed,
  107. Object? account = freezed,
  108. Object? planInfo = freezed,
  109. Object? activated = freezed,
  110. }) {
  111. return _then(
  112. _value.copyWith(
  113. country: freezed == country
  114. ? _value.country
  115. : country // ignore: cast_nullable_to_non_nullable
  116. as String?,
  117. countryName: freezed == countryName
  118. ? _value.countryName
  119. : countryName // ignore: cast_nullable_to_non_nullable
  120. as String?,
  121. userIp: freezed == userIp
  122. ? _value.userIp
  123. : userIp // ignore: cast_nullable_to_non_nullable
  124. as String?,
  125. accessToken: freezed == accessToken
  126. ? _value.accessToken
  127. : accessToken // ignore: cast_nullable_to_non_nullable
  128. as String?,
  129. refreshToken: freezed == refreshToken
  130. ? _value.refreshToken
  131. : refreshToken // ignore: cast_nullable_to_non_nullable
  132. as String?,
  133. accountKey: freezed == accountKey
  134. ? _value.accountKey
  135. : accountKey // ignore: cast_nullable_to_non_nullable
  136. as String?,
  137. accountPassword: freezed == accountPassword
  138. ? _value.accountPassword
  139. : accountPassword // ignore: cast_nullable_to_non_nullable
  140. as String?,
  141. createTime: freezed == createTime
  142. ? _value.createTime
  143. : createTime // ignore: cast_nullable_to_non_nullable
  144. as int?,
  145. geographyEea: freezed == geographyEea
  146. ? _value.geographyEea
  147. : geographyEea // ignore: cast_nullable_to_non_nullable
  148. as bool?,
  149. memberLevel: freezed == memberLevel
  150. ? _value.memberLevel
  151. : memberLevel // ignore: cast_nullable_to_non_nullable
  152. as int?,
  153. userLevel: freezed == userLevel
  154. ? _value.userLevel
  155. : userLevel // ignore: cast_nullable_to_non_nullable
  156. as int?,
  157. expireTime: freezed == expireTime
  158. ? _value.expireTime
  159. : expireTime // ignore: cast_nullable_to_non_nullable
  160. as int?,
  161. remainTime: freezed == remainTime
  162. ? _value.remainTime
  163. : remainTime // ignore: cast_nullable_to_non_nullable
  164. as int?,
  165. isExpired: freezed == isExpired
  166. ? _value.isExpired
  167. : isExpired // ignore: cast_nullable_to_non_nullable
  168. as bool?,
  169. isTestUser: freezed == isTestUser
  170. ? _value.isTestUser
  171. : isTestUser // ignore: cast_nullable_to_non_nullable
  172. as bool?,
  173. isSubscribeUser: freezed == isSubscribeUser
  174. ? _value.isSubscribeUser
  175. : isSubscribeUser // ignore: cast_nullable_to_non_nullable
  176. as bool?,
  177. account: freezed == account
  178. ? _value.account
  179. : account // ignore: cast_nullable_to_non_nullable
  180. as Account?,
  181. planInfo: freezed == planInfo
  182. ? _value.planInfo
  183. : planInfo // ignore: cast_nullable_to_non_nullable
  184. as ChannelPlan?,
  185. activated: freezed == activated
  186. ? _value.activated
  187. : activated // ignore: cast_nullable_to_non_nullable
  188. as bool?,
  189. )
  190. as $Val,
  191. );
  192. }
  193. /// Create a copy of User
  194. /// with the given fields replaced by the non-null parameter values.
  195. @override
  196. @pragma('vm:prefer-inline')
  197. $AccountCopyWith<$Res>? get account {
  198. if (_value.account == null) {
  199. return null;
  200. }
  201. return $AccountCopyWith<$Res>(_value.account!, (value) {
  202. return _then(_value.copyWith(account: value) as $Val);
  203. });
  204. }
  205. /// Create a copy of User
  206. /// with the given fields replaced by the non-null parameter values.
  207. @override
  208. @pragma('vm:prefer-inline')
  209. $ChannelPlanCopyWith<$Res>? get planInfo {
  210. if (_value.planInfo == null) {
  211. return null;
  212. }
  213. return $ChannelPlanCopyWith<$Res>(_value.planInfo!, (value) {
  214. return _then(_value.copyWith(planInfo: value) as $Val);
  215. });
  216. }
  217. }
  218. /// @nodoc
  219. abstract class _$$UserImplCopyWith<$Res> implements $UserCopyWith<$Res> {
  220. factory _$$UserImplCopyWith(
  221. _$UserImpl value,
  222. $Res Function(_$UserImpl) then,
  223. ) = __$$UserImplCopyWithImpl<$Res>;
  224. @override
  225. @useResult
  226. $Res call({
  227. String? country,
  228. String? countryName,
  229. String? userIp,
  230. String? accessToken,
  231. String? refreshToken,
  232. String? accountKey,
  233. String? accountPassword,
  234. int? createTime,
  235. bool? geographyEea,
  236. int? memberLevel,
  237. int? userLevel,
  238. int? expireTime,
  239. int? remainTime,
  240. bool? isExpired,
  241. bool? isTestUser,
  242. bool? isSubscribeUser,
  243. Account? account,
  244. ChannelPlan? planInfo,
  245. bool? activated,
  246. });
  247. @override
  248. $AccountCopyWith<$Res>? get account;
  249. @override
  250. $ChannelPlanCopyWith<$Res>? get planInfo;
  251. }
  252. /// @nodoc
  253. class __$$UserImplCopyWithImpl<$Res>
  254. extends _$UserCopyWithImpl<$Res, _$UserImpl>
  255. implements _$$UserImplCopyWith<$Res> {
  256. __$$UserImplCopyWithImpl(_$UserImpl _value, $Res Function(_$UserImpl) _then)
  257. : super(_value, _then);
  258. /// Create a copy of User
  259. /// with the given fields replaced by the non-null parameter values.
  260. @pragma('vm:prefer-inline')
  261. @override
  262. $Res call({
  263. Object? country = freezed,
  264. Object? countryName = freezed,
  265. Object? userIp = freezed,
  266. Object? accessToken = freezed,
  267. Object? refreshToken = freezed,
  268. Object? accountKey = freezed,
  269. Object? accountPassword = freezed,
  270. Object? createTime = freezed,
  271. Object? geographyEea = freezed,
  272. Object? memberLevel = freezed,
  273. Object? userLevel = freezed,
  274. Object? expireTime = freezed,
  275. Object? remainTime = freezed,
  276. Object? isExpired = freezed,
  277. Object? isTestUser = freezed,
  278. Object? isSubscribeUser = freezed,
  279. Object? account = freezed,
  280. Object? planInfo = freezed,
  281. Object? activated = freezed,
  282. }) {
  283. return _then(
  284. _$UserImpl(
  285. country: freezed == country
  286. ? _value.country
  287. : country // ignore: cast_nullable_to_non_nullable
  288. as String?,
  289. countryName: freezed == countryName
  290. ? _value.countryName
  291. : countryName // ignore: cast_nullable_to_non_nullable
  292. as String?,
  293. userIp: freezed == userIp
  294. ? _value.userIp
  295. : userIp // ignore: cast_nullable_to_non_nullable
  296. as String?,
  297. accessToken: freezed == accessToken
  298. ? _value.accessToken
  299. : accessToken // ignore: cast_nullable_to_non_nullable
  300. as String?,
  301. refreshToken: freezed == refreshToken
  302. ? _value.refreshToken
  303. : refreshToken // ignore: cast_nullable_to_non_nullable
  304. as String?,
  305. accountKey: freezed == accountKey
  306. ? _value.accountKey
  307. : accountKey // ignore: cast_nullable_to_non_nullable
  308. as String?,
  309. accountPassword: freezed == accountPassword
  310. ? _value.accountPassword
  311. : accountPassword // ignore: cast_nullable_to_non_nullable
  312. as String?,
  313. createTime: freezed == createTime
  314. ? _value.createTime
  315. : createTime // ignore: cast_nullable_to_non_nullable
  316. as int?,
  317. geographyEea: freezed == geographyEea
  318. ? _value.geographyEea
  319. : geographyEea // ignore: cast_nullable_to_non_nullable
  320. as bool?,
  321. memberLevel: freezed == memberLevel
  322. ? _value.memberLevel
  323. : memberLevel // ignore: cast_nullable_to_non_nullable
  324. as int?,
  325. userLevel: freezed == userLevel
  326. ? _value.userLevel
  327. : userLevel // ignore: cast_nullable_to_non_nullable
  328. as int?,
  329. expireTime: freezed == expireTime
  330. ? _value.expireTime
  331. : expireTime // ignore: cast_nullable_to_non_nullable
  332. as int?,
  333. remainTime: freezed == remainTime
  334. ? _value.remainTime
  335. : remainTime // ignore: cast_nullable_to_non_nullable
  336. as int?,
  337. isExpired: freezed == isExpired
  338. ? _value.isExpired
  339. : isExpired // ignore: cast_nullable_to_non_nullable
  340. as bool?,
  341. isTestUser: freezed == isTestUser
  342. ? _value.isTestUser
  343. : isTestUser // ignore: cast_nullable_to_non_nullable
  344. as bool?,
  345. isSubscribeUser: freezed == isSubscribeUser
  346. ? _value.isSubscribeUser
  347. : isSubscribeUser // ignore: cast_nullable_to_non_nullable
  348. as bool?,
  349. account: freezed == account
  350. ? _value.account
  351. : account // ignore: cast_nullable_to_non_nullable
  352. as Account?,
  353. planInfo: freezed == planInfo
  354. ? _value.planInfo
  355. : planInfo // ignore: cast_nullable_to_non_nullable
  356. as ChannelPlan?,
  357. activated: freezed == activated
  358. ? _value.activated
  359. : activated // ignore: cast_nullable_to_non_nullable
  360. as bool?,
  361. ),
  362. );
  363. }
  364. }
  365. /// @nodoc
  366. @JsonSerializable()
  367. class _$UserImpl with DiagnosticableTreeMixin implements _User {
  368. const _$UserImpl({
  369. this.country,
  370. this.countryName,
  371. this.userIp,
  372. this.accessToken,
  373. this.refreshToken,
  374. this.accountKey,
  375. this.accountPassword,
  376. this.createTime,
  377. this.geographyEea,
  378. this.memberLevel,
  379. this.userLevel,
  380. this.expireTime,
  381. this.remainTime,
  382. this.isExpired,
  383. this.isTestUser,
  384. this.isSubscribeUser,
  385. this.account,
  386. this.planInfo,
  387. this.activated,
  388. });
  389. factory _$UserImpl.fromJson(Map<String, dynamic> json) =>
  390. _$$UserImplFromJson(json);
  391. @override
  392. final String? country;
  393. @override
  394. final String? countryName;
  395. @override
  396. final String? userIp;
  397. @override
  398. final String? accessToken;
  399. @override
  400. final String? refreshToken;
  401. @override
  402. final String? accountKey;
  403. @override
  404. final String? accountPassword;
  405. @override
  406. final int? createTime;
  407. // API 返回 int 类型的时间戳
  408. @override
  409. final bool? geographyEea;
  410. @override
  411. final int? memberLevel;
  412. // 1设备用户 2注册用户
  413. @override
  414. final int? userLevel;
  415. // 1试用 2免费 3会员 9999内部
  416. @override
  417. final int? expireTime;
  418. // VIP套餐到期时间
  419. @override
  420. final int? remainTime;
  421. // VIP套餐剩余时间
  422. @override
  423. final bool? isExpired;
  424. // VIP套餐是否过期
  425. @override
  426. final bool? isTestUser;
  427. // 是否是测试用户
  428. @override
  429. final bool? isSubscribeUser;
  430. // 是否是连续订阅用户
  431. @override
  432. final Account? account;
  433. //isSubscribeUser=false 时返回最后一次购买套餐信息
  434. //isSubscribeUser=true 时返回当前订阅套餐信息
  435. @override
  436. final ChannelPlan? planInfo;
  437. // userLevel=3时生效
  438. @override
  439. final bool? activated;
  440. @override
  441. String toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) {
  442. return 'User(country: $country, countryName: $countryName, userIp: $userIp, accessToken: $accessToken, refreshToken: $refreshToken, accountKey: $accountKey, accountPassword: $accountPassword, createTime: $createTime, geographyEea: $geographyEea, memberLevel: $memberLevel, userLevel: $userLevel, expireTime: $expireTime, remainTime: $remainTime, isExpired: $isExpired, isTestUser: $isTestUser, isSubscribeUser: $isSubscribeUser, account: $account, planInfo: $planInfo, activated: $activated)';
  443. }
  444. @override
  445. void debugFillProperties(DiagnosticPropertiesBuilder properties) {
  446. super.debugFillProperties(properties);
  447. properties
  448. ..add(DiagnosticsProperty('type', 'User'))
  449. ..add(DiagnosticsProperty('country', country))
  450. ..add(DiagnosticsProperty('countryName', countryName))
  451. ..add(DiagnosticsProperty('userIp', userIp))
  452. ..add(DiagnosticsProperty('accessToken', accessToken))
  453. ..add(DiagnosticsProperty('refreshToken', refreshToken))
  454. ..add(DiagnosticsProperty('accountKey', accountKey))
  455. ..add(DiagnosticsProperty('accountPassword', accountPassword))
  456. ..add(DiagnosticsProperty('createTime', createTime))
  457. ..add(DiagnosticsProperty('geographyEea', geographyEea))
  458. ..add(DiagnosticsProperty('memberLevel', memberLevel))
  459. ..add(DiagnosticsProperty('userLevel', userLevel))
  460. ..add(DiagnosticsProperty('expireTime', expireTime))
  461. ..add(DiagnosticsProperty('remainTime', remainTime))
  462. ..add(DiagnosticsProperty('isExpired', isExpired))
  463. ..add(DiagnosticsProperty('isTestUser', isTestUser))
  464. ..add(DiagnosticsProperty('isSubscribeUser', isSubscribeUser))
  465. ..add(DiagnosticsProperty('account', account))
  466. ..add(DiagnosticsProperty('planInfo', planInfo))
  467. ..add(DiagnosticsProperty('activated', activated));
  468. }
  469. @override
  470. bool operator ==(Object other) {
  471. return identical(this, other) ||
  472. (other.runtimeType == runtimeType &&
  473. other is _$UserImpl &&
  474. (identical(other.country, country) || other.country == country) &&
  475. (identical(other.countryName, countryName) ||
  476. other.countryName == countryName) &&
  477. (identical(other.userIp, userIp) || other.userIp == userIp) &&
  478. (identical(other.accessToken, accessToken) ||
  479. other.accessToken == accessToken) &&
  480. (identical(other.refreshToken, refreshToken) ||
  481. other.refreshToken == refreshToken) &&
  482. (identical(other.accountKey, accountKey) ||
  483. other.accountKey == accountKey) &&
  484. (identical(other.accountPassword, accountPassword) ||
  485. other.accountPassword == accountPassword) &&
  486. (identical(other.createTime, createTime) ||
  487. other.createTime == createTime) &&
  488. (identical(other.geographyEea, geographyEea) ||
  489. other.geographyEea == geographyEea) &&
  490. (identical(other.memberLevel, memberLevel) ||
  491. other.memberLevel == memberLevel) &&
  492. (identical(other.userLevel, userLevel) ||
  493. other.userLevel == userLevel) &&
  494. (identical(other.expireTime, expireTime) ||
  495. other.expireTime == expireTime) &&
  496. (identical(other.remainTime, remainTime) ||
  497. other.remainTime == remainTime) &&
  498. (identical(other.isExpired, isExpired) ||
  499. other.isExpired == isExpired) &&
  500. (identical(other.isTestUser, isTestUser) ||
  501. other.isTestUser == isTestUser) &&
  502. (identical(other.isSubscribeUser, isSubscribeUser) ||
  503. other.isSubscribeUser == isSubscribeUser) &&
  504. (identical(other.account, account) || other.account == account) &&
  505. (identical(other.planInfo, planInfo) ||
  506. other.planInfo == planInfo) &&
  507. (identical(other.activated, activated) ||
  508. other.activated == activated));
  509. }
  510. @JsonKey(includeFromJson: false, includeToJson: false)
  511. @override
  512. int get hashCode => Object.hashAll([
  513. runtimeType,
  514. country,
  515. countryName,
  516. userIp,
  517. accessToken,
  518. refreshToken,
  519. accountKey,
  520. accountPassword,
  521. createTime,
  522. geographyEea,
  523. memberLevel,
  524. userLevel,
  525. expireTime,
  526. remainTime,
  527. isExpired,
  528. isTestUser,
  529. isSubscribeUser,
  530. account,
  531. planInfo,
  532. activated,
  533. ]);
  534. /// Create a copy of User
  535. /// with the given fields replaced by the non-null parameter values.
  536. @JsonKey(includeFromJson: false, includeToJson: false)
  537. @override
  538. @pragma('vm:prefer-inline')
  539. _$$UserImplCopyWith<_$UserImpl> get copyWith =>
  540. __$$UserImplCopyWithImpl<_$UserImpl>(this, _$identity);
  541. @override
  542. Map<String, dynamic> toJson() {
  543. return _$$UserImplToJson(this);
  544. }
  545. }
  546. abstract class _User implements User {
  547. const factory _User({
  548. final String? country,
  549. final String? countryName,
  550. final String? userIp,
  551. final String? accessToken,
  552. final String? refreshToken,
  553. final String? accountKey,
  554. final String? accountPassword,
  555. final int? createTime,
  556. final bool? geographyEea,
  557. final int? memberLevel,
  558. final int? userLevel,
  559. final int? expireTime,
  560. final int? remainTime,
  561. final bool? isExpired,
  562. final bool? isTestUser,
  563. final bool? isSubscribeUser,
  564. final Account? account,
  565. final ChannelPlan? planInfo,
  566. final bool? activated,
  567. }) = _$UserImpl;
  568. factory _User.fromJson(Map<String, dynamic> json) = _$UserImpl.fromJson;
  569. @override
  570. String? get country;
  571. @override
  572. String? get countryName;
  573. @override
  574. String? get userIp;
  575. @override
  576. String? get accessToken;
  577. @override
  578. String? get refreshToken;
  579. @override
  580. String? get accountKey;
  581. @override
  582. String? get accountPassword;
  583. @override
  584. int? get createTime; // API 返回 int 类型的时间戳
  585. @override
  586. bool? get geographyEea;
  587. @override
  588. int? get memberLevel; // 1设备用户 2注册用户
  589. @override
  590. int? get userLevel; // 1试用 2免费 3会员 9999内部
  591. @override
  592. int? get expireTime; // VIP套餐到期时间
  593. @override
  594. int? get remainTime; // VIP套餐剩余时间
  595. @override
  596. bool? get isExpired; // VIP套餐是否过期
  597. @override
  598. bool? get isTestUser; // 是否是测试用户
  599. @override
  600. bool? get isSubscribeUser; // 是否是连续订阅用户
  601. @override
  602. Account? get account; //isSubscribeUser=false 时返回最后一次购买套餐信息
  603. //isSubscribeUser=true 时返回当前订阅套餐信息
  604. @override
  605. ChannelPlan? get planInfo; // userLevel=3时生效
  606. @override
  607. bool? get activated;
  608. /// Create a copy of User
  609. /// with the given fields replaced by the non-null parameter values.
  610. @override
  611. @JsonKey(includeFromJson: false, includeToJson: false)
  612. _$$UserImplCopyWith<_$UserImpl> get copyWith =>
  613. throw _privateConstructorUsedError;
  614. }
  615. Account _$AccountFromJson(Map<String, dynamic> json) {
  616. return _Account.fromJson(json);
  617. }
  618. /// @nodoc
  619. mixin _$Account {
  620. String? get username => throw _privateConstructorUsedError;
  621. String? get phone => throw _privateConstructorUsedError;
  622. String? get email => throw _privateConstructorUsedError;
  623. String? get wechat => throw _privateConstructorUsedError;
  624. String? get qq => throw _privateConstructorUsedError;
  625. String? get google => throw _privateConstructorUsedError;
  626. String? get apple => throw _privateConstructorUsedError;
  627. /// Serializes this Account to a JSON map.
  628. Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
  629. /// Create a copy of Account
  630. /// with the given fields replaced by the non-null parameter values.
  631. @JsonKey(includeFromJson: false, includeToJson: false)
  632. $AccountCopyWith<Account> get copyWith => throw _privateConstructorUsedError;
  633. }
  634. /// @nodoc
  635. abstract class $AccountCopyWith<$Res> {
  636. factory $AccountCopyWith(Account value, $Res Function(Account) then) =
  637. _$AccountCopyWithImpl<$Res, Account>;
  638. @useResult
  639. $Res call({
  640. String? username,
  641. String? phone,
  642. String? email,
  643. String? wechat,
  644. String? qq,
  645. String? google,
  646. String? apple,
  647. });
  648. }
  649. /// @nodoc
  650. class _$AccountCopyWithImpl<$Res, $Val extends Account>
  651. implements $AccountCopyWith<$Res> {
  652. _$AccountCopyWithImpl(this._value, this._then);
  653. // ignore: unused_field
  654. final $Val _value;
  655. // ignore: unused_field
  656. final $Res Function($Val) _then;
  657. /// Create a copy of Account
  658. /// with the given fields replaced by the non-null parameter values.
  659. @pragma('vm:prefer-inline')
  660. @override
  661. $Res call({
  662. Object? username = freezed,
  663. Object? phone = freezed,
  664. Object? email = freezed,
  665. Object? wechat = freezed,
  666. Object? qq = freezed,
  667. Object? google = freezed,
  668. Object? apple = freezed,
  669. }) {
  670. return _then(
  671. _value.copyWith(
  672. username: freezed == username
  673. ? _value.username
  674. : username // ignore: cast_nullable_to_non_nullable
  675. as String?,
  676. phone: freezed == phone
  677. ? _value.phone
  678. : phone // ignore: cast_nullable_to_non_nullable
  679. as String?,
  680. email: freezed == email
  681. ? _value.email
  682. : email // ignore: cast_nullable_to_non_nullable
  683. as String?,
  684. wechat: freezed == wechat
  685. ? _value.wechat
  686. : wechat // ignore: cast_nullable_to_non_nullable
  687. as String?,
  688. qq: freezed == qq
  689. ? _value.qq
  690. : qq // ignore: cast_nullable_to_non_nullable
  691. as String?,
  692. google: freezed == google
  693. ? _value.google
  694. : google // ignore: cast_nullable_to_non_nullable
  695. as String?,
  696. apple: freezed == apple
  697. ? _value.apple
  698. : apple // ignore: cast_nullable_to_non_nullable
  699. as String?,
  700. )
  701. as $Val,
  702. );
  703. }
  704. }
  705. /// @nodoc
  706. abstract class _$$AccountImplCopyWith<$Res> implements $AccountCopyWith<$Res> {
  707. factory _$$AccountImplCopyWith(
  708. _$AccountImpl value,
  709. $Res Function(_$AccountImpl) then,
  710. ) = __$$AccountImplCopyWithImpl<$Res>;
  711. @override
  712. @useResult
  713. $Res call({
  714. String? username,
  715. String? phone,
  716. String? email,
  717. String? wechat,
  718. String? qq,
  719. String? google,
  720. String? apple,
  721. });
  722. }
  723. /// @nodoc
  724. class __$$AccountImplCopyWithImpl<$Res>
  725. extends _$AccountCopyWithImpl<$Res, _$AccountImpl>
  726. implements _$$AccountImplCopyWith<$Res> {
  727. __$$AccountImplCopyWithImpl(
  728. _$AccountImpl _value,
  729. $Res Function(_$AccountImpl) _then,
  730. ) : super(_value, _then);
  731. /// Create a copy of Account
  732. /// with the given fields replaced by the non-null parameter values.
  733. @pragma('vm:prefer-inline')
  734. @override
  735. $Res call({
  736. Object? username = freezed,
  737. Object? phone = freezed,
  738. Object? email = freezed,
  739. Object? wechat = freezed,
  740. Object? qq = freezed,
  741. Object? google = freezed,
  742. Object? apple = freezed,
  743. }) {
  744. return _then(
  745. _$AccountImpl(
  746. username: freezed == username
  747. ? _value.username
  748. : username // ignore: cast_nullable_to_non_nullable
  749. as String?,
  750. phone: freezed == phone
  751. ? _value.phone
  752. : phone // ignore: cast_nullable_to_non_nullable
  753. as String?,
  754. email: freezed == email
  755. ? _value.email
  756. : email // ignore: cast_nullable_to_non_nullable
  757. as String?,
  758. wechat: freezed == wechat
  759. ? _value.wechat
  760. : wechat // ignore: cast_nullable_to_non_nullable
  761. as String?,
  762. qq: freezed == qq
  763. ? _value.qq
  764. : qq // ignore: cast_nullable_to_non_nullable
  765. as String?,
  766. google: freezed == google
  767. ? _value.google
  768. : google // ignore: cast_nullable_to_non_nullable
  769. as String?,
  770. apple: freezed == apple
  771. ? _value.apple
  772. : apple // ignore: cast_nullable_to_non_nullable
  773. as String?,
  774. ),
  775. );
  776. }
  777. }
  778. /// @nodoc
  779. @JsonSerializable()
  780. class _$AccountImpl with DiagnosticableTreeMixin implements _Account {
  781. const _$AccountImpl({
  782. this.username,
  783. this.phone,
  784. this.email,
  785. this.wechat,
  786. this.qq,
  787. this.google,
  788. this.apple,
  789. });
  790. factory _$AccountImpl.fromJson(Map<String, dynamic> json) =>
  791. _$$AccountImplFromJson(json);
  792. @override
  793. final String? username;
  794. @override
  795. final String? phone;
  796. @override
  797. final String? email;
  798. @override
  799. final String? wechat;
  800. @override
  801. final String? qq;
  802. @override
  803. final String? google;
  804. @override
  805. final String? apple;
  806. @override
  807. String toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) {
  808. return 'Account(username: $username, phone: $phone, email: $email, wechat: $wechat, qq: $qq, google: $google, apple: $apple)';
  809. }
  810. @override
  811. void debugFillProperties(DiagnosticPropertiesBuilder properties) {
  812. super.debugFillProperties(properties);
  813. properties
  814. ..add(DiagnosticsProperty('type', 'Account'))
  815. ..add(DiagnosticsProperty('username', username))
  816. ..add(DiagnosticsProperty('phone', phone))
  817. ..add(DiagnosticsProperty('email', email))
  818. ..add(DiagnosticsProperty('wechat', wechat))
  819. ..add(DiagnosticsProperty('qq', qq))
  820. ..add(DiagnosticsProperty('google', google))
  821. ..add(DiagnosticsProperty('apple', apple));
  822. }
  823. @override
  824. bool operator ==(Object other) {
  825. return identical(this, other) ||
  826. (other.runtimeType == runtimeType &&
  827. other is _$AccountImpl &&
  828. (identical(other.username, username) ||
  829. other.username == username) &&
  830. (identical(other.phone, phone) || other.phone == phone) &&
  831. (identical(other.email, email) || other.email == email) &&
  832. (identical(other.wechat, wechat) || other.wechat == wechat) &&
  833. (identical(other.qq, qq) || other.qq == qq) &&
  834. (identical(other.google, google) || other.google == google) &&
  835. (identical(other.apple, apple) || other.apple == apple));
  836. }
  837. @JsonKey(includeFromJson: false, includeToJson: false)
  838. @override
  839. int get hashCode => Object.hash(
  840. runtimeType,
  841. username,
  842. phone,
  843. email,
  844. wechat,
  845. qq,
  846. google,
  847. apple,
  848. );
  849. /// Create a copy of Account
  850. /// with the given fields replaced by the non-null parameter values.
  851. @JsonKey(includeFromJson: false, includeToJson: false)
  852. @override
  853. @pragma('vm:prefer-inline')
  854. _$$AccountImplCopyWith<_$AccountImpl> get copyWith =>
  855. __$$AccountImplCopyWithImpl<_$AccountImpl>(this, _$identity);
  856. @override
  857. Map<String, dynamic> toJson() {
  858. return _$$AccountImplToJson(this);
  859. }
  860. }
  861. abstract class _Account implements Account {
  862. const factory _Account({
  863. final String? username,
  864. final String? phone,
  865. final String? email,
  866. final String? wechat,
  867. final String? qq,
  868. final String? google,
  869. final String? apple,
  870. }) = _$AccountImpl;
  871. factory _Account.fromJson(Map<String, dynamic> json) = _$AccountImpl.fromJson;
  872. @override
  873. String? get username;
  874. @override
  875. String? get phone;
  876. @override
  877. String? get email;
  878. @override
  879. String? get wechat;
  880. @override
  881. String? get qq;
  882. @override
  883. String? get google;
  884. @override
  885. String? get apple;
  886. /// Create a copy of Account
  887. /// with the given fields replaced by the non-null parameter values.
  888. @override
  889. @JsonKey(includeFromJson: false, includeToJson: false)
  890. _$$AccountImplCopyWith<_$AccountImpl> get copyWith =>
  891. throw _privateConstructorUsedError;
  892. }