user.freezed.dart 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404
  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. User _$UserFromJson(Map<String, dynamic> json) {
  13. return _User.fromJson(json);
  14. }
  15. /// @nodoc
  16. mixin _$User {
  17. String? get country => throw _privateConstructorUsedError;
  18. String? get userIp => throw _privateConstructorUsedError;
  19. String? get accessToken => throw _privateConstructorUsedError;
  20. String? get refreshToken => throw _privateConstructorUsedError;
  21. String? get accountKey => throw _privateConstructorUsedError;
  22. String? get accountPassword => throw _privateConstructorUsedError;
  23. String? get createTime => throw _privateConstructorUsedError;
  24. bool? get geographyEea => throw _privateConstructorUsedError;
  25. int? get memberLevel =>
  26. throw _privateConstructorUsedError; // 会员等级 1 游客 2 普通用户 3 会员
  27. String? get account => throw _privateConstructorUsedError; // 用户名
  28. bool? get activated => throw _privateConstructorUsedError;
  29. /// Serializes this User to a JSON map.
  30. Map<String, dynamic> toJson() => throw _privateConstructorUsedError;
  31. /// Create a copy of User
  32. /// with the given fields replaced by the non-null parameter values.
  33. @JsonKey(includeFromJson: false, includeToJson: false)
  34. $UserCopyWith<User> get copyWith => throw _privateConstructorUsedError;
  35. }
  36. /// @nodoc
  37. abstract class $UserCopyWith<$Res> {
  38. factory $UserCopyWith(User value, $Res Function(User) then) =
  39. _$UserCopyWithImpl<$Res, User>;
  40. @useResult
  41. $Res call(
  42. {String? country,
  43. String? userIp,
  44. String? accessToken,
  45. String? refreshToken,
  46. String? accountKey,
  47. String? accountPassword,
  48. String? createTime,
  49. bool? geographyEea,
  50. int? memberLevel,
  51. String? account,
  52. bool? activated});
  53. }
  54. /// @nodoc
  55. class _$UserCopyWithImpl<$Res, $Val extends User>
  56. implements $UserCopyWith<$Res> {
  57. _$UserCopyWithImpl(this._value, this._then);
  58. // ignore: unused_field
  59. final $Val _value;
  60. // ignore: unused_field
  61. final $Res Function($Val) _then;
  62. /// Create a copy of User
  63. /// with the given fields replaced by the non-null parameter values.
  64. @pragma('vm:prefer-inline')
  65. @override
  66. $Res call({
  67. Object? country = freezed,
  68. Object? userIp = freezed,
  69. Object? accessToken = freezed,
  70. Object? refreshToken = freezed,
  71. Object? accountKey = freezed,
  72. Object? accountPassword = freezed,
  73. Object? createTime = freezed,
  74. Object? geographyEea = freezed,
  75. Object? memberLevel = freezed,
  76. Object? account = freezed,
  77. Object? activated = freezed,
  78. }) {
  79. return _then(_value.copyWith(
  80. country: freezed == country
  81. ? _value.country
  82. : country // ignore: cast_nullable_to_non_nullable
  83. as String?,
  84. userIp: freezed == userIp
  85. ? _value.userIp
  86. : userIp // ignore: cast_nullable_to_non_nullable
  87. as String?,
  88. accessToken: freezed == accessToken
  89. ? _value.accessToken
  90. : accessToken // ignore: cast_nullable_to_non_nullable
  91. as String?,
  92. refreshToken: freezed == refreshToken
  93. ? _value.refreshToken
  94. : refreshToken // ignore: cast_nullable_to_non_nullable
  95. as String?,
  96. accountKey: freezed == accountKey
  97. ? _value.accountKey
  98. : accountKey // ignore: cast_nullable_to_non_nullable
  99. as String?,
  100. accountPassword: freezed == accountPassword
  101. ? _value.accountPassword
  102. : accountPassword // ignore: cast_nullable_to_non_nullable
  103. as String?,
  104. createTime: freezed == createTime
  105. ? _value.createTime
  106. : createTime // ignore: cast_nullable_to_non_nullable
  107. as String?,
  108. geographyEea: freezed == geographyEea
  109. ? _value.geographyEea
  110. : geographyEea // ignore: cast_nullable_to_non_nullable
  111. as bool?,
  112. memberLevel: freezed == memberLevel
  113. ? _value.memberLevel
  114. : memberLevel // ignore: cast_nullable_to_non_nullable
  115. as int?,
  116. account: freezed == account
  117. ? _value.account
  118. : account // ignore: cast_nullable_to_non_nullable
  119. as String?,
  120. activated: freezed == activated
  121. ? _value.activated
  122. : activated // ignore: cast_nullable_to_non_nullable
  123. as bool?,
  124. ) as $Val);
  125. }
  126. }
  127. /// @nodoc
  128. abstract class _$$UserImplCopyWith<$Res> implements $UserCopyWith<$Res> {
  129. factory _$$UserImplCopyWith(
  130. _$UserImpl value, $Res Function(_$UserImpl) then) =
  131. __$$UserImplCopyWithImpl<$Res>;
  132. @override
  133. @useResult
  134. $Res call(
  135. {String? country,
  136. String? userIp,
  137. String? accessToken,
  138. String? refreshToken,
  139. String? accountKey,
  140. String? accountPassword,
  141. String? createTime,
  142. bool? geographyEea,
  143. int? memberLevel,
  144. String? account,
  145. bool? activated});
  146. }
  147. /// @nodoc
  148. class __$$UserImplCopyWithImpl<$Res>
  149. extends _$UserCopyWithImpl<$Res, _$UserImpl>
  150. implements _$$UserImplCopyWith<$Res> {
  151. __$$UserImplCopyWithImpl(_$UserImpl _value, $Res Function(_$UserImpl) _then)
  152. : super(_value, _then);
  153. /// Create a copy of User
  154. /// with the given fields replaced by the non-null parameter values.
  155. @pragma('vm:prefer-inline')
  156. @override
  157. $Res call({
  158. Object? country = freezed,
  159. Object? userIp = freezed,
  160. Object? accessToken = freezed,
  161. Object? refreshToken = freezed,
  162. Object? accountKey = freezed,
  163. Object? accountPassword = freezed,
  164. Object? createTime = freezed,
  165. Object? geographyEea = freezed,
  166. Object? memberLevel = freezed,
  167. Object? account = freezed,
  168. Object? activated = freezed,
  169. }) {
  170. return _then(_$UserImpl(
  171. country: freezed == country
  172. ? _value.country
  173. : country // ignore: cast_nullable_to_non_nullable
  174. as String?,
  175. userIp: freezed == userIp
  176. ? _value.userIp
  177. : userIp // ignore: cast_nullable_to_non_nullable
  178. as String?,
  179. accessToken: freezed == accessToken
  180. ? _value.accessToken
  181. : accessToken // ignore: cast_nullable_to_non_nullable
  182. as String?,
  183. refreshToken: freezed == refreshToken
  184. ? _value.refreshToken
  185. : refreshToken // ignore: cast_nullable_to_non_nullable
  186. as String?,
  187. accountKey: freezed == accountKey
  188. ? _value.accountKey
  189. : accountKey // ignore: cast_nullable_to_non_nullable
  190. as String?,
  191. accountPassword: freezed == accountPassword
  192. ? _value.accountPassword
  193. : accountPassword // ignore: cast_nullable_to_non_nullable
  194. as String?,
  195. createTime: freezed == createTime
  196. ? _value.createTime
  197. : createTime // ignore: cast_nullable_to_non_nullable
  198. as String?,
  199. geographyEea: freezed == geographyEea
  200. ? _value.geographyEea
  201. : geographyEea // ignore: cast_nullable_to_non_nullable
  202. as bool?,
  203. memberLevel: freezed == memberLevel
  204. ? _value.memberLevel
  205. : memberLevel // ignore: cast_nullable_to_non_nullable
  206. as int?,
  207. account: freezed == account
  208. ? _value.account
  209. : account // ignore: cast_nullable_to_non_nullable
  210. as String?,
  211. activated: freezed == activated
  212. ? _value.activated
  213. : activated // ignore: cast_nullable_to_non_nullable
  214. as bool?,
  215. ));
  216. }
  217. }
  218. /// @nodoc
  219. @JsonSerializable()
  220. class _$UserImpl with DiagnosticableTreeMixin implements _User {
  221. const _$UserImpl(
  222. {this.country,
  223. this.userIp,
  224. this.accessToken,
  225. this.refreshToken,
  226. this.accountKey,
  227. this.accountPassword,
  228. this.createTime,
  229. this.geographyEea,
  230. this.memberLevel,
  231. this.account,
  232. this.activated});
  233. factory _$UserImpl.fromJson(Map<String, dynamic> json) =>
  234. _$$UserImplFromJson(json);
  235. @override
  236. final String? country;
  237. @override
  238. final String? userIp;
  239. @override
  240. final String? accessToken;
  241. @override
  242. final String? refreshToken;
  243. @override
  244. final String? accountKey;
  245. @override
  246. final String? accountPassword;
  247. @override
  248. final String? createTime;
  249. @override
  250. final bool? geographyEea;
  251. @override
  252. final int? memberLevel;
  253. // 会员等级 1 游客 2 普通用户 3 会员
  254. @override
  255. final String? account;
  256. // 用户名
  257. @override
  258. final bool? activated;
  259. @override
  260. String toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) {
  261. return 'User(country: $country, userIp: $userIp, accessToken: $accessToken, refreshToken: $refreshToken, accountKey: $accountKey, accountPassword: $accountPassword, createTime: $createTime, geographyEea: $geographyEea, memberLevel: $memberLevel, account: $account, activated: $activated)';
  262. }
  263. @override
  264. void debugFillProperties(DiagnosticPropertiesBuilder properties) {
  265. super.debugFillProperties(properties);
  266. properties
  267. ..add(DiagnosticsProperty('type', 'User'))
  268. ..add(DiagnosticsProperty('country', country))
  269. ..add(DiagnosticsProperty('userIp', userIp))
  270. ..add(DiagnosticsProperty('accessToken', accessToken))
  271. ..add(DiagnosticsProperty('refreshToken', refreshToken))
  272. ..add(DiagnosticsProperty('accountKey', accountKey))
  273. ..add(DiagnosticsProperty('accountPassword', accountPassword))
  274. ..add(DiagnosticsProperty('createTime', createTime))
  275. ..add(DiagnosticsProperty('geographyEea', geographyEea))
  276. ..add(DiagnosticsProperty('memberLevel', memberLevel))
  277. ..add(DiagnosticsProperty('account', account))
  278. ..add(DiagnosticsProperty('activated', activated));
  279. }
  280. @override
  281. bool operator ==(Object other) {
  282. return identical(this, other) ||
  283. (other.runtimeType == runtimeType &&
  284. other is _$UserImpl &&
  285. (identical(other.country, country) || other.country == country) &&
  286. (identical(other.userIp, userIp) || other.userIp == userIp) &&
  287. (identical(other.accessToken, accessToken) ||
  288. other.accessToken == accessToken) &&
  289. (identical(other.refreshToken, refreshToken) ||
  290. other.refreshToken == refreshToken) &&
  291. (identical(other.accountKey, accountKey) ||
  292. other.accountKey == accountKey) &&
  293. (identical(other.accountPassword, accountPassword) ||
  294. other.accountPassword == accountPassword) &&
  295. (identical(other.createTime, createTime) ||
  296. other.createTime == createTime) &&
  297. (identical(other.geographyEea, geographyEea) ||
  298. other.geographyEea == geographyEea) &&
  299. (identical(other.memberLevel, memberLevel) ||
  300. other.memberLevel == memberLevel) &&
  301. (identical(other.account, account) || other.account == account) &&
  302. (identical(other.activated, activated) ||
  303. other.activated == activated));
  304. }
  305. @JsonKey(includeFromJson: false, includeToJson: false)
  306. @override
  307. int get hashCode => Object.hash(
  308. runtimeType,
  309. country,
  310. userIp,
  311. accessToken,
  312. refreshToken,
  313. accountKey,
  314. accountPassword,
  315. createTime,
  316. geographyEea,
  317. memberLevel,
  318. account,
  319. activated);
  320. /// Create a copy of User
  321. /// with the given fields replaced by the non-null parameter values.
  322. @JsonKey(includeFromJson: false, includeToJson: false)
  323. @override
  324. @pragma('vm:prefer-inline')
  325. _$$UserImplCopyWith<_$UserImpl> get copyWith =>
  326. __$$UserImplCopyWithImpl<_$UserImpl>(this, _$identity);
  327. @override
  328. Map<String, dynamic> toJson() {
  329. return _$$UserImplToJson(
  330. this,
  331. );
  332. }
  333. }
  334. abstract class _User implements User {
  335. const factory _User(
  336. {final String? country,
  337. final String? userIp,
  338. final String? accessToken,
  339. final String? refreshToken,
  340. final String? accountKey,
  341. final String? accountPassword,
  342. final String? createTime,
  343. final bool? geographyEea,
  344. final int? memberLevel,
  345. final String? account,
  346. final bool? activated}) = _$UserImpl;
  347. factory _User.fromJson(Map<String, dynamic> json) = _$UserImpl.fromJson;
  348. @override
  349. String? get country;
  350. @override
  351. String? get userIp;
  352. @override
  353. String? get accessToken;
  354. @override
  355. String? get refreshToken;
  356. @override
  357. String? get accountKey;
  358. @override
  359. String? get accountPassword;
  360. @override
  361. String? get createTime;
  362. @override
  363. bool? get geographyEea;
  364. @override
  365. int? get memberLevel; // 会员等级 1 游客 2 普通用户 3 会员
  366. @override
  367. String? get account; // 用户名
  368. @override
  369. bool? get activated;
  370. /// Create a copy of User
  371. /// with the given fields replaced by the non-null parameter values.
  372. @override
  373. @JsonKey(includeFromJson: false, includeToJson: false)
  374. _$$UserImplCopyWith<_$UserImpl> get copyWith =>
  375. throw _privateConstructorUsedError;
  376. }