From d53a5974d48f63a24816415cc45f736f390e8c4e Mon Sep 17 00:00:00 2001 From: sorairo Date: Wed, 14 Aug 2024 17:15:38 +0900 Subject: [PATCH] fix test --- example/misskey_dart_example.dart | 4 +- lib/misskey_dart.dart | 2 +- lib/src/data/streaming/Untitled-1.json | 759 ------ .../data/streaming/streaming_response.dart | 68 +- .../streaming/streaming_response.freezed.dart | 2177 +++++++++++------ .../data/streaming/streaming_response.g.dart | 125 +- lib/src/data/streaming/timeline_deleted.dart | 15 + .../streaming/timeline_deleted.freezed.dart | 158 ++ .../data/streaming/timeline_deleted.g.dart | 20 + lib/src/misskey_dart_base.dart | 2 +- lib/src/misskey_reversi.dart | 3 - lib/src/misskey_users.dart | 2 - lib/src/services/streaming_service_impl.dart | 25 +- test/misskey_dart_base_test.dart | 5 - test/streaming_test.dart | 186 +- 15 files changed, 1886 insertions(+), 1665 deletions(-) delete mode 100644 lib/src/data/streaming/Untitled-1.json create mode 100644 lib/src/data/streaming/timeline_deleted.dart create mode 100644 lib/src/data/streaming/timeline_deleted.freezed.dart create mode 100644 lib/src/data/streaming/timeline_deleted.g.dart diff --git a/example/misskey_dart_example.dart b/example/misskey_dart_example.dart index 3bda81a0..042e7cd6 100644 --- a/example/misskey_dart_example.dart +++ b/example/misskey_dart_example.dart @@ -38,9 +38,7 @@ Future main() async { .join(",")); case StatsChannelEvent(:final body): print((body as ServerMetricsResponse).mem); - case NoteChannelEvent(): - case UserAddedChannelEvent(): - case UserRemovedChannelEvent(): + case _: } }); streamController.requestLog(id, 50); diff --git a/lib/misskey_dart.dart b/lib/misskey_dart.dart index d6a86fd8..7fb6a81e 100644 --- a/lib/misskey_dart.dart +++ b/lib/misskey_dart.dart @@ -221,6 +221,7 @@ export 'src/data/reversi/reversi_games_response.dart'; export 'src/data/reversi/reversi_show_game_response.dart'; export 'src/data/streaming/timeline_reacted.dart'; export 'src/data/streaming/timeline_voted.dart'; +export 'src/data/streaming/timeline_deleted.dart'; export 'src/data/streaming/stats_log_response.dart'; export 'src/data/streaming/note_edited.dart'; export 'src/data/streaming/home_timeline_parameter.dart'; @@ -229,7 +230,6 @@ export 'src/data/streaming/global_timeline_parameter.dart'; export 'src/data/streaming/hybrid_timeline_parameter.dart'; export 'src/data/streaming/streaming_response.dart'; export 'src/data/join_misskey_instances.dart'; -export 'src/services/streaming_service_impl.dart'; export 'src/server.dart'; export 'src/join_misskey.dart'; diff --git a/lib/src/data/streaming/Untitled-1.json b/lib/src/data/streaming/Untitled-1.json deleted file mode 100644 index b400466f..00000000 --- a/lib/src/data/streaming/Untitled-1.json +++ /dev/null @@ -1,759 +0,0 @@ -{ - "type": "channel", - "body": { - "id": "6", - "type": "statsLog", - "body": [ - { - "cpu": 0.055, - "mem": { - "used": 2226302976, - "active": 2226302976 - }, - "net": { - "rx": 3658.7, - "tx": 3389.3 - }, - "fs": { - "r": 0, - "w": 7.5 - } - }, - { - "cpu": 0.065, - "mem": { - "used": 2228461568, - "active": 2228461568 - }, - "net": { - "rx": 2840.4, - "tx": 7784.5 - }, - "fs": { - "r": 0, - "w": 16 - } - }, - { - "cpu": 0.085, - "mem": { - "used": 2214342656, - "active": 2214342656 - }, - "net": { - "rx": 1824.4, - "tx": 2087.8 - }, - "fs": { - "r": 0, - "w": 2 - } - }, - { - "cpu": 0.075, - "mem": { - "used": 2226421760, - "active": 2226421760 - }, - "net": { - "rx": 2763.1, - "tx": 3315.8 - }, - "fs": { - "r": 0, - "w": 13 - } - }, - { - "cpu": 0.055, - "mem": { - "used": 2222284800, - "active": 2222284800 - }, - "net": { - "rx": 355.8, - "tx": 634.8 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.056, - "mem": { - "used": 2220220416, - "active": 2220220416 - }, - "net": { - "rx": 1741.3, - "tx": 2768.5 - }, - "fs": { - "r": 0, - "w": 1 - } - }, - { - "cpu": 0.065, - "mem": { - "used": 2218954752, - "active": 2218954752 - }, - "net": { - "rx": 1937.7, - "tx": 1245 - }, - "fs": { - "r": 0, - "w": 5.5 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2223218688, - "active": 2223218688 - }, - "net": { - "rx": 198.3, - "tx": 551.8 - }, - "fs": { - "r": 0, - "w": 1.5 - } - }, - { - "cpu": 0.095, - "mem": { - "used": 2218315776, - "active": 2218315776 - }, - "net": { - "rx": 4173, - "tx": 7290.7 - }, - "fs": { - "r": 0, - "w": 6.1 - } - }, - { - "cpu": 0.05, - "mem": { - "used": 2216951808, - "active": 2216951808 - }, - "net": { - "rx": 803.1, - "tx": 1074.3 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.085, - "mem": { - "used": 2249183232, - "active": 2249183232 - }, - "net": { - "rx": 2977.8, - "tx": 2071.2 - }, - "fs": { - "r": 0, - "w": 7.1 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2242949120, - "active": 2242949120 - }, - "net": { - "rx": 228.6, - "tx": 418.6 - }, - "fs": { - "r": 0, - "w": 2.5 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2246832128, - "active": 2246832128 - }, - "net": { - "rx": 449.1, - "tx": 1579 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.065, - "mem": { - "used": 2245070848, - "active": 2245070848 - }, - "net": { - "rx": 10532.2, - "tx": 4972.4 - }, - "fs": { - "r": 0.5, - "w": 7.6 - } - }, - { - "cpu": 0.075, - "mem": { - "used": 2227806208, - "active": 2227806208 - }, - "net": { - "rx": 2948.2, - "tx": 26526.4 - }, - "fs": { - "r": 0, - "w": 8 - } - }, - { - "cpu": 0.533, - "mem": { - "used": 2216980480, - "active": 2216980480 - }, - "net": { - "rx": 5395.8, - "tx": 55093.9 - }, - "fs": { - "r": 0, - "w": 26.1 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2205691904, - "active": 2205691904 - }, - "net": { - "rx": 1274.5, - "tx": 743.4 - }, - "fs": { - "r": 0, - "w": 48.4 - } - }, - { - "cpu": 0.075, - "mem": { - "used": 2206785536, - "active": 2206785536 - }, - "net": { - "rx": 2070.9, - "tx": 1138.4 - }, - "fs": { - "r": 0, - "w": 4 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2204991488, - "active": 2204991488 - }, - "net": { - "rx": 2066.6, - "tx": 799.7 - }, - "fs": { - "r": 0, - "w": 1 - } - }, - { - "cpu": 0.05, - "mem": { - "used": 2237759488, - "active": 2237759488 - }, - "net": { - "rx": 1836.2, - "tx": 1176.2 - }, - "fs": { - "r": 0, - "w": 6 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2243133440, - "active": 2243133440 - }, - "net": { - "rx": 2904.6, - "tx": 8125.3 - }, - "fs": { - "r": 0, - "w": 1 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2239533056, - "active": 2239533056 - }, - "net": { - "rx": 648, - "tx": 2098.3 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.075, - "mem": { - "used": 2236440576, - "active": 2236440576 - }, - "net": { - "rx": 2569.5, - "tx": 2892.9 - }, - "fs": { - "r": 0, - "w": 4.5 - } - }, - { - "cpu": 0.071, - "mem": { - "used": 2233589760, - "active": 2233589760 - }, - "net": { - "rx": 5132.5, - "tx": 14309.1 - }, - "fs": { - "r": 0, - "w": 9.6 - } - }, - { - "cpu": 0.08, - "mem": { - "used": 2216402944, - "active": 2216402944 - }, - "net": { - "rx": 198.7, - "tx": 506.8 - }, - "fs": { - "r": 0, - "w": 1.5 - } - }, - { - "cpu": 0.08, - "mem": { - "used": 2218053632, - "active": 2218053632 - }, - "net": { - "rx": 2042.7, - "tx": 1278.3 - }, - "fs": { - "r": 0, - "w": 4 - } - }, - { - "cpu": 0.101, - "mem": { - "used": 2206740480, - "active": 2206740480 - }, - "net": { - "rx": 632.3, - "tx": 898.9 - }, - "fs": { - "r": 0, - "w": 0.5 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2247430144, - "active": 2247430144 - }, - "net": { - "rx": 2077.5, - "tx": 3744.5 - }, - "fs": { - "r": 0, - "w": 1 - } - }, - { - "cpu": 0.05, - "mem": { - "used": 2253754368, - "active": 2253754368 - }, - "net": { - "rx": 1639, - "tx": 833.3 - }, - "fs": { - "r": 0, - "w": 10 - } - }, - { - "cpu": 0.055, - "mem": { - "used": 2253758464, - "active": 2253758464 - }, - "net": { - "rx": 242.4, - "tx": 569.1 - }, - "fs": { - "r": 0, - "w": 0.5 - } - }, - { - "cpu": 0.045, - "mem": { - "used": 2249195520, - "active": 2249195520 - }, - "net": { - "rx": 336.7, - "tx": 473.5 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.352, - "mem": { - "used": 2243305472, - "active": 2243305472 - }, - "net": { - "rx": 23319.5, - "tx": 275147.5 - }, - "fs": { - "r": 23.9, - "w": 7.3 - } - }, - { - "cpu": 0.051, - "mem": { - "used": 2219544576, - "active": 2219544576 - }, - "net": { - "rx": 131.7, - "tx": 440.6 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.065, - "mem": { - "used": 2226626560, - "active": 2226626560 - }, - "net": { - "rx": 3026.6, - "tx": 128228.1 - }, - "fs": { - "r": 0, - "w": 26.5 - } - }, - { - "cpu": 0.07, - "mem": { - "used": 2222542848, - "active": 2222542848 - }, - "net": { - "rx": 6914.3, - "tx": 57211.8 - }, - "fs": { - "r": 3.4, - "w": 22.1 - } - }, - { - "cpu": 0.07, - "mem": { - "used": 2230108160, - "active": 2230108160 - }, - "net": { - "rx": 264.4, - "tx": 461.2 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.055, - "mem": { - "used": 2228707328, - "active": 2228707328 - }, - "net": { - "rx": 1842.3, - "tx": 1660.2 - }, - "fs": { - "r": 0.5, - "w": 5.5 - } - }, - { - "cpu": 0.055, - "mem": { - "used": 2224680960, - "active": 2224680960 - }, - "net": { - "rx": 231.8, - "tx": 2439 - }, - "fs": { - "r": 0, - "w": 0.5 - } - }, - { - "cpu": 0.075, - "mem": { - "used": 2220605440, - "active": 2220605440 - }, - "net": { - "rx": 9978.1, - "tx": 9058.6 - }, - "fs": { - "r": 0, - "w": 4.5 - } - }, - { - "cpu": 0.065, - "mem": { - "used": 2215976960, - "active": 2215976960 - }, - "net": { - "rx": 1503.3, - "tx": 3651.3 - }, - "fs": { - "r": 0, - "w": 0.5 - } - }, - { - "cpu": 0.056, - "mem": { - "used": 2217205760, - "active": 2217205760 - }, - "net": { - "rx": 569, - "tx": 691.7 - }, - "fs": { - "r": 0, - "w": 1 - } - }, - { - "cpu": 0.061, - "mem": { - "used": 2225774592, - "active": 2225774592 - }, - "net": { - "rx": 47019.3, - "tx": 12020.3 - }, - "fs": { - "r": 4, - "w": 6.9 - } - }, - { - "cpu": 0.085, - "mem": { - "used": 2218438656, - "active": 2218438656 - }, - "net": { - "rx": 6493, - "tx": 3608.1 - }, - "fs": { - "r": 0, - "w": 1.5 - } - }, - { - "cpu": 0.05, - "mem": { - "used": 2222612480, - "active": 2222612480 - }, - "net": { - "rx": 196.7, - "tx": 386.5 - }, - "fs": { - "r": 0, - "w": 3 - } - }, - { - "cpu": 0.05, - "mem": { - "used": 2229645312, - "active": 2229645312 - }, - "net": { - "rx": 194, - "tx": 477.5 - }, - "fs": { - "r": 0, - "w": 0 - } - }, - { - "cpu": 0.06, - "mem": { - "used": 2229391360, - "active": 2229391360 - }, - "net": { - "rx": 226.9, - "tx": 397.9 - }, - "fs": { - "r": 0, - "w": 1.5 - } - }, - { - "cpu": 0.07, - "mem": { - "used": 2221457408, - "active": 2221457408 - }, - "net": { - "rx": 3488.2, - "tx": 2804.4 - }, - "fs": { - "r": 0, - "w": 97 - } - }, - { - "cpu": 0.07, - "mem": { - "used": 2220683264, - "active": 2220683264 - }, - "net": { - "rx": 247, - "tx": 554.4 - }, - "fs": { - "r": 0, - "w": 17.2 - } - }, - { - "cpu": 0.065, - "mem": { - "used": 2220699648, - "active": 2220699648 - }, - "net": { - "rx": 197.6, - "tx": 307.4 - }, - "fs": { - "r": 0, - "w": 0.5 - } - }, - { - "cpu": 0.086, - "mem": { - "used": 2227322880, - "active": 2227322880 - }, - "net": { - "rx": 2095, - "tx": 1205.4 - }, - "fs": { - "r": 0, - "w": 22.8 - } - } - ] - } -} \ No newline at end of file diff --git a/lib/src/data/streaming/streaming_response.dart b/lib/src/data/streaming/streaming_response.dart index ba98037e..92779ec0 100644 --- a/lib/src/data/streaming/streaming_response.dart +++ b/lib/src/data/streaming/streaming_response.dart @@ -1,5 +1,6 @@ import 'package:freezed_annotation/freezed_annotation.dart'; import 'package:misskey_dart/misskey_dart.dart'; +import 'package:misskey_dart/src/data/streaming/timeline_deleted.dart'; import 'package:misskey_dart/src/enums/broadcast_event_type.dart'; import 'package:misskey_dart/src/enums/channel_event_type.dart'; @@ -20,19 +21,24 @@ sealed class StreamingResponse with _$StreamingResponse { @FreezedUnionValue("emojiAdded") const factory StreamingResponse.emojiAdded({ - required BroadcastStreamEvent body, + required EmojiAddedStreamEvent body, }) = StreamingChannelEmojiAddedResponse; @FreezedUnionValue("emojiUpdated") const factory StreamingResponse.emojiUpdated({ - required BroadcastStreamEvent body, + required EmojiUpdatedStreamEvent body, }) = StreamingChannelEmojiUpdatedResponse; @FreezedUnionValue("emojiDeleted") const factory StreamingResponse.emojiDeleted({ - required BroadcastStreamEvent body, + required EmojiDeletedStreamEvent body, }) = StreamingChannelEmojiDeletedResponse; + @FreezedUnionValue("announcementCreated") + const factory StreamingResponse.announcementCreated({ + required AnnouncementCreatedStreamEvent body, + }) = StreamingChannelAnnouncementCreatedResponse; + const factory StreamingResponse.fallback({ required Object body, }) = StreamingChannelUnknownResponse; @@ -41,6 +47,40 @@ sealed class StreamingResponse with _$StreamingResponse { _$StreamingResponseFromJson(json); } +@freezed +class EmojiAddedStreamEvent with _$EmojiAddedStreamEvent { + const factory EmojiAddedStreamEvent({required Emoji emoji}) = + _EmojiAddedStreamEvent; + factory EmojiAddedStreamEvent.fromJson(Map json) => + _$EmojiAddedStreamEventFromJson(json); +} + +@freezed +class EmojiUpdatedStreamEvent with _$EmojiUpdatedStreamEvent { + const factory EmojiUpdatedStreamEvent({required List emojis}) = + _EmojiUpdatedStreamEvent; + factory EmojiUpdatedStreamEvent.fromJson(Map json) => + _$EmojiUpdatedStreamEventFromJson(json); +} + +@freezed +class EmojiDeletedStreamEvent with _$EmojiDeletedStreamEvent { + const factory EmojiDeletedStreamEvent({required List emojis}) = + _EmojiDeletedStreamEvent; + factory EmojiDeletedStreamEvent.fromJson(Map json) => + _$EmojiDeletedStreamEventFromJson(json); +} + +@freezed +class AnnouncementCreatedStreamEvent with _$AnnouncementCreatedStreamEvent { + const factory AnnouncementCreatedStreamEvent({ + required AnnouncementsResponse announcement, + }) = _AnnouncementCreatedStreamEvent; + + factory AnnouncementCreatedStreamEvent.fromJson(Map json) => + _$AnnouncementCreatedStreamEventFromJson(json); +} + @Freezed(unionKey: "type") sealed class ChannelStreamEvent with _$ChannelStreamEvent { @FreezedUnionValue("note") @@ -64,7 +104,6 @@ sealed class ChannelStreamEvent with _$ChannelStreamEvent { }) = StatsChannelEvent; // list - @FreezedUnionValue("userAdded") const factory ChannelStreamEvent.userAdded({ required String id, @@ -140,7 +179,7 @@ sealed class ChannelStreamEvent with _$ChannelStreamEvent { @FreezedUnionValue("unreadMention") const factory ChannelStreamEvent.unreadMention({ required String id, - required Note body, + required String body, }) = UnreadMentionChannelEvent; @FreezedUnionValue("readAllUnreadMentions") @@ -149,9 +188,9 @@ sealed class ChannelStreamEvent with _$ChannelStreamEvent { }) = ReadAllUnreadMentionsChannelEvent; @FreezedUnionValue("unreadSpecifiedNote") - const factory ChannelStreamEvent.uneradSpecifiedNote({ + const factory ChannelStreamEvent.unreadSpecifiedNote({ required String id, - required Note body, + required String body, }) = UnreadSpecifiedNoteChannelEvent; @FreezedUnionValue("readAllUnreadSpecifiedNotes") @@ -168,7 +207,7 @@ sealed class ChannelStreamEvent with _$ChannelStreamEvent { @FreezedUnionValue("readAllAnnouncements") const factory ChannelStreamEvent.readAllAnnouncements({ required String id, - }) = ReadAllAnnouncements; + }) = ReadAllAnnouncementsChannelEvent; factory ChannelStreamEvent.fromJson(Map json) => _$ChannelStreamEventFromJson(json); @@ -191,7 +230,7 @@ sealed class NoteUpdateStreamEvent with _$NoteUpdateStreamEvent { @FreezedUnionValue("deleted") const factory NoteUpdateStreamEvent.deleted({ required String id, - required DateTime body, + required TimelineDeleted body, }) = DeletedChannelEvent; @FreezedUnionValue("pollVoted") @@ -209,14 +248,3 @@ sealed class NoteUpdateStreamEvent with _$NoteUpdateStreamEvent { factory NoteUpdateStreamEvent.fromJson(Map json) => _$NoteUpdateStreamEventFromJson(json); } - -@Freezed(unionKey: "type") -sealed class BroadcastStreamEvent with _$BroadcastStreamEvent { - const factory BroadcastStreamEvent.broadcast({ - @BroadcastEventTypeJsonConverter() required BroadcastEventType type, - required Map body, - }) = BroadcastChannelEvent; - - factory BroadcastStreamEvent.fromJson(Map json) => - _$BroadcastStreamEventFromJson(json); -} diff --git a/lib/src/data/streaming/streaming_response.freezed.dart b/lib/src/data/streaming/streaming_response.freezed.dart index 7fb14561..ed79c4bb 100644 --- a/lib/src/data/streaming/streaming_response.freezed.dart +++ b/lib/src/data/streaming/streaming_response.freezed.dart @@ -26,6 +26,8 @@ StreamingResponse _$StreamingResponseFromJson(Map json) { return StreamingChannelEmojiUpdatedResponse.fromJson(json); case 'emojiDeleted': return StreamingChannelEmojiDeletedResponse.fromJson(json); + case 'announcementCreated': + return StreamingChannelAnnouncementCreatedResponse.fromJson(json); default: return StreamingChannelUnknownResponse.fromJson(json); @@ -39,9 +41,11 @@ mixin _$StreamingResponse { TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) => throw _privateConstructorUsedError; @@ -49,9 +53,10 @@ mixin _$StreamingResponse { TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) => throw _privateConstructorUsedError; @@ -59,9 +64,10 @@ mixin _$StreamingResponse { TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) => @@ -77,6 +83,8 @@ mixin _$StreamingResponse { emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) => throw _privateConstructorUsedError; @@ -87,6 +95,8 @@ mixin _$StreamingResponse { TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) => throw _privateConstructorUsedError; @@ -97,6 +107,8 @@ mixin _$StreamingResponse { TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult Function(StreamingChannelUnknownResponse value)? fallback, required TResult orElse(), }) => @@ -211,9 +223,11 @@ class _$StreamingChannelResponseImpl implements StreamingChannelResponse { TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) { return channel(body); @@ -224,9 +238,10 @@ class _$StreamingChannelResponseImpl implements StreamingChannelResponse { TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) { return channel?.call(body); @@ -237,9 +252,10 @@ class _$StreamingChannelResponseImpl implements StreamingChannelResponse { TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) { @@ -261,6 +277,8 @@ class _$StreamingChannelResponseImpl implements StreamingChannelResponse { emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) { return channel(this); @@ -274,6 +292,8 @@ class _$StreamingChannelResponseImpl implements StreamingChannelResponse { TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) { return channel?.call(this); @@ -287,6 +307,8 @@ class _$StreamingChannelResponseImpl implements StreamingChannelResponse { TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult Function(StreamingChannelUnknownResponse value)? fallback, required TResult orElse(), }) { @@ -411,9 +433,11 @@ class _$StreamingChannelNoteUpdatedResponseImpl TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) { return noteUpdated(body); @@ -424,9 +448,10 @@ class _$StreamingChannelNoteUpdatedResponseImpl TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) { return noteUpdated?.call(body); @@ -437,9 +462,10 @@ class _$StreamingChannelNoteUpdatedResponseImpl TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) { @@ -461,6 +487,8 @@ class _$StreamingChannelNoteUpdatedResponseImpl emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) { return noteUpdated(this); @@ -474,6 +502,8 @@ class _$StreamingChannelNoteUpdatedResponseImpl TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) { return noteUpdated?.call(this); @@ -487,6 +517,8 @@ class _$StreamingChannelNoteUpdatedResponseImpl TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult Function(StreamingChannelUnknownResponse value)? fallback, required TResult orElse(), }) { @@ -529,9 +561,9 @@ abstract class _$$StreamingChannelEmojiAddedResponseImplCopyWith<$Res> { $Res Function(_$StreamingChannelEmojiAddedResponseImpl) then) = __$$StreamingChannelEmojiAddedResponseImplCopyWithImpl<$Res>; @useResult - $Res call({BroadcastStreamEvent body}); + $Res call({EmojiAddedStreamEvent body}); - $BroadcastStreamEventCopyWith<$Res> get body; + $EmojiAddedStreamEventCopyWith<$Res> get body; } /// @nodoc @@ -553,14 +585,14 @@ class __$$StreamingChannelEmojiAddedResponseImplCopyWithImpl<$Res> body: null == body ? _value.body : body // ignore: cast_nullable_to_non_nullable - as BroadcastStreamEvent, + as EmojiAddedStreamEvent, )); } @override @pragma('vm:prefer-inline') - $BroadcastStreamEventCopyWith<$Res> get body { - return $BroadcastStreamEventCopyWith<$Res>(_value.body, (value) { + $EmojiAddedStreamEventCopyWith<$Res> get body { + return $EmojiAddedStreamEventCopyWith<$Res>(_value.body, (value) { return _then(_value.copyWith(body: value)); }); } @@ -579,7 +611,7 @@ class _$StreamingChannelEmojiAddedResponseImpl _$$StreamingChannelEmojiAddedResponseImplFromJson(json); @override - final BroadcastStreamEvent body; + final EmojiAddedStreamEvent body; @JsonKey(name: 'type') final String $type; @@ -614,9 +646,11 @@ class _$StreamingChannelEmojiAddedResponseImpl TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) { return emojiAdded(body); @@ -627,9 +661,10 @@ class _$StreamingChannelEmojiAddedResponseImpl TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) { return emojiAdded?.call(body); @@ -640,9 +675,10 @@ class _$StreamingChannelEmojiAddedResponseImpl TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) { @@ -664,6 +700,8 @@ class _$StreamingChannelEmojiAddedResponseImpl emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) { return emojiAdded(this); @@ -677,6 +715,8 @@ class _$StreamingChannelEmojiAddedResponseImpl TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) { return emojiAdded?.call(this); @@ -690,6 +730,8 @@ class _$StreamingChannelEmojiAddedResponseImpl TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult Function(StreamingChannelUnknownResponse value)? fallback, required TResult orElse(), }) { @@ -709,7 +751,7 @@ class _$StreamingChannelEmojiAddedResponseImpl abstract class StreamingChannelEmojiAddedResponse implements StreamingResponse { const factory StreamingChannelEmojiAddedResponse( - {required final BroadcastStreamEvent body}) = + {required final EmojiAddedStreamEvent body}) = _$StreamingChannelEmojiAddedResponseImpl; factory StreamingChannelEmojiAddedResponse.fromJson( @@ -717,7 +759,7 @@ abstract class StreamingChannelEmojiAddedResponse implements StreamingResponse { _$StreamingChannelEmojiAddedResponseImpl.fromJson; @override - BroadcastStreamEvent get body; + EmojiAddedStreamEvent get body; @JsonKey(ignore: true) _$$StreamingChannelEmojiAddedResponseImplCopyWith< _$StreamingChannelEmojiAddedResponseImpl> @@ -731,9 +773,9 @@ abstract class _$$StreamingChannelEmojiUpdatedResponseImplCopyWith<$Res> { $Res Function(_$StreamingChannelEmojiUpdatedResponseImpl) then) = __$$StreamingChannelEmojiUpdatedResponseImplCopyWithImpl<$Res>; @useResult - $Res call({BroadcastStreamEvent body}); + $Res call({EmojiUpdatedStreamEvent body}); - $BroadcastStreamEventCopyWith<$Res> get body; + $EmojiUpdatedStreamEventCopyWith<$Res> get body; } /// @nodoc @@ -755,14 +797,14 @@ class __$$StreamingChannelEmojiUpdatedResponseImplCopyWithImpl<$Res> body: null == body ? _value.body : body // ignore: cast_nullable_to_non_nullable - as BroadcastStreamEvent, + as EmojiUpdatedStreamEvent, )); } @override @pragma('vm:prefer-inline') - $BroadcastStreamEventCopyWith<$Res> get body { - return $BroadcastStreamEventCopyWith<$Res>(_value.body, (value) { + $EmojiUpdatedStreamEventCopyWith<$Res> get body { + return $EmojiUpdatedStreamEventCopyWith<$Res>(_value.body, (value) { return _then(_value.copyWith(body: value)); }); } @@ -781,7 +823,7 @@ class _$StreamingChannelEmojiUpdatedResponseImpl _$$StreamingChannelEmojiUpdatedResponseImplFromJson(json); @override - final BroadcastStreamEvent body; + final EmojiUpdatedStreamEvent body; @JsonKey(name: 'type') final String $type; @@ -816,9 +858,11 @@ class _$StreamingChannelEmojiUpdatedResponseImpl TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) { return emojiUpdated(body); @@ -829,9 +873,10 @@ class _$StreamingChannelEmojiUpdatedResponseImpl TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) { return emojiUpdated?.call(body); @@ -842,9 +887,10 @@ class _$StreamingChannelEmojiUpdatedResponseImpl TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) { @@ -866,6 +912,8 @@ class _$StreamingChannelEmojiUpdatedResponseImpl emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) { return emojiUpdated(this); @@ -879,6 +927,8 @@ class _$StreamingChannelEmojiUpdatedResponseImpl TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) { return emojiUpdated?.call(this); @@ -892,6 +942,8 @@ class _$StreamingChannelEmojiUpdatedResponseImpl TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult Function(StreamingChannelUnknownResponse value)? fallback, required TResult orElse(), }) { @@ -912,7 +964,7 @@ class _$StreamingChannelEmojiUpdatedResponseImpl abstract class StreamingChannelEmojiUpdatedResponse implements StreamingResponse { const factory StreamingChannelEmojiUpdatedResponse( - {required final BroadcastStreamEvent body}) = + {required final EmojiUpdatedStreamEvent body}) = _$StreamingChannelEmojiUpdatedResponseImpl; factory StreamingChannelEmojiUpdatedResponse.fromJson( @@ -920,7 +972,7 @@ abstract class StreamingChannelEmojiUpdatedResponse _$StreamingChannelEmojiUpdatedResponseImpl.fromJson; @override - BroadcastStreamEvent get body; + EmojiUpdatedStreamEvent get body; @JsonKey(ignore: true) _$$StreamingChannelEmojiUpdatedResponseImplCopyWith< _$StreamingChannelEmojiUpdatedResponseImpl> @@ -934,9 +986,9 @@ abstract class _$$StreamingChannelEmojiDeletedResponseImplCopyWith<$Res> { $Res Function(_$StreamingChannelEmojiDeletedResponseImpl) then) = __$$StreamingChannelEmojiDeletedResponseImplCopyWithImpl<$Res>; @useResult - $Res call({BroadcastStreamEvent body}); + $Res call({EmojiDeletedStreamEvent body}); - $BroadcastStreamEventCopyWith<$Res> get body; + $EmojiDeletedStreamEventCopyWith<$Res> get body; } /// @nodoc @@ -958,14 +1010,14 @@ class __$$StreamingChannelEmojiDeletedResponseImplCopyWithImpl<$Res> body: null == body ? _value.body : body // ignore: cast_nullable_to_non_nullable - as BroadcastStreamEvent, + as EmojiDeletedStreamEvent, )); } @override @pragma('vm:prefer-inline') - $BroadcastStreamEventCopyWith<$Res> get body { - return $BroadcastStreamEventCopyWith<$Res>(_value.body, (value) { + $EmojiDeletedStreamEventCopyWith<$Res> get body { + return $EmojiDeletedStreamEventCopyWith<$Res>(_value.body, (value) { return _then(_value.copyWith(body: value)); }); } @@ -984,7 +1036,7 @@ class _$StreamingChannelEmojiDeletedResponseImpl _$$StreamingChannelEmojiDeletedResponseImplFromJson(json); @override - final BroadcastStreamEvent body; + final EmojiDeletedStreamEvent body; @JsonKey(name: 'type') final String $type; @@ -1019,9 +1071,11 @@ class _$StreamingChannelEmojiDeletedResponseImpl TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) { return emojiDeleted(body); @@ -1032,9 +1086,10 @@ class _$StreamingChannelEmojiDeletedResponseImpl TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) { return emojiDeleted?.call(body); @@ -1045,9 +1100,10 @@ class _$StreamingChannelEmojiDeletedResponseImpl TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) { @@ -1069,6 +1125,8 @@ class _$StreamingChannelEmojiDeletedResponseImpl emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) { return emojiDeleted(this); @@ -1082,6 +1140,8 @@ class _$StreamingChannelEmojiDeletedResponseImpl TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) { return emojiDeleted?.call(this); @@ -1095,6 +1155,8 @@ class _$StreamingChannelEmojiDeletedResponseImpl TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult Function(StreamingChannelUnknownResponse value)? fallback, required TResult orElse(), }) { @@ -1115,7 +1177,7 @@ class _$StreamingChannelEmojiDeletedResponseImpl abstract class StreamingChannelEmojiDeletedResponse implements StreamingResponse { const factory StreamingChannelEmojiDeletedResponse( - {required final BroadcastStreamEvent body}) = + {required final EmojiDeletedStreamEvent body}) = _$StreamingChannelEmojiDeletedResponseImpl; factory StreamingChannelEmojiDeletedResponse.fromJson( @@ -1123,13 +1185,231 @@ abstract class StreamingChannelEmojiDeletedResponse _$StreamingChannelEmojiDeletedResponseImpl.fromJson; @override - BroadcastStreamEvent get body; + EmojiDeletedStreamEvent get body; @JsonKey(ignore: true) _$$StreamingChannelEmojiDeletedResponseImplCopyWith< _$StreamingChannelEmojiDeletedResponseImpl> get copyWith => throw _privateConstructorUsedError; } +/// @nodoc +abstract class _$$StreamingChannelAnnouncementCreatedResponseImplCopyWith< + $Res> { + factory _$$StreamingChannelAnnouncementCreatedResponseImplCopyWith( + _$StreamingChannelAnnouncementCreatedResponseImpl value, + $Res Function(_$StreamingChannelAnnouncementCreatedResponseImpl) + then) = + __$$StreamingChannelAnnouncementCreatedResponseImplCopyWithImpl<$Res>; + @useResult + $Res call({AnnouncementCreatedStreamEvent body}); + + $AnnouncementCreatedStreamEventCopyWith<$Res> get body; +} + +/// @nodoc +class __$$StreamingChannelAnnouncementCreatedResponseImplCopyWithImpl<$Res> + extends _$StreamingResponseCopyWithImpl<$Res, + _$StreamingChannelAnnouncementCreatedResponseImpl> + implements + _$$StreamingChannelAnnouncementCreatedResponseImplCopyWith<$Res> { + __$$StreamingChannelAnnouncementCreatedResponseImplCopyWithImpl( + _$StreamingChannelAnnouncementCreatedResponseImpl _value, + $Res Function(_$StreamingChannelAnnouncementCreatedResponseImpl) _then) + : super(_value, _then); + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? body = null, + }) { + return _then(_$StreamingChannelAnnouncementCreatedResponseImpl( + body: null == body + ? _value.body + : body // ignore: cast_nullable_to_non_nullable + as AnnouncementCreatedStreamEvent, + )); + } + + @override + @pragma('vm:prefer-inline') + $AnnouncementCreatedStreamEventCopyWith<$Res> get body { + return $AnnouncementCreatedStreamEventCopyWith<$Res>(_value.body, (value) { + return _then(_value.copyWith(body: value)); + }); + } +} + +/// @nodoc +@JsonSerializable() +class _$StreamingChannelAnnouncementCreatedResponseImpl + implements StreamingChannelAnnouncementCreatedResponse { + const _$StreamingChannelAnnouncementCreatedResponseImpl( + {required this.body, final String? $type}) + : $type = $type ?? 'announcementCreated'; + + factory _$StreamingChannelAnnouncementCreatedResponseImpl.fromJson( + Map json) => + _$$StreamingChannelAnnouncementCreatedResponseImplFromJson(json); + + @override + final AnnouncementCreatedStreamEvent body; + + @JsonKey(name: 'type') + final String $type; + + @override + String toString() { + return 'StreamingResponse.announcementCreated(body: $body)'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && + other is _$StreamingChannelAnnouncementCreatedResponseImpl && + (identical(other.body, body) || other.body == body)); + } + + @JsonKey(ignore: true) + @override + int get hashCode => Object.hash(runtimeType, body); + + @JsonKey(ignore: true) + @override + @pragma('vm:prefer-inline') + _$$StreamingChannelAnnouncementCreatedResponseImplCopyWith< + _$StreamingChannelAnnouncementCreatedResponseImpl> + get copyWith => + __$$StreamingChannelAnnouncementCreatedResponseImplCopyWithImpl< + _$StreamingChannelAnnouncementCreatedResponseImpl>( + this, _$identity); + + @override + @optionalTypeArgs + TResult when({ + required TResult Function(ChannelStreamEvent body) channel, + required TResult Function(NoteUpdateStreamEvent body) noteUpdated, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, + required TResult Function(Object body) fallback, + }) { + return announcementCreated(body); + } + + @override + @optionalTypeArgs + TResult? whenOrNull({ + TResult? Function(ChannelStreamEvent body)? channel, + TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, + TResult? Function(Object body)? fallback, + }) { + return announcementCreated?.call(body); + } + + @override + @optionalTypeArgs + TResult maybeWhen({ + TResult Function(ChannelStreamEvent body)? channel, + TResult Function(NoteUpdateStreamEvent body)? noteUpdated, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, + TResult Function(Object body)? fallback, + required TResult orElse(), + }) { + if (announcementCreated != null) { + return announcementCreated(body); + } + return orElse(); + } + + @override + @optionalTypeArgs + TResult map({ + required TResult Function(StreamingChannelResponse value) channel, + required TResult Function(StreamingChannelNoteUpdatedResponse value) + noteUpdated, + required TResult Function(StreamingChannelEmojiAddedResponse value) + emojiAdded, + required TResult Function(StreamingChannelEmojiUpdatedResponse value) + emojiUpdated, + required TResult Function(StreamingChannelEmojiDeletedResponse value) + emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, + required TResult Function(StreamingChannelUnknownResponse value) fallback, + }) { + return announcementCreated(this); + } + + @override + @optionalTypeArgs + TResult? mapOrNull({ + TResult? Function(StreamingChannelResponse value)? channel, + TResult? Function(StreamingChannelNoteUpdatedResponse value)? noteUpdated, + TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, + TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, + TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, + TResult? Function(StreamingChannelUnknownResponse value)? fallback, + }) { + return announcementCreated?.call(this); + } + + @override + @optionalTypeArgs + TResult maybeMap({ + TResult Function(StreamingChannelResponse value)? channel, + TResult Function(StreamingChannelNoteUpdatedResponse value)? noteUpdated, + TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, + TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, + TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, + TResult Function(StreamingChannelUnknownResponse value)? fallback, + required TResult orElse(), + }) { + if (announcementCreated != null) { + return announcementCreated(this); + } + return orElse(); + } + + @override + Map toJson() { + return _$$StreamingChannelAnnouncementCreatedResponseImplToJson( + this, + ); + } +} + +abstract class StreamingChannelAnnouncementCreatedResponse + implements StreamingResponse { + const factory StreamingChannelAnnouncementCreatedResponse( + {required final AnnouncementCreatedStreamEvent body}) = + _$StreamingChannelAnnouncementCreatedResponseImpl; + + factory StreamingChannelAnnouncementCreatedResponse.fromJson( + Map json) = + _$StreamingChannelAnnouncementCreatedResponseImpl.fromJson; + + @override + AnnouncementCreatedStreamEvent get body; + @JsonKey(ignore: true) + _$$StreamingChannelAnnouncementCreatedResponseImplCopyWith< + _$StreamingChannelAnnouncementCreatedResponseImpl> + get copyWith => throw _privateConstructorUsedError; +} + /// @nodoc abstract class _$$StreamingChannelUnknownResponseImplCopyWith<$Res> { factory _$$StreamingChannelUnknownResponseImplCopyWith( @@ -1210,9 +1490,11 @@ class _$StreamingChannelUnknownResponseImpl TResult when({ required TResult Function(ChannelStreamEvent body) channel, required TResult Function(NoteUpdateStreamEvent body) noteUpdated, - required TResult Function(BroadcastStreamEvent body) emojiAdded, - required TResult Function(BroadcastStreamEvent body) emojiUpdated, - required TResult Function(BroadcastStreamEvent body) emojiDeleted, + required TResult Function(EmojiAddedStreamEvent body) emojiAdded, + required TResult Function(EmojiUpdatedStreamEvent body) emojiUpdated, + required TResult Function(EmojiDeletedStreamEvent body) emojiDeleted, + required TResult Function(AnnouncementCreatedStreamEvent body) + announcementCreated, required TResult Function(Object body) fallback, }) { return fallback(body); @@ -1223,9 +1505,10 @@ class _$StreamingChannelUnknownResponseImpl TResult? whenOrNull({ TResult? Function(ChannelStreamEvent body)? channel, TResult? Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiAdded, - TResult? Function(BroadcastStreamEvent body)? emojiUpdated, - TResult? Function(BroadcastStreamEvent body)? emojiDeleted, + TResult? Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult? Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult? Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult? Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult? Function(Object body)? fallback, }) { return fallback?.call(body); @@ -1236,9 +1519,10 @@ class _$StreamingChannelUnknownResponseImpl TResult maybeWhen({ TResult Function(ChannelStreamEvent body)? channel, TResult Function(NoteUpdateStreamEvent body)? noteUpdated, - TResult Function(BroadcastStreamEvent body)? emojiAdded, - TResult Function(BroadcastStreamEvent body)? emojiUpdated, - TResult Function(BroadcastStreamEvent body)? emojiDeleted, + TResult Function(EmojiAddedStreamEvent body)? emojiAdded, + TResult Function(EmojiUpdatedStreamEvent body)? emojiUpdated, + TResult Function(EmojiDeletedStreamEvent body)? emojiDeleted, + TResult Function(AnnouncementCreatedStreamEvent body)? announcementCreated, TResult Function(Object body)? fallback, required TResult orElse(), }) { @@ -1260,6 +1544,8 @@ class _$StreamingChannelUnknownResponseImpl emojiUpdated, required TResult Function(StreamingChannelEmojiDeletedResponse value) emojiDeleted, + required TResult Function(StreamingChannelAnnouncementCreatedResponse value) + announcementCreated, required TResult Function(StreamingChannelUnknownResponse value) fallback, }) { return fallback(this); @@ -1273,48 +1559,672 @@ class _$StreamingChannelUnknownResponseImpl TResult? Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, TResult? Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, TResult? Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult? Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, TResult? Function(StreamingChannelUnknownResponse value)? fallback, }) { return fallback?.call(this); } @override - @optionalTypeArgs - TResult maybeMap({ - TResult Function(StreamingChannelResponse value)? channel, - TResult Function(StreamingChannelNoteUpdatedResponse value)? noteUpdated, - TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, - TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, - TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, - TResult Function(StreamingChannelUnknownResponse value)? fallback, - required TResult orElse(), - }) { - if (fallback != null) { - return fallback(this); - } - return orElse(); + @optionalTypeArgs + TResult maybeMap({ + TResult Function(StreamingChannelResponse value)? channel, + TResult Function(StreamingChannelNoteUpdatedResponse value)? noteUpdated, + TResult Function(StreamingChannelEmojiAddedResponse value)? emojiAdded, + TResult Function(StreamingChannelEmojiUpdatedResponse value)? emojiUpdated, + TResult Function(StreamingChannelEmojiDeletedResponse value)? emojiDeleted, + TResult Function(StreamingChannelAnnouncementCreatedResponse value)? + announcementCreated, + TResult Function(StreamingChannelUnknownResponse value)? fallback, + required TResult orElse(), + }) { + if (fallback != null) { + return fallback(this); + } + return orElse(); + } + + @override + Map toJson() { + return _$$StreamingChannelUnknownResponseImplToJson( + this, + ); + } +} + +abstract class StreamingChannelUnknownResponse implements StreamingResponse { + const factory StreamingChannelUnknownResponse({required final Object body}) = + _$StreamingChannelUnknownResponseImpl; + + factory StreamingChannelUnknownResponse.fromJson(Map json) = + _$StreamingChannelUnknownResponseImpl.fromJson; + + @override + Object get body; + @JsonKey(ignore: true) + _$$StreamingChannelUnknownResponseImplCopyWith< + _$StreamingChannelUnknownResponseImpl> + get copyWith => throw _privateConstructorUsedError; +} + +EmojiAddedStreamEvent _$EmojiAddedStreamEventFromJson( + Map json) { + return _EmojiAddedStreamEvent.fromJson(json); +} + +/// @nodoc +mixin _$EmojiAddedStreamEvent { + Emoji get emoji => throw _privateConstructorUsedError; + + Map toJson() => throw _privateConstructorUsedError; + @JsonKey(ignore: true) + $EmojiAddedStreamEventCopyWith get copyWith => + throw _privateConstructorUsedError; +} + +/// @nodoc +abstract class $EmojiAddedStreamEventCopyWith<$Res> { + factory $EmojiAddedStreamEventCopyWith(EmojiAddedStreamEvent value, + $Res Function(EmojiAddedStreamEvent) then) = + _$EmojiAddedStreamEventCopyWithImpl<$Res, EmojiAddedStreamEvent>; + @useResult + $Res call({Emoji emoji}); + + $EmojiCopyWith<$Res> get emoji; +} + +/// @nodoc +class _$EmojiAddedStreamEventCopyWithImpl<$Res, + $Val extends EmojiAddedStreamEvent> + implements $EmojiAddedStreamEventCopyWith<$Res> { + _$EmojiAddedStreamEventCopyWithImpl(this._value, this._then); + + // ignore: unused_field + final $Val _value; + // ignore: unused_field + final $Res Function($Val) _then; + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? emoji = null, + }) { + return _then(_value.copyWith( + emoji: null == emoji + ? _value.emoji + : emoji // ignore: cast_nullable_to_non_nullable + as Emoji, + ) as $Val); + } + + @override + @pragma('vm:prefer-inline') + $EmojiCopyWith<$Res> get emoji { + return $EmojiCopyWith<$Res>(_value.emoji, (value) { + return _then(_value.copyWith(emoji: value) as $Val); + }); + } +} + +/// @nodoc +abstract class _$$EmojiAddedStreamEventImplCopyWith<$Res> + implements $EmojiAddedStreamEventCopyWith<$Res> { + factory _$$EmojiAddedStreamEventImplCopyWith( + _$EmojiAddedStreamEventImpl value, + $Res Function(_$EmojiAddedStreamEventImpl) then) = + __$$EmojiAddedStreamEventImplCopyWithImpl<$Res>; + @override + @useResult + $Res call({Emoji emoji}); + + @override + $EmojiCopyWith<$Res> get emoji; +} + +/// @nodoc +class __$$EmojiAddedStreamEventImplCopyWithImpl<$Res> + extends _$EmojiAddedStreamEventCopyWithImpl<$Res, + _$EmojiAddedStreamEventImpl> + implements _$$EmojiAddedStreamEventImplCopyWith<$Res> { + __$$EmojiAddedStreamEventImplCopyWithImpl(_$EmojiAddedStreamEventImpl _value, + $Res Function(_$EmojiAddedStreamEventImpl) _then) + : super(_value, _then); + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? emoji = null, + }) { + return _then(_$EmojiAddedStreamEventImpl( + emoji: null == emoji + ? _value.emoji + : emoji // ignore: cast_nullable_to_non_nullable + as Emoji, + )); + } +} + +/// @nodoc +@JsonSerializable() +class _$EmojiAddedStreamEventImpl implements _EmojiAddedStreamEvent { + const _$EmojiAddedStreamEventImpl({required this.emoji}); + + factory _$EmojiAddedStreamEventImpl.fromJson(Map json) => + _$$EmojiAddedStreamEventImplFromJson(json); + + @override + final Emoji emoji; + + @override + String toString() { + return 'EmojiAddedStreamEvent(emoji: $emoji)'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && + other is _$EmojiAddedStreamEventImpl && + (identical(other.emoji, emoji) || other.emoji == emoji)); + } + + @JsonKey(ignore: true) + @override + int get hashCode => Object.hash(runtimeType, emoji); + + @JsonKey(ignore: true) + @override + @pragma('vm:prefer-inline') + _$$EmojiAddedStreamEventImplCopyWith<_$EmojiAddedStreamEventImpl> + get copyWith => __$$EmojiAddedStreamEventImplCopyWithImpl< + _$EmojiAddedStreamEventImpl>(this, _$identity); + + @override + Map toJson() { + return _$$EmojiAddedStreamEventImplToJson( + this, + ); + } +} + +abstract class _EmojiAddedStreamEvent implements EmojiAddedStreamEvent { + const factory _EmojiAddedStreamEvent({required final Emoji emoji}) = + _$EmojiAddedStreamEventImpl; + + factory _EmojiAddedStreamEvent.fromJson(Map json) = + _$EmojiAddedStreamEventImpl.fromJson; + + @override + Emoji get emoji; + @override + @JsonKey(ignore: true) + _$$EmojiAddedStreamEventImplCopyWith<_$EmojiAddedStreamEventImpl> + get copyWith => throw _privateConstructorUsedError; +} + +EmojiUpdatedStreamEvent _$EmojiUpdatedStreamEventFromJson( + Map json) { + return _EmojiUpdatedStreamEvent.fromJson(json); +} + +/// @nodoc +mixin _$EmojiUpdatedStreamEvent { + List get emojis => throw _privateConstructorUsedError; + + Map toJson() => throw _privateConstructorUsedError; + @JsonKey(ignore: true) + $EmojiUpdatedStreamEventCopyWith get copyWith => + throw _privateConstructorUsedError; +} + +/// @nodoc +abstract class $EmojiUpdatedStreamEventCopyWith<$Res> { + factory $EmojiUpdatedStreamEventCopyWith(EmojiUpdatedStreamEvent value, + $Res Function(EmojiUpdatedStreamEvent) then) = + _$EmojiUpdatedStreamEventCopyWithImpl<$Res, EmojiUpdatedStreamEvent>; + @useResult + $Res call({List emojis}); +} + +/// @nodoc +class _$EmojiUpdatedStreamEventCopyWithImpl<$Res, + $Val extends EmojiUpdatedStreamEvent> + implements $EmojiUpdatedStreamEventCopyWith<$Res> { + _$EmojiUpdatedStreamEventCopyWithImpl(this._value, this._then); + + // ignore: unused_field + final $Val _value; + // ignore: unused_field + final $Res Function($Val) _then; + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? emojis = null, + }) { + return _then(_value.copyWith( + emojis: null == emojis + ? _value.emojis + : emojis // ignore: cast_nullable_to_non_nullable + as List, + ) as $Val); + } +} + +/// @nodoc +abstract class _$$EmojiUpdatedStreamEventImplCopyWith<$Res> + implements $EmojiUpdatedStreamEventCopyWith<$Res> { + factory _$$EmojiUpdatedStreamEventImplCopyWith( + _$EmojiUpdatedStreamEventImpl value, + $Res Function(_$EmojiUpdatedStreamEventImpl) then) = + __$$EmojiUpdatedStreamEventImplCopyWithImpl<$Res>; + @override + @useResult + $Res call({List emojis}); +} + +/// @nodoc +class __$$EmojiUpdatedStreamEventImplCopyWithImpl<$Res> + extends _$EmojiUpdatedStreamEventCopyWithImpl<$Res, + _$EmojiUpdatedStreamEventImpl> + implements _$$EmojiUpdatedStreamEventImplCopyWith<$Res> { + __$$EmojiUpdatedStreamEventImplCopyWithImpl( + _$EmojiUpdatedStreamEventImpl _value, + $Res Function(_$EmojiUpdatedStreamEventImpl) _then) + : super(_value, _then); + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? emojis = null, + }) { + return _then(_$EmojiUpdatedStreamEventImpl( + emojis: null == emojis + ? _value._emojis + : emojis // ignore: cast_nullable_to_non_nullable + as List, + )); + } +} + +/// @nodoc +@JsonSerializable() +class _$EmojiUpdatedStreamEventImpl implements _EmojiUpdatedStreamEvent { + const _$EmojiUpdatedStreamEventImpl({required final List emojis}) + : _emojis = emojis; + + factory _$EmojiUpdatedStreamEventImpl.fromJson(Map json) => + _$$EmojiUpdatedStreamEventImplFromJson(json); + + final List _emojis; + @override + List get emojis { + if (_emojis is EqualUnmodifiableListView) return _emojis; + // ignore: implicit_dynamic_type + return EqualUnmodifiableListView(_emojis); + } + + @override + String toString() { + return 'EmojiUpdatedStreamEvent(emojis: $emojis)'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && + other is _$EmojiUpdatedStreamEventImpl && + const DeepCollectionEquality().equals(other._emojis, _emojis)); + } + + @JsonKey(ignore: true) + @override + int get hashCode => + Object.hash(runtimeType, const DeepCollectionEquality().hash(_emojis)); + + @JsonKey(ignore: true) + @override + @pragma('vm:prefer-inline') + _$$EmojiUpdatedStreamEventImplCopyWith<_$EmojiUpdatedStreamEventImpl> + get copyWith => __$$EmojiUpdatedStreamEventImplCopyWithImpl< + _$EmojiUpdatedStreamEventImpl>(this, _$identity); + + @override + Map toJson() { + return _$$EmojiUpdatedStreamEventImplToJson( + this, + ); + } +} + +abstract class _EmojiUpdatedStreamEvent implements EmojiUpdatedStreamEvent { + const factory _EmojiUpdatedStreamEvent({required final List emojis}) = + _$EmojiUpdatedStreamEventImpl; + + factory _EmojiUpdatedStreamEvent.fromJson(Map json) = + _$EmojiUpdatedStreamEventImpl.fromJson; + + @override + List get emojis; + @override + @JsonKey(ignore: true) + _$$EmojiUpdatedStreamEventImplCopyWith<_$EmojiUpdatedStreamEventImpl> + get copyWith => throw _privateConstructorUsedError; +} + +EmojiDeletedStreamEvent _$EmojiDeletedStreamEventFromJson( + Map json) { + return _EmojiDeletedStreamEvent.fromJson(json); +} + +/// @nodoc +mixin _$EmojiDeletedStreamEvent { + List get emojis => throw _privateConstructorUsedError; + + Map toJson() => throw _privateConstructorUsedError; + @JsonKey(ignore: true) + $EmojiDeletedStreamEventCopyWith get copyWith => + throw _privateConstructorUsedError; +} + +/// @nodoc +abstract class $EmojiDeletedStreamEventCopyWith<$Res> { + factory $EmojiDeletedStreamEventCopyWith(EmojiDeletedStreamEvent value, + $Res Function(EmojiDeletedStreamEvent) then) = + _$EmojiDeletedStreamEventCopyWithImpl<$Res, EmojiDeletedStreamEvent>; + @useResult + $Res call({List emojis}); +} + +/// @nodoc +class _$EmojiDeletedStreamEventCopyWithImpl<$Res, + $Val extends EmojiDeletedStreamEvent> + implements $EmojiDeletedStreamEventCopyWith<$Res> { + _$EmojiDeletedStreamEventCopyWithImpl(this._value, this._then); + + // ignore: unused_field + final $Val _value; + // ignore: unused_field + final $Res Function($Val) _then; + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? emojis = null, + }) { + return _then(_value.copyWith( + emojis: null == emojis + ? _value.emojis + : emojis // ignore: cast_nullable_to_non_nullable + as List, + ) as $Val); + } +} + +/// @nodoc +abstract class _$$EmojiDeletedStreamEventImplCopyWith<$Res> + implements $EmojiDeletedStreamEventCopyWith<$Res> { + factory _$$EmojiDeletedStreamEventImplCopyWith( + _$EmojiDeletedStreamEventImpl value, + $Res Function(_$EmojiDeletedStreamEventImpl) then) = + __$$EmojiDeletedStreamEventImplCopyWithImpl<$Res>; + @override + @useResult + $Res call({List emojis}); +} + +/// @nodoc +class __$$EmojiDeletedStreamEventImplCopyWithImpl<$Res> + extends _$EmojiDeletedStreamEventCopyWithImpl<$Res, + _$EmojiDeletedStreamEventImpl> + implements _$$EmojiDeletedStreamEventImplCopyWith<$Res> { + __$$EmojiDeletedStreamEventImplCopyWithImpl( + _$EmojiDeletedStreamEventImpl _value, + $Res Function(_$EmojiDeletedStreamEventImpl) _then) + : super(_value, _then); + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? emojis = null, + }) { + return _then(_$EmojiDeletedStreamEventImpl( + emojis: null == emojis + ? _value._emojis + : emojis // ignore: cast_nullable_to_non_nullable + as List, + )); + } +} + +/// @nodoc +@JsonSerializable() +class _$EmojiDeletedStreamEventImpl implements _EmojiDeletedStreamEvent { + const _$EmojiDeletedStreamEventImpl({required final List emojis}) + : _emojis = emojis; + + factory _$EmojiDeletedStreamEventImpl.fromJson(Map json) => + _$$EmojiDeletedStreamEventImplFromJson(json); + + final List _emojis; + @override + List get emojis { + if (_emojis is EqualUnmodifiableListView) return _emojis; + // ignore: implicit_dynamic_type + return EqualUnmodifiableListView(_emojis); + } + + @override + String toString() { + return 'EmojiDeletedStreamEvent(emojis: $emojis)'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && + other is _$EmojiDeletedStreamEventImpl && + const DeepCollectionEquality().equals(other._emojis, _emojis)); + } + + @JsonKey(ignore: true) + @override + int get hashCode => + Object.hash(runtimeType, const DeepCollectionEquality().hash(_emojis)); + + @JsonKey(ignore: true) + @override + @pragma('vm:prefer-inline') + _$$EmojiDeletedStreamEventImplCopyWith<_$EmojiDeletedStreamEventImpl> + get copyWith => __$$EmojiDeletedStreamEventImplCopyWithImpl< + _$EmojiDeletedStreamEventImpl>(this, _$identity); + + @override + Map toJson() { + return _$$EmojiDeletedStreamEventImplToJson( + this, + ); + } +} + +abstract class _EmojiDeletedStreamEvent implements EmojiDeletedStreamEvent { + const factory _EmojiDeletedStreamEvent({required final List emojis}) = + _$EmojiDeletedStreamEventImpl; + + factory _EmojiDeletedStreamEvent.fromJson(Map json) = + _$EmojiDeletedStreamEventImpl.fromJson; + + @override + List get emojis; + @override + @JsonKey(ignore: true) + _$$EmojiDeletedStreamEventImplCopyWith<_$EmojiDeletedStreamEventImpl> + get copyWith => throw _privateConstructorUsedError; +} + +AnnouncementCreatedStreamEvent _$AnnouncementCreatedStreamEventFromJson( + Map json) { + return _AnnouncementCreatedStreamEvent.fromJson(json); +} + +/// @nodoc +mixin _$AnnouncementCreatedStreamEvent { + AnnouncementsResponse get announcement => throw _privateConstructorUsedError; + + Map toJson() => throw _privateConstructorUsedError; + @JsonKey(ignore: true) + $AnnouncementCreatedStreamEventCopyWith + get copyWith => throw _privateConstructorUsedError; +} + +/// @nodoc +abstract class $AnnouncementCreatedStreamEventCopyWith<$Res> { + factory $AnnouncementCreatedStreamEventCopyWith( + AnnouncementCreatedStreamEvent value, + $Res Function(AnnouncementCreatedStreamEvent) then) = + _$AnnouncementCreatedStreamEventCopyWithImpl<$Res, + AnnouncementCreatedStreamEvent>; + @useResult + $Res call({AnnouncementsResponse announcement}); + + $AnnouncementsResponseCopyWith<$Res> get announcement; +} + +/// @nodoc +class _$AnnouncementCreatedStreamEventCopyWithImpl<$Res, + $Val extends AnnouncementCreatedStreamEvent> + implements $AnnouncementCreatedStreamEventCopyWith<$Res> { + _$AnnouncementCreatedStreamEventCopyWithImpl(this._value, this._then); + + // ignore: unused_field + final $Val _value; + // ignore: unused_field + final $Res Function($Val) _then; + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? announcement = null, + }) { + return _then(_value.copyWith( + announcement: null == announcement + ? _value.announcement + : announcement // ignore: cast_nullable_to_non_nullable + as AnnouncementsResponse, + ) as $Val); + } + + @override + @pragma('vm:prefer-inline') + $AnnouncementsResponseCopyWith<$Res> get announcement { + return $AnnouncementsResponseCopyWith<$Res>(_value.announcement, (value) { + return _then(_value.copyWith(announcement: value) as $Val); + }); + } +} + +/// @nodoc +abstract class _$$AnnouncementCreatedStreamEventImplCopyWith<$Res> + implements $AnnouncementCreatedStreamEventCopyWith<$Res> { + factory _$$AnnouncementCreatedStreamEventImplCopyWith( + _$AnnouncementCreatedStreamEventImpl value, + $Res Function(_$AnnouncementCreatedStreamEventImpl) then) = + __$$AnnouncementCreatedStreamEventImplCopyWithImpl<$Res>; + @override + @useResult + $Res call({AnnouncementsResponse announcement}); + + @override + $AnnouncementsResponseCopyWith<$Res> get announcement; +} + +/// @nodoc +class __$$AnnouncementCreatedStreamEventImplCopyWithImpl<$Res> + extends _$AnnouncementCreatedStreamEventCopyWithImpl<$Res, + _$AnnouncementCreatedStreamEventImpl> + implements _$$AnnouncementCreatedStreamEventImplCopyWith<$Res> { + __$$AnnouncementCreatedStreamEventImplCopyWithImpl( + _$AnnouncementCreatedStreamEventImpl _value, + $Res Function(_$AnnouncementCreatedStreamEventImpl) _then) + : super(_value, _then); + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? announcement = null, + }) { + return _then(_$AnnouncementCreatedStreamEventImpl( + announcement: null == announcement + ? _value.announcement + : announcement // ignore: cast_nullable_to_non_nullable + as AnnouncementsResponse, + )); + } +} + +/// @nodoc +@JsonSerializable() +class _$AnnouncementCreatedStreamEventImpl + implements _AnnouncementCreatedStreamEvent { + const _$AnnouncementCreatedStreamEventImpl({required this.announcement}); + + factory _$AnnouncementCreatedStreamEventImpl.fromJson( + Map json) => + _$$AnnouncementCreatedStreamEventImplFromJson(json); + + @override + final AnnouncementsResponse announcement; + + @override + String toString() { + return 'AnnouncementCreatedStreamEvent(announcement: $announcement)'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && + other is _$AnnouncementCreatedStreamEventImpl && + (identical(other.announcement, announcement) || + other.announcement == announcement)); } + @JsonKey(ignore: true) + @override + int get hashCode => Object.hash(runtimeType, announcement); + + @JsonKey(ignore: true) + @override + @pragma('vm:prefer-inline') + _$$AnnouncementCreatedStreamEventImplCopyWith< + _$AnnouncementCreatedStreamEventImpl> + get copyWith => __$$AnnouncementCreatedStreamEventImplCopyWithImpl< + _$AnnouncementCreatedStreamEventImpl>(this, _$identity); + @override Map toJson() { - return _$$StreamingChannelUnknownResponseImplToJson( + return _$$AnnouncementCreatedStreamEventImplToJson( this, ); } } -abstract class StreamingChannelUnknownResponse implements StreamingResponse { - const factory StreamingChannelUnknownResponse({required final Object body}) = - _$StreamingChannelUnknownResponseImpl; +abstract class _AnnouncementCreatedStreamEvent + implements AnnouncementCreatedStreamEvent { + const factory _AnnouncementCreatedStreamEvent( + {required final AnnouncementsResponse announcement}) = + _$AnnouncementCreatedStreamEventImpl; - factory StreamingChannelUnknownResponse.fromJson(Map json) = - _$StreamingChannelUnknownResponseImpl.fromJson; + factory _AnnouncementCreatedStreamEvent.fromJson(Map json) = + _$AnnouncementCreatedStreamEventImpl.fromJson; @override - Object get body; + AnnouncementsResponse get announcement; + @override @JsonKey(ignore: true) - _$$StreamingChannelUnknownResponseImplCopyWith< - _$StreamingChannelUnknownResponseImpl> + _$$AnnouncementCreatedStreamEventImplCopyWith< + _$AnnouncementCreatedStreamEventImpl> get copyWith => throw _privateConstructorUsedError; } @@ -1361,7 +2271,7 @@ ChannelStreamEvent _$ChannelStreamEventFromJson(Map json) { case 'receiveFollowRequest': return ReceiveFollowRequestChannelEvent.fromJson(json); case 'readAllAnnouncements': - return ReadAllAnnouncements.fromJson(json); + return ReadAllAnnouncementsChannelEvent.fromJson(json); default: throw CheckedFromJsonException(json, 'type', 'ChannelStreamEvent', @@ -1397,9 +2307,9 @@ mixin _$ChannelStreamEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -1428,9 +2338,9 @@ mixin _$ChannelStreamEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -1459,9 +2369,9 @@ mixin _$ChannelStreamEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -1491,12 +2401,13 @@ mixin _$ChannelStreamEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) => throw _privateConstructorUsedError; @optionalTypeArgs @@ -1521,12 +2432,13 @@ mixin _$ChannelStreamEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) => throw _privateConstructorUsedError; @optionalTypeArgs @@ -1551,12 +2463,13 @@ mixin _$ChannelStreamEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) => throw _privateConstructorUsedError; @@ -1726,9 +2639,9 @@ class _$NoteChannelEventImpl implements NoteChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -1760,9 +2673,9 @@ class _$NoteChannelEventImpl implements NoteChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -1794,9 +2707,9 @@ class _$NoteChannelEventImpl implements NoteChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -1832,12 +2745,13 @@ class _$NoteChannelEventImpl implements NoteChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return note(this); } @@ -1865,12 +2779,13 @@ class _$NoteChannelEventImpl implements NoteChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return note?.call(this); } @@ -1898,12 +2813,13 @@ class _$NoteChannelEventImpl implements NoteChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (note != null) { @@ -2058,9 +2974,9 @@ class _$StatsLogChannelEventImpl implements StatsLogChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -2092,9 +3008,9 @@ class _$StatsLogChannelEventImpl implements StatsLogChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -2126,9 +3042,9 @@ class _$StatsLogChannelEventImpl implements StatsLogChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -2164,12 +3080,13 @@ class _$StatsLogChannelEventImpl implements StatsLogChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return statsLog(this); } @@ -2197,12 +3114,13 @@ class _$StatsLogChannelEventImpl implements StatsLogChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return statsLog?.call(this); } @@ -2230,12 +3148,13 @@ class _$StatsLogChannelEventImpl implements StatsLogChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (statsLog != null) { @@ -2391,9 +3310,9 @@ class _$StatsChannelEventImpl implements StatsChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -2425,9 +3344,9 @@ class _$StatsChannelEventImpl implements StatsChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -2459,9 +3378,9 @@ class _$StatsChannelEventImpl implements StatsChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -2497,12 +3416,13 @@ class _$StatsChannelEventImpl implements StatsChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return stats(this); } @@ -2530,12 +3450,13 @@ class _$StatsChannelEventImpl implements StatsChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return stats?.call(this); } @@ -2563,12 +3484,13 @@ class _$StatsChannelEventImpl implements StatsChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (stats != null) { @@ -2722,9 +3644,9 @@ class _$UserAddedChannelEventImpl implements UserAddedChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -2756,9 +3678,9 @@ class _$UserAddedChannelEventImpl implements UserAddedChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -2790,9 +3712,9 @@ class _$UserAddedChannelEventImpl implements UserAddedChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -2828,12 +3750,13 @@ class _$UserAddedChannelEventImpl implements UserAddedChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return userAdded(this); } @@ -2861,12 +3784,13 @@ class _$UserAddedChannelEventImpl implements UserAddedChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return userAdded?.call(this); } @@ -2894,12 +3818,13 @@ class _$UserAddedChannelEventImpl implements UserAddedChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (userAdded != null) { @@ -3053,9 +3978,9 @@ class _$UserRemovedChannelEventImpl implements UserRemovedChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -3087,9 +4012,9 @@ class _$UserRemovedChannelEventImpl implements UserRemovedChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -3121,9 +4046,9 @@ class _$UserRemovedChannelEventImpl implements UserRemovedChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -3159,12 +4084,13 @@ class _$UserRemovedChannelEventImpl implements UserRemovedChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return userRemoved(this); } @@ -3192,12 +4118,13 @@ class _$UserRemovedChannelEventImpl implements UserRemovedChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return userRemoved?.call(this); } @@ -3225,12 +4152,13 @@ class _$UserRemovedChannelEventImpl implements UserRemovedChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (userRemoved != null) { @@ -3384,9 +4312,9 @@ class _$NotificationChannelEventImpl implements NotificationChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -3418,9 +4346,9 @@ class _$NotificationChannelEventImpl implements NotificationChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -3452,9 +4380,9 @@ class _$NotificationChannelEventImpl implements NotificationChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -3490,12 +4418,13 @@ class _$NotificationChannelEventImpl implements NotificationChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return notification(this); } @@ -3523,12 +4452,13 @@ class _$NotificationChannelEventImpl implements NotificationChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return notification?.call(this); } @@ -3556,12 +4486,13 @@ class _$NotificationChannelEventImpl implements NotificationChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (notification != null) { @@ -3713,9 +4644,9 @@ class _$MentionChannelEventImpl implements MentionChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -3747,9 +4678,9 @@ class _$MentionChannelEventImpl implements MentionChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -3781,9 +4712,9 @@ class _$MentionChannelEventImpl implements MentionChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -3819,12 +4750,13 @@ class _$MentionChannelEventImpl implements MentionChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return mention(this); } @@ -3852,12 +4784,13 @@ class _$MentionChannelEventImpl implements MentionChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return mention?.call(this); } @@ -3885,12 +4818,13 @@ class _$MentionChannelEventImpl implements MentionChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (mention != null) { @@ -4041,9 +4975,9 @@ class _$ReplyChannelEventImpl implements ReplyChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -4075,9 +5009,9 @@ class _$ReplyChannelEventImpl implements ReplyChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -4109,9 +5043,9 @@ class _$ReplyChannelEventImpl implements ReplyChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -4147,12 +5081,13 @@ class _$ReplyChannelEventImpl implements ReplyChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return reply(this); } @@ -4180,12 +5115,13 @@ class _$ReplyChannelEventImpl implements ReplyChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return reply?.call(this); } @@ -4213,12 +5149,13 @@ class _$ReplyChannelEventImpl implements ReplyChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (reply != null) { @@ -4369,9 +5306,9 @@ class _$RenoteChannelEventImpl implements RenoteChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -4403,9 +5340,9 @@ class _$RenoteChannelEventImpl implements RenoteChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -4437,9 +5374,9 @@ class _$RenoteChannelEventImpl implements RenoteChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -4475,12 +5412,13 @@ class _$RenoteChannelEventImpl implements RenoteChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return renote(this); } @@ -4508,12 +5446,13 @@ class _$RenoteChannelEventImpl implements RenoteChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return renote?.call(this); } @@ -4541,12 +5480,13 @@ class _$RenoteChannelEventImpl implements RenoteChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (renote != null) { @@ -4697,9 +5637,9 @@ class _$FollowChannelEventImpl implements FollowChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -4731,9 +5671,9 @@ class _$FollowChannelEventImpl implements FollowChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -4765,9 +5705,9 @@ class _$FollowChannelEventImpl implements FollowChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -4803,12 +5743,13 @@ class _$FollowChannelEventImpl implements FollowChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return follow(this); } @@ -4836,12 +5777,13 @@ class _$FollowChannelEventImpl implements FollowChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return follow?.call(this); } @@ -4869,12 +5811,13 @@ class _$FollowChannelEventImpl implements FollowChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (follow != null) { @@ -5026,9 +5969,9 @@ class _$FollowedChannelEventImpl implements FollowedChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -5060,9 +6003,9 @@ class _$FollowedChannelEventImpl implements FollowedChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -5094,9 +6037,9 @@ class _$FollowedChannelEventImpl implements FollowedChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -5132,12 +6075,13 @@ class _$FollowedChannelEventImpl implements FollowedChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return followed(this); } @@ -5165,12 +6109,13 @@ class _$FollowedChannelEventImpl implements FollowedChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return followed?.call(this); } @@ -5198,12 +6143,13 @@ class _$FollowedChannelEventImpl implements FollowedChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (followed != null) { @@ -5355,9 +6301,9 @@ class _$UnfollowChannelEventImpl implements UnfollowChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -5389,9 +6335,9 @@ class _$UnfollowChannelEventImpl implements UnfollowChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -5423,9 +6369,9 @@ class _$UnfollowChannelEventImpl implements UnfollowChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -5461,12 +6407,13 @@ class _$UnfollowChannelEventImpl implements UnfollowChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return unfollow(this); } @@ -5494,12 +6441,13 @@ class _$UnfollowChannelEventImpl implements UnfollowChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return unfollow?.call(this); } @@ -5527,12 +6475,13 @@ class _$UnfollowChannelEventImpl implements UnfollowChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (unfollow != null) { @@ -5684,9 +6633,9 @@ class _$MeUpdatedChannelEventImpl implements MeUpdatedChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -5718,9 +6667,9 @@ class _$MeUpdatedChannelEventImpl implements MeUpdatedChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -5752,9 +6701,9 @@ class _$MeUpdatedChannelEventImpl implements MeUpdatedChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -5790,12 +6739,13 @@ class _$MeUpdatedChannelEventImpl implements MeUpdatedChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return meUpdated(this); } @@ -5823,12 +6773,13 @@ class _$MeUpdatedChannelEventImpl implements MeUpdatedChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return meUpdated?.call(this); } @@ -5856,12 +6807,13 @@ class _$MeUpdatedChannelEventImpl implements MeUpdatedChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (meUpdated != null) { @@ -6000,9 +6952,9 @@ class _$ReadAllNotificationsChannelEventImpl required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -6034,9 +6986,9 @@ class _$ReadAllNotificationsChannelEventImpl TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -6068,9 +7020,9 @@ class _$ReadAllNotificationsChannelEventImpl TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -6106,12 +7058,13 @@ class _$ReadAllNotificationsChannelEventImpl required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return readAllNotifications(this); } @@ -6139,12 +7092,13 @@ class _$ReadAllNotificationsChannelEventImpl TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return readAllNotifications?.call(this); } @@ -6172,12 +7126,13 @@ class _$ReadAllNotificationsChannelEventImpl TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (readAllNotifications != null) { @@ -6333,9 +7288,9 @@ class _$UnreadNotificationChannelEventImpl required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -6367,9 +7322,9 @@ class _$UnreadNotificationChannelEventImpl TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -6401,9 +7356,9 @@ class _$UnreadNotificationChannelEventImpl TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -6439,12 +7394,13 @@ class _$UnreadNotificationChannelEventImpl required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return unreadNotification(this); } @@ -6472,12 +7428,13 @@ class _$UnreadNotificationChannelEventImpl TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return unreadNotification?.call(this); } @@ -6505,12 +7462,13 @@ class _$UnreadNotificationChannelEventImpl TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (unreadNotification != null) { @@ -6555,9 +7513,7 @@ abstract class _$$UnreadMentionChannelEventImplCopyWith<$Res> __$$UnreadMentionChannelEventImplCopyWithImpl<$Res>; @override @useResult - $Res call({String id, Note body}); - - $NoteCopyWith<$Res> get body; + $Res call({String id, String body}); } /// @nodoc @@ -6584,17 +7540,9 @@ class __$$UnreadMentionChannelEventImplCopyWithImpl<$Res> body: null == body ? _value.body : body // ignore: cast_nullable_to_non_nullable - as Note, + as String, )); } - - @override - @pragma('vm:prefer-inline') - $NoteCopyWith<$Res> get body { - return $NoteCopyWith<$Res>(_value.body, (value) { - return _then(_value.copyWith(body: value)); - }); - } } /// @nodoc @@ -6610,7 +7558,7 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { @override final String id; @override - final Note body; + final String body; @JsonKey(name: 'type') final String $type; @@ -6666,9 +7614,9 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -6700,9 +7648,9 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -6734,9 +7682,9 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -6772,12 +7720,13 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return unreadMention(this); } @@ -6805,12 +7754,13 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return unreadMention?.call(this); } @@ -6838,12 +7788,13 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (unreadMention != null) { @@ -6863,14 +7814,14 @@ class _$UnreadMentionChannelEventImpl implements UnreadMentionChannelEvent { abstract class UnreadMentionChannelEvent implements ChannelStreamEvent { const factory UnreadMentionChannelEvent( {required final String id, - required final Note body}) = _$UnreadMentionChannelEventImpl; + required final String body}) = _$UnreadMentionChannelEventImpl; factory UnreadMentionChannelEvent.fromJson(Map json) = _$UnreadMentionChannelEventImpl.fromJson; @override String get id; - Note get body; + String get body; @override @JsonKey(ignore: true) _$$UnreadMentionChannelEventImplCopyWith<_$UnreadMentionChannelEventImpl> @@ -6982,9 +7933,9 @@ class _$ReadAllUnreadMentionsChannelEventImpl required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -7016,9 +7967,9 @@ class _$ReadAllUnreadMentionsChannelEventImpl TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -7050,9 +8001,9 @@ class _$ReadAllUnreadMentionsChannelEventImpl TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -7088,12 +8039,13 @@ class _$ReadAllUnreadMentionsChannelEventImpl required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return readAllUnreadMentions(this); } @@ -7121,12 +8073,13 @@ class _$ReadAllUnreadMentionsChannelEventImpl TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return readAllUnreadMentions?.call(this); } @@ -7154,12 +8107,13 @@ class _$ReadAllUnreadMentionsChannelEventImpl TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (readAllUnreadMentions != null) { @@ -7202,9 +8156,7 @@ abstract class _$$UnreadSpecifiedNoteChannelEventImplCopyWith<$Res> __$$UnreadSpecifiedNoteChannelEventImplCopyWithImpl<$Res>; @override @useResult - $Res call({String id, Note body}); - - $NoteCopyWith<$Res> get body; + $Res call({String id, String body}); } /// @nodoc @@ -7231,17 +8183,9 @@ class __$$UnreadSpecifiedNoteChannelEventImplCopyWithImpl<$Res> body: null == body ? _value.body : body // ignore: cast_nullable_to_non_nullable - as Note, + as String, )); } - - @override - @pragma('vm:prefer-inline') - $NoteCopyWith<$Res> get body { - return $NoteCopyWith<$Res>(_value.body, (value) { - return _then(_value.copyWith(body: value)); - }); - } } /// @nodoc @@ -7259,14 +8203,14 @@ class _$UnreadSpecifiedNoteChannelEventImpl @override final String id; @override - final Note body; + final String body; @JsonKey(name: 'type') final String $type; @override String toString() { - return 'ChannelStreamEvent.uneradSpecifiedNote(id: $id, body: $body)'; + return 'ChannelStreamEvent.unreadSpecifiedNote(id: $id, body: $body)'; } @override @@ -7316,14 +8260,14 @@ class _$UnreadSpecifiedNoteChannelEventImpl required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, }) { - return uneradSpecifiedNote(id, body); + return unreadSpecifiedNote(id, body); } @override @@ -7350,14 +8294,14 @@ class _$UnreadSpecifiedNoteChannelEventImpl TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, }) { - return uneradSpecifiedNote?.call(id, body); + return unreadSpecifiedNote?.call(id, body); } @override @@ -7384,16 +8328,16 @@ class _$UnreadSpecifiedNoteChannelEventImpl TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, required TResult orElse(), }) { - if (uneradSpecifiedNote != null) { - return uneradSpecifiedNote(id, body); + if (unreadSpecifiedNote != null) { + return unreadSpecifiedNote(id, body); } return orElse(); } @@ -7422,14 +8366,15 @@ class _$UnreadSpecifiedNoteChannelEventImpl required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { - return uneradSpecifiedNote(this); + return unreadSpecifiedNote(this); } @override @@ -7455,14 +8400,15 @@ class _$UnreadSpecifiedNoteChannelEventImpl TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { - return uneradSpecifiedNote?.call(this); + return unreadSpecifiedNote?.call(this); } @override @@ -7488,16 +8434,17 @@ class _$UnreadSpecifiedNoteChannelEventImpl TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { - if (uneradSpecifiedNote != null) { - return uneradSpecifiedNote(this); + if (unreadSpecifiedNote != null) { + return unreadSpecifiedNote(this); } return orElse(); } @@ -7513,14 +8460,14 @@ class _$UnreadSpecifiedNoteChannelEventImpl abstract class UnreadSpecifiedNoteChannelEvent implements ChannelStreamEvent { const factory UnreadSpecifiedNoteChannelEvent( {required final String id, - required final Note body}) = _$UnreadSpecifiedNoteChannelEventImpl; + required final String body}) = _$UnreadSpecifiedNoteChannelEventImpl; factory UnreadSpecifiedNoteChannelEvent.fromJson(Map json) = _$UnreadSpecifiedNoteChannelEventImpl.fromJson; @override String get id; - Note get body; + String get body; @override @JsonKey(ignore: true) _$$UnreadSpecifiedNoteChannelEventImplCopyWith< @@ -7634,9 +8581,9 @@ class _$ReadAllUnreadSpecifiedNotesChannelEventImpl required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -7668,9 +8615,9 @@ class _$ReadAllUnreadSpecifiedNotesChannelEventImpl TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -7702,9 +8649,9 @@ class _$ReadAllUnreadSpecifiedNotesChannelEventImpl TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -7740,12 +8687,13 @@ class _$ReadAllUnreadSpecifiedNotesChannelEventImpl required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return readAllUnreadSpecifiedNotes(this); } @@ -7773,12 +8721,13 @@ class _$ReadAllUnreadSpecifiedNotesChannelEventImpl TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return readAllUnreadSpecifiedNotes?.call(this); } @@ -7806,12 +8755,13 @@ class _$ReadAllUnreadSpecifiedNotesChannelEventImpl TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (readAllUnreadSpecifiedNotes != null) { @@ -7970,9 +8920,9 @@ class _$ReceiveFollowRequestChannelEventImpl required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -8004,9 +8954,9 @@ class _$ReceiveFollowRequestChannelEventImpl TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -8038,9 +8988,9 @@ class _$ReceiveFollowRequestChannelEventImpl TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -8076,12 +9026,13 @@ class _$ReceiveFollowRequestChannelEventImpl required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return receiveFollowRequest(this); } @@ -8109,12 +9060,13 @@ class _$ReceiveFollowRequestChannelEventImpl TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return receiveFollowRequest?.call(this); } @@ -8142,12 +9094,13 @@ class _$ReceiveFollowRequestChannelEventImpl TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (receiveFollowRequest != null) { @@ -8183,22 +9136,25 @@ abstract class ReceiveFollowRequestChannelEvent implements ChannelStreamEvent { } /// @nodoc -abstract class _$$ReadAllAnnouncementsImplCopyWith<$Res> +abstract class _$$ReadAllAnnouncementsChannelEventImplCopyWith<$Res> implements $ChannelStreamEventCopyWith<$Res> { - factory _$$ReadAllAnnouncementsImplCopyWith(_$ReadAllAnnouncementsImpl value, - $Res Function(_$ReadAllAnnouncementsImpl) then) = - __$$ReadAllAnnouncementsImplCopyWithImpl<$Res>; + factory _$$ReadAllAnnouncementsChannelEventImplCopyWith( + _$ReadAllAnnouncementsChannelEventImpl value, + $Res Function(_$ReadAllAnnouncementsChannelEventImpl) then) = + __$$ReadAllAnnouncementsChannelEventImplCopyWithImpl<$Res>; @override @useResult $Res call({String id}); } /// @nodoc -class __$$ReadAllAnnouncementsImplCopyWithImpl<$Res> - extends _$ChannelStreamEventCopyWithImpl<$Res, _$ReadAllAnnouncementsImpl> - implements _$$ReadAllAnnouncementsImplCopyWith<$Res> { - __$$ReadAllAnnouncementsImplCopyWithImpl(_$ReadAllAnnouncementsImpl _value, - $Res Function(_$ReadAllAnnouncementsImpl) _then) +class __$$ReadAllAnnouncementsChannelEventImplCopyWithImpl<$Res> + extends _$ChannelStreamEventCopyWithImpl<$Res, + _$ReadAllAnnouncementsChannelEventImpl> + implements _$$ReadAllAnnouncementsChannelEventImplCopyWith<$Res> { + __$$ReadAllAnnouncementsChannelEventImplCopyWithImpl( + _$ReadAllAnnouncementsChannelEventImpl _value, + $Res Function(_$ReadAllAnnouncementsChannelEventImpl) _then) : super(_value, _then); @pragma('vm:prefer-inline') @@ -8206,7 +9162,7 @@ class __$$ReadAllAnnouncementsImplCopyWithImpl<$Res> $Res call({ Object? id = null, }) { - return _then(_$ReadAllAnnouncementsImpl( + return _then(_$ReadAllAnnouncementsChannelEventImpl( id: null == id ? _value.id : id // ignore: cast_nullable_to_non_nullable @@ -8217,12 +9173,15 @@ class __$$ReadAllAnnouncementsImplCopyWithImpl<$Res> /// @nodoc @JsonSerializable() -class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { - const _$ReadAllAnnouncementsImpl({required this.id, final String? $type}) +class _$ReadAllAnnouncementsChannelEventImpl + implements ReadAllAnnouncementsChannelEvent { + const _$ReadAllAnnouncementsChannelEventImpl( + {required this.id, final String? $type}) : $type = $type ?? 'readAllAnnouncements'; - factory _$ReadAllAnnouncementsImpl.fromJson(Map json) => - _$$ReadAllAnnouncementsImplFromJson(json); + factory _$ReadAllAnnouncementsChannelEventImpl.fromJson( + Map json) => + _$$ReadAllAnnouncementsChannelEventImplFromJson(json); @override final String id; @@ -8239,7 +9198,7 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { bool operator ==(Object other) { return identical(this, other) || (other.runtimeType == runtimeType && - other is _$ReadAllAnnouncementsImpl && + other is _$ReadAllAnnouncementsChannelEventImpl && (identical(other.id, id) || other.id == id)); } @@ -8250,10 +9209,10 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { @JsonKey(ignore: true) @override @pragma('vm:prefer-inline') - _$$ReadAllAnnouncementsImplCopyWith<_$ReadAllAnnouncementsImpl> - get copyWith => - __$$ReadAllAnnouncementsImplCopyWithImpl<_$ReadAllAnnouncementsImpl>( - this, _$identity); + _$$ReadAllAnnouncementsChannelEventImplCopyWith< + _$ReadAllAnnouncementsChannelEventImpl> + get copyWith => __$$ReadAllAnnouncementsChannelEventImplCopyWithImpl< + _$ReadAllAnnouncementsChannelEventImpl>(this, _$identity); @override @optionalTypeArgs @@ -8281,9 +9240,9 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { required TResult Function(String id) readAllNotifications, required TResult Function(String id, INotificationsResponse body) unreadNotification, - required TResult Function(String id, Note body) unreadMention, + required TResult Function(String id, String body) unreadMention, required TResult Function(String id) readAllUnreadMentions, - required TResult Function(String id, Note body) uneradSpecifiedNote, + required TResult Function(String id, String body) unreadSpecifiedNote, required TResult Function(String id) readAllUnreadSpecifiedNotes, required TResult Function(String id, UserLite body) receiveFollowRequest, required TResult Function(String id) readAllAnnouncements, @@ -8315,9 +9274,9 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { TResult? Function(String id)? readAllNotifications, TResult? Function(String id, INotificationsResponse body)? unreadNotification, - TResult? Function(String id, Note body)? unreadMention, + TResult? Function(String id, String body)? unreadMention, TResult? Function(String id)? readAllUnreadMentions, - TResult? Function(String id, Note body)? uneradSpecifiedNote, + TResult? Function(String id, String body)? unreadSpecifiedNote, TResult? Function(String id)? readAllUnreadSpecifiedNotes, TResult? Function(String id, UserLite body)? receiveFollowRequest, TResult? Function(String id)? readAllAnnouncements, @@ -8349,9 +9308,9 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { TResult Function(String id)? readAllNotifications, TResult Function(String id, INotificationsResponse body)? unreadNotification, - TResult Function(String id, Note body)? unreadMention, + TResult Function(String id, String body)? unreadMention, TResult Function(String id)? readAllUnreadMentions, - TResult Function(String id, Note body)? uneradSpecifiedNote, + TResult Function(String id, String body)? unreadSpecifiedNote, TResult Function(String id)? readAllUnreadSpecifiedNotes, TResult Function(String id, UserLite body)? receiveFollowRequest, TResult Function(String id)? readAllAnnouncements, @@ -8387,12 +9346,13 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { required TResult Function(ReadAllUnreadMentionsChannelEvent value) readAllUnreadMentions, required TResult Function(UnreadSpecifiedNoteChannelEvent value) - uneradSpecifiedNote, + unreadSpecifiedNote, required TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value) readAllUnreadSpecifiedNotes, required TResult Function(ReceiveFollowRequestChannelEvent value) receiveFollowRequest, - required TResult Function(ReadAllAnnouncements value) readAllAnnouncements, + required TResult Function(ReadAllAnnouncementsChannelEvent value) + readAllAnnouncements, }) { return readAllAnnouncements(this); } @@ -8420,12 +9380,13 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { TResult? Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult? Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult? Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult? Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult? Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult? Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, }) { return readAllAnnouncements?.call(this); } @@ -8453,12 +9414,13 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { TResult Function(ReadAllUnreadMentionsChannelEvent value)? readAllUnreadMentions, TResult Function(UnreadSpecifiedNoteChannelEvent value)? - uneradSpecifiedNote, + unreadSpecifiedNote, TResult Function(ReadAllUnreadSpecifiedNotesChannelEvent value)? readAllUnreadSpecifiedNotes, TResult Function(ReceiveFollowRequestChannelEvent value)? receiveFollowRequest, - TResult Function(ReadAllAnnouncements value)? readAllAnnouncements, + TResult Function(ReadAllAnnouncementsChannelEvent value)? + readAllAnnouncements, required TResult orElse(), }) { if (readAllAnnouncements != null) { @@ -8469,24 +9431,25 @@ class _$ReadAllAnnouncementsImpl implements ReadAllAnnouncements { @override Map toJson() { - return _$$ReadAllAnnouncementsImplToJson( + return _$$ReadAllAnnouncementsChannelEventImplToJson( this, ); } } -abstract class ReadAllAnnouncements implements ChannelStreamEvent { - const factory ReadAllAnnouncements({required final String id}) = - _$ReadAllAnnouncementsImpl; +abstract class ReadAllAnnouncementsChannelEvent implements ChannelStreamEvent { + const factory ReadAllAnnouncementsChannelEvent({required final String id}) = + _$ReadAllAnnouncementsChannelEventImpl; - factory ReadAllAnnouncements.fromJson(Map json) = - _$ReadAllAnnouncementsImpl.fromJson; + factory ReadAllAnnouncementsChannelEvent.fromJson(Map json) = + _$ReadAllAnnouncementsChannelEventImpl.fromJson; @override String get id; @override @JsonKey(ignore: true) - _$$ReadAllAnnouncementsImplCopyWith<_$ReadAllAnnouncementsImpl> + _$$ReadAllAnnouncementsChannelEventImplCopyWith< + _$ReadAllAnnouncementsChannelEventImpl> get copyWith => throw _privateConstructorUsedError; } @@ -8518,7 +9481,7 @@ mixin _$NoteUpdateStreamEvent { TResult when({ required TResult Function(String id, TimelineReacted body) reacted, required TResult Function(String id, TimelineReacted body) unreacted, - required TResult Function(String id, DateTime body) deleted, + required TResult Function(String id, TimelineDeleted body) deleted, required TResult Function(String id, TimelineVoted body) pollVoted, required TResult Function(String id, NoteEdited body) updated, }) => @@ -8527,7 +9490,7 @@ mixin _$NoteUpdateStreamEvent { TResult? whenOrNull({ TResult? Function(String id, TimelineReacted body)? reacted, TResult? Function(String id, TimelineReacted body)? unreacted, - TResult? Function(String id, DateTime body)? deleted, + TResult? Function(String id, TimelineDeleted body)? deleted, TResult? Function(String id, TimelineVoted body)? pollVoted, TResult? Function(String id, NoteEdited body)? updated, }) => @@ -8536,7 +9499,7 @@ mixin _$NoteUpdateStreamEvent { TResult maybeWhen({ TResult Function(String id, TimelineReacted body)? reacted, TResult Function(String id, TimelineReacted body)? unreacted, - TResult Function(String id, DateTime body)? deleted, + TResult Function(String id, TimelineDeleted body)? deleted, TResult Function(String id, TimelineVoted body)? pollVoted, TResult Function(String id, NoteEdited body)? updated, required TResult orElse(), @@ -8706,7 +9669,7 @@ class _$ReactedChannelEventImpl implements ReactedChannelEvent { TResult when({ required TResult Function(String id, TimelineReacted body) reacted, required TResult Function(String id, TimelineReacted body) unreacted, - required TResult Function(String id, DateTime body) deleted, + required TResult Function(String id, TimelineDeleted body) deleted, required TResult Function(String id, TimelineVoted body) pollVoted, required TResult Function(String id, NoteEdited body) updated, }) { @@ -8718,7 +9681,7 @@ class _$ReactedChannelEventImpl implements ReactedChannelEvent { TResult? whenOrNull({ TResult? Function(String id, TimelineReacted body)? reacted, TResult? Function(String id, TimelineReacted body)? unreacted, - TResult? Function(String id, DateTime body)? deleted, + TResult? Function(String id, TimelineDeleted body)? deleted, TResult? Function(String id, TimelineVoted body)? pollVoted, TResult? Function(String id, NoteEdited body)? updated, }) { @@ -8730,7 +9693,7 @@ class _$ReactedChannelEventImpl implements ReactedChannelEvent { TResult maybeWhen({ TResult Function(String id, TimelineReacted body)? reacted, TResult Function(String id, TimelineReacted body)? unreacted, - TResult Function(String id, DateTime body)? deleted, + TResult Function(String id, TimelineDeleted body)? deleted, TResult Function(String id, TimelineVoted body)? pollVoted, TResult Function(String id, NoteEdited body)? updated, required TResult orElse(), @@ -8905,7 +9868,7 @@ class _$UnreactedChannelEventImpl implements UnreactedChannelEvent { TResult when({ required TResult Function(String id, TimelineReacted body) reacted, required TResult Function(String id, TimelineReacted body) unreacted, - required TResult Function(String id, DateTime body) deleted, + required TResult Function(String id, TimelineDeleted body) deleted, required TResult Function(String id, TimelineVoted body) pollVoted, required TResult Function(String id, NoteEdited body) updated, }) { @@ -8917,7 +9880,7 @@ class _$UnreactedChannelEventImpl implements UnreactedChannelEvent { TResult? whenOrNull({ TResult? Function(String id, TimelineReacted body)? reacted, TResult? Function(String id, TimelineReacted body)? unreacted, - TResult? Function(String id, DateTime body)? deleted, + TResult? Function(String id, TimelineDeleted body)? deleted, TResult? Function(String id, TimelineVoted body)? pollVoted, TResult? Function(String id, NoteEdited body)? updated, }) { @@ -8929,7 +9892,7 @@ class _$UnreactedChannelEventImpl implements UnreactedChannelEvent { TResult maybeWhen({ TResult Function(String id, TimelineReacted body)? reacted, TResult Function(String id, TimelineReacted body)? unreacted, - TResult Function(String id, DateTime body)? deleted, + TResult Function(String id, TimelineDeleted body)? deleted, TResult Function(String id, TimelineVoted body)? pollVoted, TResult Function(String id, NoteEdited body)? updated, required TResult orElse(), @@ -9014,7 +9977,9 @@ abstract class _$$DeletedChannelEventImplCopyWith<$Res> __$$DeletedChannelEventImplCopyWithImpl<$Res>; @override @useResult - $Res call({String id, DateTime body}); + $Res call({String id, TimelineDeleted body}); + + $TimelineDeletedCopyWith<$Res> get body; } /// @nodoc @@ -9039,9 +10004,17 @@ class __$$DeletedChannelEventImplCopyWithImpl<$Res> body: null == body ? _value.body : body // ignore: cast_nullable_to_non_nullable - as DateTime, + as TimelineDeleted, )); } + + @override + @pragma('vm:prefer-inline') + $TimelineDeletedCopyWith<$Res> get body { + return $TimelineDeletedCopyWith<$Res>(_value.body, (value) { + return _then(_value.copyWith(body: value)); + }); + } } /// @nodoc @@ -9057,7 +10030,7 @@ class _$DeletedChannelEventImpl implements DeletedChannelEvent { @override final String id; @override - final DateTime body; + final TimelineDeleted body; @JsonKey(name: 'type') final String $type; @@ -9092,7 +10065,7 @@ class _$DeletedChannelEventImpl implements DeletedChannelEvent { TResult when({ required TResult Function(String id, TimelineReacted body) reacted, required TResult Function(String id, TimelineReacted body) unreacted, - required TResult Function(String id, DateTime body) deleted, + required TResult Function(String id, TimelineDeleted body) deleted, required TResult Function(String id, TimelineVoted body) pollVoted, required TResult Function(String id, NoteEdited body) updated, }) { @@ -9104,7 +10077,7 @@ class _$DeletedChannelEventImpl implements DeletedChannelEvent { TResult? whenOrNull({ TResult? Function(String id, TimelineReacted body)? reacted, TResult? Function(String id, TimelineReacted body)? unreacted, - TResult? Function(String id, DateTime body)? deleted, + TResult? Function(String id, TimelineDeleted body)? deleted, TResult? Function(String id, TimelineVoted body)? pollVoted, TResult? Function(String id, NoteEdited body)? updated, }) { @@ -9116,7 +10089,7 @@ class _$DeletedChannelEventImpl implements DeletedChannelEvent { TResult maybeWhen({ TResult Function(String id, TimelineReacted body)? reacted, TResult Function(String id, TimelineReacted body)? unreacted, - TResult Function(String id, DateTime body)? deleted, + TResult Function(String id, TimelineDeleted body)? deleted, TResult Function(String id, TimelineVoted body)? pollVoted, TResult Function(String id, NoteEdited body)? updated, required TResult orElse(), @@ -9178,7 +10151,7 @@ class _$DeletedChannelEventImpl implements DeletedChannelEvent { abstract class DeletedChannelEvent implements NoteUpdateStreamEvent { const factory DeletedChannelEvent( {required final String id, - required final DateTime body}) = _$DeletedChannelEventImpl; + required final TimelineDeleted body}) = _$DeletedChannelEventImpl; factory DeletedChannelEvent.fromJson(Map json) = _$DeletedChannelEventImpl.fromJson; @@ -9186,7 +10159,7 @@ abstract class DeletedChannelEvent implements NoteUpdateStreamEvent { @override String get id; @override - DateTime get body; + TimelineDeleted get body; @override @JsonKey(ignore: true) _$$DeletedChannelEventImplCopyWith<_$DeletedChannelEventImpl> get copyWith => @@ -9291,7 +10264,7 @@ class _$PollVotedChannelEventImpl implements PollVotedChannelEvent { TResult when({ required TResult Function(String id, TimelineReacted body) reacted, required TResult Function(String id, TimelineReacted body) unreacted, - required TResult Function(String id, DateTime body) deleted, + required TResult Function(String id, TimelineDeleted body) deleted, required TResult Function(String id, TimelineVoted body) pollVoted, required TResult Function(String id, NoteEdited body) updated, }) { @@ -9303,7 +10276,7 @@ class _$PollVotedChannelEventImpl implements PollVotedChannelEvent { TResult? whenOrNull({ TResult? Function(String id, TimelineReacted body)? reacted, TResult? Function(String id, TimelineReacted body)? unreacted, - TResult? Function(String id, DateTime body)? deleted, + TResult? Function(String id, TimelineDeleted body)? deleted, TResult? Function(String id, TimelineVoted body)? pollVoted, TResult? Function(String id, NoteEdited body)? updated, }) { @@ -9315,7 +10288,7 @@ class _$PollVotedChannelEventImpl implements PollVotedChannelEvent { TResult maybeWhen({ TResult Function(String id, TimelineReacted body)? reacted, TResult Function(String id, TimelineReacted body)? unreacted, - TResult Function(String id, DateTime body)? deleted, + TResult Function(String id, TimelineDeleted body)? deleted, TResult Function(String id, TimelineVoted body)? pollVoted, TResult Function(String id, NoteEdited body)? updated, required TResult orElse(), @@ -9488,7 +10461,7 @@ class _$UpdatedChannelEventImpl implements UpdatedChannelEvent { TResult when({ required TResult Function(String id, TimelineReacted body) reacted, required TResult Function(String id, TimelineReacted body) unreacted, - required TResult Function(String id, DateTime body) deleted, + required TResult Function(String id, TimelineDeleted body) deleted, required TResult Function(String id, TimelineVoted body) pollVoted, required TResult Function(String id, NoteEdited body) updated, }) { @@ -9500,7 +10473,7 @@ class _$UpdatedChannelEventImpl implements UpdatedChannelEvent { TResult? whenOrNull({ TResult? Function(String id, TimelineReacted body)? reacted, TResult? Function(String id, TimelineReacted body)? unreacted, - TResult? Function(String id, DateTime body)? deleted, + TResult? Function(String id, TimelineDeleted body)? deleted, TResult? Function(String id, TimelineVoted body)? pollVoted, TResult? Function(String id, NoteEdited body)? updated, }) { @@ -9512,7 +10485,7 @@ class _$UpdatedChannelEventImpl implements UpdatedChannelEvent { TResult maybeWhen({ TResult Function(String id, TimelineReacted body)? reacted, TResult Function(String id, TimelineReacted body)? unreacted, - TResult Function(String id, DateTime body)? deleted, + TResult Function(String id, TimelineDeleted body)? deleted, TResult Function(String id, TimelineVoted body)? pollVoted, TResult Function(String id, NoteEdited body)? updated, required TResult orElse(), @@ -9588,281 +10561,3 @@ abstract class UpdatedChannelEvent implements NoteUpdateStreamEvent { _$$UpdatedChannelEventImplCopyWith<_$UpdatedChannelEventImpl> get copyWith => throw _privateConstructorUsedError; } - -BroadcastStreamEvent _$BroadcastStreamEventFromJson(Map json) { - return BroadcastChannelEvent.fromJson(json); -} - -/// @nodoc -mixin _$BroadcastStreamEvent { - @BroadcastEventTypeJsonConverter() - BroadcastEventType get type => throw _privateConstructorUsedError; - Map get body => throw _privateConstructorUsedError; - @optionalTypeArgs - TResult when({ - required TResult Function( - @BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body) - broadcast, - }) => - throw _privateConstructorUsedError; - @optionalTypeArgs - TResult? whenOrNull({ - TResult? Function( - @BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body)? - broadcast, - }) => - throw _privateConstructorUsedError; - @optionalTypeArgs - TResult maybeWhen({ - TResult Function(@BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body)? - broadcast, - required TResult orElse(), - }) => - throw _privateConstructorUsedError; - @optionalTypeArgs - TResult map({ - required TResult Function(BroadcastChannelEvent value) broadcast, - }) => - throw _privateConstructorUsedError; - @optionalTypeArgs - TResult? mapOrNull({ - TResult? Function(BroadcastChannelEvent value)? broadcast, - }) => - throw _privateConstructorUsedError; - @optionalTypeArgs - TResult maybeMap({ - TResult Function(BroadcastChannelEvent value)? broadcast, - required TResult orElse(), - }) => - throw _privateConstructorUsedError; - Map toJson() => throw _privateConstructorUsedError; - @JsonKey(ignore: true) - $BroadcastStreamEventCopyWith get copyWith => - throw _privateConstructorUsedError; -} - -/// @nodoc -abstract class $BroadcastStreamEventCopyWith<$Res> { - factory $BroadcastStreamEventCopyWith(BroadcastStreamEvent value, - $Res Function(BroadcastStreamEvent) then) = - _$BroadcastStreamEventCopyWithImpl<$Res, BroadcastStreamEvent>; - @useResult - $Res call( - {@BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body}); -} - -/// @nodoc -class _$BroadcastStreamEventCopyWithImpl<$Res, - $Val extends BroadcastStreamEvent> - implements $BroadcastStreamEventCopyWith<$Res> { - _$BroadcastStreamEventCopyWithImpl(this._value, this._then); - - // ignore: unused_field - final $Val _value; - // ignore: unused_field - final $Res Function($Val) _then; - - @pragma('vm:prefer-inline') - @override - $Res call({ - Object? type = null, - Object? body = null, - }) { - return _then(_value.copyWith( - type: null == type - ? _value.type - : type // ignore: cast_nullable_to_non_nullable - as BroadcastEventType, - body: null == body - ? _value.body - : body // ignore: cast_nullable_to_non_nullable - as Map, - ) as $Val); - } -} - -/// @nodoc -abstract class _$$BroadcastChannelEventImplCopyWith<$Res> - implements $BroadcastStreamEventCopyWith<$Res> { - factory _$$BroadcastChannelEventImplCopyWith( - _$BroadcastChannelEventImpl value, - $Res Function(_$BroadcastChannelEventImpl) then) = - __$$BroadcastChannelEventImplCopyWithImpl<$Res>; - @override - @useResult - $Res call( - {@BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body}); -} - -/// @nodoc -class __$$BroadcastChannelEventImplCopyWithImpl<$Res> - extends _$BroadcastStreamEventCopyWithImpl<$Res, - _$BroadcastChannelEventImpl> - implements _$$BroadcastChannelEventImplCopyWith<$Res> { - __$$BroadcastChannelEventImplCopyWithImpl(_$BroadcastChannelEventImpl _value, - $Res Function(_$BroadcastChannelEventImpl) _then) - : super(_value, _then); - - @pragma('vm:prefer-inline') - @override - $Res call({ - Object? type = null, - Object? body = null, - }) { - return _then(_$BroadcastChannelEventImpl( - type: null == type - ? _value.type - : type // ignore: cast_nullable_to_non_nullable - as BroadcastEventType, - body: null == body - ? _value._body - : body // ignore: cast_nullable_to_non_nullable - as Map, - )); - } -} - -/// @nodoc -@JsonSerializable() -class _$BroadcastChannelEventImpl implements BroadcastChannelEvent { - const _$BroadcastChannelEventImpl( - {@BroadcastEventTypeJsonConverter() required this.type, - required final Map body}) - : _body = body; - - factory _$BroadcastChannelEventImpl.fromJson(Map json) => - _$$BroadcastChannelEventImplFromJson(json); - - @override - @BroadcastEventTypeJsonConverter() - final BroadcastEventType type; - final Map _body; - @override - Map get body { - if (_body is EqualUnmodifiableMapView) return _body; - // ignore: implicit_dynamic_type - return EqualUnmodifiableMapView(_body); - } - - @override - String toString() { - return 'BroadcastStreamEvent.broadcast(type: $type, body: $body)'; - } - - @override - bool operator ==(Object other) { - return identical(this, other) || - (other.runtimeType == runtimeType && - other is _$BroadcastChannelEventImpl && - (identical(other.type, type) || other.type == type) && - const DeepCollectionEquality().equals(other._body, _body)); - } - - @JsonKey(ignore: true) - @override - int get hashCode => Object.hash( - runtimeType, type, const DeepCollectionEquality().hash(_body)); - - @JsonKey(ignore: true) - @override - @pragma('vm:prefer-inline') - _$$BroadcastChannelEventImplCopyWith<_$BroadcastChannelEventImpl> - get copyWith => __$$BroadcastChannelEventImplCopyWithImpl< - _$BroadcastChannelEventImpl>(this, _$identity); - - @override - @optionalTypeArgs - TResult when({ - required TResult Function( - @BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body) - broadcast, - }) { - return broadcast(type, body); - } - - @override - @optionalTypeArgs - TResult? whenOrNull({ - TResult? Function( - @BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body)? - broadcast, - }) { - return broadcast?.call(type, body); - } - - @override - @optionalTypeArgs - TResult maybeWhen({ - TResult Function(@BroadcastEventTypeJsonConverter() BroadcastEventType type, - Map body)? - broadcast, - required TResult orElse(), - }) { - if (broadcast != null) { - return broadcast(type, body); - } - return orElse(); - } - - @override - @optionalTypeArgs - TResult map({ - required TResult Function(BroadcastChannelEvent value) broadcast, - }) { - return broadcast(this); - } - - @override - @optionalTypeArgs - TResult? mapOrNull({ - TResult? Function(BroadcastChannelEvent value)? broadcast, - }) { - return broadcast?.call(this); - } - - @override - @optionalTypeArgs - TResult maybeMap({ - TResult Function(BroadcastChannelEvent value)? broadcast, - required TResult orElse(), - }) { - if (broadcast != null) { - return broadcast(this); - } - return orElse(); - } - - @override - Map toJson() { - return _$$BroadcastChannelEventImplToJson( - this, - ); - } -} - -abstract class BroadcastChannelEvent implements BroadcastStreamEvent { - const factory BroadcastChannelEvent( - {@BroadcastEventTypeJsonConverter() - required final BroadcastEventType type, - required final Map body}) = _$BroadcastChannelEventImpl; - - factory BroadcastChannelEvent.fromJson(Map json) = - _$BroadcastChannelEventImpl.fromJson; - - @override - @BroadcastEventTypeJsonConverter() - BroadcastEventType get type; - @override - Map get body; - @override - @JsonKey(ignore: true) - _$$BroadcastChannelEventImplCopyWith<_$BroadcastChannelEventImpl> - get copyWith => throw _privateConstructorUsedError; -} diff --git a/lib/src/data/streaming/streaming_response.g.dart b/lib/src/data/streaming/streaming_response.g.dart index ef46c13b..31308892 100644 --- a/lib/src/data/streaming/streaming_response.g.dart +++ b/lib/src/data/streaming/streaming_response.g.dart @@ -40,7 +40,7 @@ _$StreamingChannelEmojiAddedResponseImpl _$$StreamingChannelEmojiAddedResponseImplFromJson( Map json) => _$StreamingChannelEmojiAddedResponseImpl( - body: BroadcastStreamEvent.fromJson( + body: EmojiAddedStreamEvent.fromJson( json['body'] as Map), $type: json['type'] as String?, ); @@ -56,7 +56,7 @@ _$StreamingChannelEmojiUpdatedResponseImpl _$$StreamingChannelEmojiUpdatedResponseImplFromJson( Map json) => _$StreamingChannelEmojiUpdatedResponseImpl( - body: BroadcastStreamEvent.fromJson( + body: EmojiUpdatedStreamEvent.fromJson( json['body'] as Map), $type: json['type'] as String?, ); @@ -72,7 +72,7 @@ _$StreamingChannelEmojiDeletedResponseImpl _$$StreamingChannelEmojiDeletedResponseImplFromJson( Map json) => _$StreamingChannelEmojiDeletedResponseImpl( - body: BroadcastStreamEvent.fromJson( + body: EmojiDeletedStreamEvent.fromJson( json['body'] as Map), $type: json['type'] as String?, ); @@ -84,6 +84,22 @@ Map _$$StreamingChannelEmojiDeletedResponseImplToJson( 'type': instance.$type, }; +_$StreamingChannelAnnouncementCreatedResponseImpl + _$$StreamingChannelAnnouncementCreatedResponseImplFromJson( + Map json) => + _$StreamingChannelAnnouncementCreatedResponseImpl( + body: AnnouncementCreatedStreamEvent.fromJson( + json['body'] as Map), + $type: json['type'] as String?, + ); + +Map _$$StreamingChannelAnnouncementCreatedResponseImplToJson( + _$StreamingChannelAnnouncementCreatedResponseImpl instance) => + { + 'body': instance.body.toJson(), + 'type': instance.$type, + }; + _$StreamingChannelUnknownResponseImpl _$$StreamingChannelUnknownResponseImplFromJson(Map json) => _$StreamingChannelUnknownResponseImpl( @@ -98,6 +114,59 @@ Map _$$StreamingChannelUnknownResponseImplToJson( 'type': instance.$type, }; +_$EmojiAddedStreamEventImpl _$$EmojiAddedStreamEventImplFromJson( + Map json) => + _$EmojiAddedStreamEventImpl( + emoji: Emoji.fromJson(json['emoji'] as Map), + ); + +Map _$$EmojiAddedStreamEventImplToJson( + _$EmojiAddedStreamEventImpl instance) => + { + 'emoji': instance.emoji.toJson(), + }; + +_$EmojiUpdatedStreamEventImpl _$$EmojiUpdatedStreamEventImplFromJson( + Map json) => + _$EmojiUpdatedStreamEventImpl( + emojis: (json['emojis'] as List) + .map((e) => Emoji.fromJson(e as Map)) + .toList(), + ); + +Map _$$EmojiUpdatedStreamEventImplToJson( + _$EmojiUpdatedStreamEventImpl instance) => + { + 'emojis': instance.emojis.map((e) => e.toJson()).toList(), + }; + +_$EmojiDeletedStreamEventImpl _$$EmojiDeletedStreamEventImplFromJson( + Map json) => + _$EmojiDeletedStreamEventImpl( + emojis: (json['emojis'] as List) + .map((e) => Emoji.fromJson(e as Map)) + .toList(), + ); + +Map _$$EmojiDeletedStreamEventImplToJson( + _$EmojiDeletedStreamEventImpl instance) => + { + 'emojis': instance.emojis.map((e) => e.toJson()).toList(), + }; + +_$AnnouncementCreatedStreamEventImpl + _$$AnnouncementCreatedStreamEventImplFromJson(Map json) => + _$AnnouncementCreatedStreamEventImpl( + announcement: AnnouncementsResponse.fromJson( + json['announcement'] as Map), + ); + +Map _$$AnnouncementCreatedStreamEventImplToJson( + _$AnnouncementCreatedStreamEventImpl instance) => + { + 'announcement': instance.announcement.toJson(), + }; + _$NoteChannelEventImpl _$$NoteChannelEventImplFromJson( Map json) => _$NoteChannelEventImpl( @@ -381,7 +450,7 @@ _$UnreadMentionChannelEventImpl _$$UnreadMentionChannelEventImplFromJson( Map json) => _$UnreadMentionChannelEventImpl( id: json['id'] as String, - body: Note.fromJson(json['body'] as Map), + body: json['body'] as String, $type: json['type'] as String?, ); @@ -389,7 +458,7 @@ Map _$$UnreadMentionChannelEventImplToJson( _$UnreadMentionChannelEventImpl instance) => { 'id': instance.id, - 'body': instance.body.toJson(), + 'body': instance.body, 'type': instance.$type, }; @@ -412,7 +481,7 @@ _$UnreadSpecifiedNoteChannelEventImpl _$$UnreadSpecifiedNoteChannelEventImplFromJson(Map json) => _$UnreadSpecifiedNoteChannelEventImpl( id: json['id'] as String, - body: Note.fromJson(json['body'] as Map), + body: json['body'] as String, $type: json['type'] as String?, ); @@ -420,7 +489,7 @@ Map _$$UnreadSpecifiedNoteChannelEventImplToJson( _$UnreadSpecifiedNoteChannelEventImpl instance) => { 'id': instance.id, - 'body': instance.body.toJson(), + 'body': instance.body, 'type': instance.$type, }; @@ -456,15 +525,16 @@ Map _$$ReceiveFollowRequestChannelEventImplToJson( 'type': instance.$type, }; -_$ReadAllAnnouncementsImpl _$$ReadAllAnnouncementsImplFromJson( - Map json) => - _$ReadAllAnnouncementsImpl( - id: json['id'] as String, - $type: json['type'] as String?, - ); +_$ReadAllAnnouncementsChannelEventImpl + _$$ReadAllAnnouncementsChannelEventImplFromJson( + Map json) => + _$ReadAllAnnouncementsChannelEventImpl( + id: json['id'] as String, + $type: json['type'] as String?, + ); -Map _$$ReadAllAnnouncementsImplToJson( - _$ReadAllAnnouncementsImpl instance) => +Map _$$ReadAllAnnouncementsChannelEventImplToJson( + _$ReadAllAnnouncementsChannelEventImpl instance) => { 'id': instance.id, 'type': instance.$type, @@ -506,7 +576,7 @@ _$DeletedChannelEventImpl _$$DeletedChannelEventImplFromJson( Map json) => _$DeletedChannelEventImpl( id: json['id'] as String, - body: DateTime.parse(json['body'] as String), + body: TimelineDeleted.fromJson(json['body'] as Map), $type: json['type'] as String?, ); @@ -514,7 +584,7 @@ Map _$$DeletedChannelEventImplToJson( _$DeletedChannelEventImpl instance) => { 'id': instance.id, - 'body': instance.body.toIso8601String(), + 'body': instance.body.toJson(), 'type': instance.$type, }; @@ -549,24 +619,3 @@ Map _$$UpdatedChannelEventImplToJson( 'body': instance.body.toJson(), 'type': instance.$type, }; - -_$BroadcastChannelEventImpl _$$BroadcastChannelEventImplFromJson( - Map json) => - _$BroadcastChannelEventImpl( - type: $enumDecode(_$BroadcastEventTypeEnumMap, json['type']), - body: json['body'] as Map, - ); - -Map _$$BroadcastChannelEventImplToJson( - _$BroadcastChannelEventImpl instance) => - { - 'type': _$BroadcastEventTypeEnumMap[instance.type]!, - 'body': instance.body, - }; - -const _$BroadcastEventTypeEnumMap = { - BroadcastEventType.emojiAdded: 'emojiAdded', - BroadcastEventType.emojiUpdated: 'emojiUpdated', - BroadcastEventType.emojiDeleted: 'emojiDeleted', - BroadcastEventType.announcementCreated: 'announcementCreated', -}; diff --git a/lib/src/data/streaming/timeline_deleted.dart b/lib/src/data/streaming/timeline_deleted.dart new file mode 100644 index 00000000..94e237d0 --- /dev/null +++ b/lib/src/data/streaming/timeline_deleted.dart @@ -0,0 +1,15 @@ +import 'package:freezed_annotation/freezed_annotation.dart'; +import 'package:misskey_dart/src/converters/date_time_converter.dart'; + +part 'timeline_deleted.freezed.dart'; +part 'timeline_deleted.g.dart'; + +@freezed +class TimelineDeleted with _$TimelineDeleted { + const factory TimelineDeleted({ + @DateTimeConverter() required DateTime deletedAt, + }) = _TimelineDeleted; + + factory TimelineDeleted.fromJson(Map json) => + _$TimelineDeletedFromJson(json); +} diff --git a/lib/src/data/streaming/timeline_deleted.freezed.dart b/lib/src/data/streaming/timeline_deleted.freezed.dart new file mode 100644 index 00000000..3806ee7f --- /dev/null +++ b/lib/src/data/streaming/timeline_deleted.freezed.dart @@ -0,0 +1,158 @@ +// coverage:ignore-file +// GENERATED CODE - DO NOT MODIFY BY HAND +// ignore_for_file: type=lint +// 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 + +part of 'timeline_deleted.dart'; + +// ************************************************************************** +// FreezedGenerator +// ************************************************************************** + +T _$identity(T value) => value; + +final _privateConstructorUsedError = UnsupportedError( + '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#custom-getters-and-methods'); + +TimelineDeleted _$TimelineDeletedFromJson(Map json) { + return _TimelineDeleted.fromJson(json); +} + +/// @nodoc +mixin _$TimelineDeleted { + @DateTimeConverter() + DateTime get deletedAt => throw _privateConstructorUsedError; + + Map toJson() => throw _privateConstructorUsedError; + @JsonKey(ignore: true) + $TimelineDeletedCopyWith get copyWith => + throw _privateConstructorUsedError; +} + +/// @nodoc +abstract class $TimelineDeletedCopyWith<$Res> { + factory $TimelineDeletedCopyWith( + TimelineDeleted value, $Res Function(TimelineDeleted) then) = + _$TimelineDeletedCopyWithImpl<$Res, TimelineDeleted>; + @useResult + $Res call({@DateTimeConverter() DateTime deletedAt}); +} + +/// @nodoc +class _$TimelineDeletedCopyWithImpl<$Res, $Val extends TimelineDeleted> + implements $TimelineDeletedCopyWith<$Res> { + _$TimelineDeletedCopyWithImpl(this._value, this._then); + + // ignore: unused_field + final $Val _value; + // ignore: unused_field + final $Res Function($Val) _then; + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? deletedAt = null, + }) { + return _then(_value.copyWith( + deletedAt: null == deletedAt + ? _value.deletedAt + : deletedAt // ignore: cast_nullable_to_non_nullable + as DateTime, + ) as $Val); + } +} + +/// @nodoc +abstract class _$$TimelineDeletedImplCopyWith<$Res> + implements $TimelineDeletedCopyWith<$Res> { + factory _$$TimelineDeletedImplCopyWith(_$TimelineDeletedImpl value, + $Res Function(_$TimelineDeletedImpl) then) = + __$$TimelineDeletedImplCopyWithImpl<$Res>; + @override + @useResult + $Res call({@DateTimeConverter() DateTime deletedAt}); +} + +/// @nodoc +class __$$TimelineDeletedImplCopyWithImpl<$Res> + extends _$TimelineDeletedCopyWithImpl<$Res, _$TimelineDeletedImpl> + implements _$$TimelineDeletedImplCopyWith<$Res> { + __$$TimelineDeletedImplCopyWithImpl( + _$TimelineDeletedImpl _value, $Res Function(_$TimelineDeletedImpl) _then) + : super(_value, _then); + + @pragma('vm:prefer-inline') + @override + $Res call({ + Object? deletedAt = null, + }) { + return _then(_$TimelineDeletedImpl( + deletedAt: null == deletedAt + ? _value.deletedAt + : deletedAt // ignore: cast_nullable_to_non_nullable + as DateTime, + )); + } +} + +/// @nodoc +@JsonSerializable() +class _$TimelineDeletedImpl implements _TimelineDeleted { + const _$TimelineDeletedImpl({@DateTimeConverter() required this.deletedAt}); + + factory _$TimelineDeletedImpl.fromJson(Map json) => + _$$TimelineDeletedImplFromJson(json); + + @override + @DateTimeConverter() + final DateTime deletedAt; + + @override + String toString() { + return 'TimelineDeleted(deletedAt: $deletedAt)'; + } + + @override + bool operator ==(Object other) { + return identical(this, other) || + (other.runtimeType == runtimeType && + other is _$TimelineDeletedImpl && + (identical(other.deletedAt, deletedAt) || + other.deletedAt == deletedAt)); + } + + @JsonKey(ignore: true) + @override + int get hashCode => Object.hash(runtimeType, deletedAt); + + @JsonKey(ignore: true) + @override + @pragma('vm:prefer-inline') + _$$TimelineDeletedImplCopyWith<_$TimelineDeletedImpl> get copyWith => + __$$TimelineDeletedImplCopyWithImpl<_$TimelineDeletedImpl>( + this, _$identity); + + @override + Map toJson() { + return _$$TimelineDeletedImplToJson( + this, + ); + } +} + +abstract class _TimelineDeleted implements TimelineDeleted { + const factory _TimelineDeleted( + {@DateTimeConverter() required final DateTime deletedAt}) = + _$TimelineDeletedImpl; + + factory _TimelineDeleted.fromJson(Map json) = + _$TimelineDeletedImpl.fromJson; + + @override + @DateTimeConverter() + DateTime get deletedAt; + @override + @JsonKey(ignore: true) + _$$TimelineDeletedImplCopyWith<_$TimelineDeletedImpl> get copyWith => + throw _privateConstructorUsedError; +} diff --git a/lib/src/data/streaming/timeline_deleted.g.dart b/lib/src/data/streaming/timeline_deleted.g.dart new file mode 100644 index 00000000..f44f7557 --- /dev/null +++ b/lib/src/data/streaming/timeline_deleted.g.dart @@ -0,0 +1,20 @@ +// GENERATED CODE - DO NOT MODIFY BY HAND + +part of 'timeline_deleted.dart'; + +// ************************************************************************** +// JsonSerializableGenerator +// ************************************************************************** + +_$TimelineDeletedImpl _$$TimelineDeletedImplFromJson( + Map json) => + _$TimelineDeletedImpl( + deletedAt: + const DateTimeConverter().fromJson(json['deletedAt'] as String), + ); + +Map _$$TimelineDeletedImplToJson( + _$TimelineDeletedImpl instance) => + { + 'deletedAt': const DateTimeConverter().toJson(instance.deletedAt), + }; diff --git a/lib/src/misskey_dart_base.dart b/lib/src/misskey_dart_base.dart index 6dc3ab2a..ec73ffa8 100644 --- a/lib/src/misskey_dart_base.dart +++ b/lib/src/misskey_dart_base.dart @@ -2,10 +2,10 @@ import 'dart:async'; import 'package:misskey_dart/misskey_dart.dart'; import 'package:misskey_dart/src/data/ping_response.dart'; -import 'package:misskey_dart/src/data/stats_response.dart'; import 'package:misskey_dart/src/misskey_flash.dart'; import 'package:misskey_dart/src/services/api_service.dart'; import 'package:misskey_dart/src/services/streaming_service.dart'; +import 'package:misskey_dart/src/services/streaming_service_impl.dart'; class Misskey { final String? token; diff --git a/lib/src/misskey_reversi.dart b/lib/src/misskey_reversi.dart index ea95e26d..f5171283 100644 --- a/lib/src/misskey_reversi.dart +++ b/lib/src/misskey_reversi.dart @@ -1,7 +1,4 @@ import 'package:misskey_dart/misskey_dart.dart'; -import 'package:misskey_dart/src/data/reversi/reversi_games_request.dart'; -import 'package:misskey_dart/src/data/reversi/reversi_games_response.dart'; -import 'package:misskey_dart/src/data/reversi/reversi_show_game_response.dart'; import 'package:misskey_dart/src/services/api_service.dart'; class MisskeyReversi { diff --git a/lib/src/misskey_users.dart b/lib/src/misskey_users.dart index b296dcf1..67c464ae 100644 --- a/lib/src/misskey_users.dart +++ b/lib/src/misskey_users.dart @@ -1,6 +1,4 @@ import 'package:misskey_dart/misskey_dart.dart'; -import 'package:misskey_dart/src/data/users/users_get_frequently_replied_users_request.dart'; -import 'package:misskey_dart/src/data/users/users_get_frequently_replied_users_response.dart'; import 'package:misskey_dart/src/services/api_service.dart'; class MisskeyUsers { diff --git a/lib/src/services/streaming_service_impl.dart b/lib/src/services/streaming_service_impl.dart index 2c851017..b24d1507 100644 --- a/lib/src/services/streaming_service_impl.dart +++ b/lib/src/services/streaming_service_impl.dart @@ -36,13 +36,13 @@ class StreamingService implements StreamingController, WebSocketController { StreamSubscription? _subscription; WebSocketChannel _createWebSocketChannel() { - log( - "connect websocket wss://$host/streaming${token != null ? "?i=$token" : ""}", - ); + final url = + "${streamingUrl ?? "wss://$host${port == 80 ? "" : ":$port"}/streaming"}${token != null ? "?i=$token" : ""}"; + + log("connect websocket $url"); return IOWebSocketChannel.connect( - streamingUrl ?? - "wss://$host/streaming${token != null ? "?i=$token" : ""}", + url, pingInterval: const Duration(minutes: 1), connectTimeout: connectionTimeout, ); @@ -164,12 +164,15 @@ class StreamingService implements StreamingController, WebSocketController { _connections.add(body); return _controller.stream.where((e) { + if (e is StreamingChannelUnknownResponse) { + print("$e is unknown type response"); + } + return switch (e) { StreamingChannelResponse(:final body) => body.id == id, - StreamingChannelNoteUpdatedResponse(:final body) => body.id == id, - _ => false, + _ => true, }; - }).cast(); + }); } @override @@ -246,7 +249,7 @@ class StreamingService implements StreamingController, WebSocketController { String? id, }) => addChannel( - Channel.roleTimeline, + Channel.channel, {"channelId": channelId}, id ?? channelId, ); @@ -256,7 +259,7 @@ class StreamingService implements StreamingController, WebSocketController { required String listId, String? id, }) => - addChannel(Channel.roleTimeline, {"listId": listId}, id ?? listId); + addChannel(Channel.userList, {"listId": listId}, id ?? listId); @override Stream antennaStream({ @@ -264,7 +267,7 @@ class StreamingService implements StreamingController, WebSocketController { String? id, }) => addChannel( - Channel.roleTimeline, + Channel.antenna, {"antennaId": antennaId}, id ?? antennaId, ); diff --git a/test/misskey_dart_base_test.dart b/test/misskey_dart_base_test.dart index 0aea4c81..09fb0895 100644 --- a/test/misskey_dart_base_test.dart +++ b/test/misskey_dart_base_test.dart @@ -1,14 +1,9 @@ -import 'dart:async'; - import 'package:misskey_dart/misskey_dart.dart'; import 'package:test/test.dart'; -import 'package:uuid/uuid.dart'; import 'util/misskey_dart_test_util.dart'; void main() async { - final user = await userClient.i.i(); - group("misc", () { test("announcements", () async { final response = await userClient.announcements(AnnouncementsRequest()); diff --git a/test/streaming_test.dart b/test/streaming_test.dart index 562c27f2..1e8e58dc 100644 --- a/test/streaming_test.dart +++ b/test/streaming_test.dart @@ -2,6 +2,7 @@ import 'dart:async'; import 'package:misskey_dart/misskey_dart.dart'; import 'package:test/test.dart'; +import 'package:uuid/uuid.dart'; import 'util/misskey_dart_test_util.dart'; @@ -205,18 +206,18 @@ void main() async { }); group( - "serverStats", + "queueStats", () { test("statsLog", () async { - final completer = Completer>(); + final completer = Completer>(); final client = userClient; final controller = await client.streamingService.stream(); final id = DateTime.now().toIso8601String(); final listener = - controller.serverStatsLogStream(id: id).listen((event) { + controller.queueStatsLogStream(id: id).listen((event) { final body = event.body; if (body is StatsLogChannelEvent) { - completer.complete(body.body.cast()); + completer.complete(body.body.cast()); } }); controller.requestLog(id, 50); @@ -225,15 +226,15 @@ void main() async { }); test("stats", () async { - final completer = Completer(); + final completer = Completer(); final client = userClient; final controller = await client.streamingService.stream(); final id = DateTime.now().toIso8601String(); final listener = - controller.serverStatsLogStream(id: id).listen((event) { + controller.queueStatsLogStream(id: id).listen((event) { final body = event.body; if (body is StatsChannelEvent) { - completer.complete(body.body as ServerMetricsResponse); + completer.complete(body.body as JobQueueResponse); } }); await completer.future; @@ -377,7 +378,7 @@ void main() async { final id = DateTime.now().toIso8601String(); final listener = controller.mainStream(id: id).listen((event) { final body = event.body; - if (body is ReadAllAnnouncements) completer.complete(); + if (body is ReadAllNotificationsChannelEvent) completer.complete(); }); await client.apiService.post("notifications/mark-all-as-read", {}); await completer.future; @@ -399,7 +400,7 @@ void main() async { }); test("unreadMention", () async { - final completer = Completer(); + final completer = Completer(); final client = userClient; final controller = await client.streamingService.stream(); final id = DateTime.now().toIso8601String(); @@ -433,7 +434,7 @@ void main() async { }); test("unreadSpecifiedNote", () async { - final completer = Completer(); + final completer = Completer(); final client = userClient; final controller = await client.streamingService.stream(); @@ -507,7 +508,7 @@ void main() async { final id = DateTime.now().toIso8601String(); final listener = controller.mainStream(id: id).listen((event) { final body = event.body; - if (body is ReadAllAnnouncements) completer.complete(); + if (body is ReadAllAnnouncementsChannelEvent) completer.complete(); }); await Future.wait( announcements.map((announcement) { @@ -575,7 +576,7 @@ void main() async { }); test("deleted", () async { - final completer = Completer(); + final completer = Completer(); final client = userClient; final note = await client.createNote(); final controller = await client.streamingService.stream(); @@ -584,9 +585,7 @@ void main() async { .homeTimelineStream(id: id, parameter: HomeTimelineParameter()) .listen((event) { final body = event.body; - if (body is DeletedChannelEvent) { - completer.complete(body.body); - } + if (body is DeletedChannelEvent) completer.complete(body.body); }); controller.subNote(note.id); await client.notes.delete(NotesDeleteRequest(noteId: note.id)); @@ -622,70 +621,95 @@ void main() async { }); }); - // group("broadcast", () { - // test("emojiCreated", () async { - // final completer = Completer(); - // final client = userClient; - // final name = Uuid().v4().replaceAll("-", "_"); - // final file = await adminClient.createDriveFile(); - // final controller = client.mainStream(onEmojiAdded: completer.complete); - // await client.startStreaming(); - // await adminClient.apiService - // .post("admin/emoji/add", {"name": name, "fileId": file.id}); - // await completer.future; - // controller.disconnect(); - // }); - - // test("emojiUpdated", () async { - // final completer = Completer>(); - // final client = userClient; - // final file = await adminClient.createDriveFile(); - // final name = Uuid().v4().replaceAll("-", "_"); - // final response = await adminClient.apiService - // .post("admin/emoji/add", {"name": name, "fileId": file.id}); - // await adminClient.apiService.post( - // "admin/emoji/update", - // {"id": response["id"], "name": name, "aliases": []}, - // ); - // final controller = client.mainStream(onEmojiUpdated: completer.complete); - // await client.startStreaming(); - // await adminClient.apiService.post( - // "admin/emoji/update", - // {"id": response["id"], "name": name, "aliases": []}, - // ); - // await completer.future; - // controller.disconnect(); - // }); - - // test("emojiDeleted", () async { - // final completer = Completer>(); - // final client = userClient; - // final file = await adminClient.createDriveFile(); - // final name = Uuid().v4().replaceAll("-", "_"); - // final response = await adminClient.apiService - // .post("admin/emoji/add", {"name": name, "fileId": file.id}); - // final controller = client.mainStream(onEmojiDeleted: completer.complete); - // await client.startStreaming(); - // await adminClient.apiService - // .post("admin/emoji/delete", {"id": response["id"]}); - // await completer.future; - // controller.disconnect(); - // }); - - // test("announcementCreated", () async { - // final completer = Completer(); - // final client = userClient; - // final controller = client.mainStream( - // onAnnouncementCreated: completer.complete, - // ); - // await client.startStreaming(); - // await adminClient.apiService.post("admin/announcements/create", { - // "title": "title", - // "text": "test", - // "imageUrl": "https://example.com", - // }); - // await completer.future; - // controller.disconnect(); - // }); - // }); + group("broadcast", () { + test("emojiCreated", () async { + final completer = Completer(); + final client = userClient; + final name = Uuid().v4().replaceAll("-", "_"); + final file = await adminClient.createDriveFile(); + final controller = await client.streamingService.stream(); + final id = DateTime.now().toIso8601String(); + final listener = controller + .homeTimelineStream(id: id, parameter: HomeTimelineParameter()) + .listen((event) { + final body = event.body; + if (body is EmojiAddedStreamEvent) completer.complete(body.emoji); + }); + await adminClient.apiService + .post("admin/emoji/add", {"name": name, "fileId": file.id}); + await completer.future; + await (controller.removeChannel(id), listener.cancel()).wait; + }); + + test("emojiUpdated", () async { + final completer = Completer>(); + final client = userClient; + final file = await adminClient.createDriveFile(); + final name = Uuid().v4().replaceAll("-", "_"); + final response = await adminClient.apiService + .post("admin/emoji/add", {"name": name, "fileId": file.id}); + await adminClient.apiService.post( + "admin/emoji/update", + {"id": response["id"], "name": name, "aliases": []}, + ); + final controller = await client.streamingService.stream(); + final id = DateTime.now().toIso8601String(); + final listener = controller + .homeTimelineStream(id: id, parameter: HomeTimelineParameter()) + .listen((event) { + final body = event.body; + if (body is EmojiUpdatedStreamEvent) completer.complete(body.emojis); + }); + await adminClient.apiService.post( + "admin/emoji/update", + {"id": response["id"], "name": name, "aliases": []}, + ); + await completer.future; + await (controller.removeChannel(id), listener.cancel()).wait; + }); + + test("emojiDeleted", () async { + final completer = Completer>(); + final client = userClient; + final file = await adminClient.createDriveFile(); + final name = Uuid().v4().replaceAll("-", "_"); + final response = await adminClient.apiService + .post("admin/emoji/add", {"name": name, "fileId": file.id}); + final controller = await client.streamingService.stream(); + final id = DateTime.now().toIso8601String(); + final listener = controller + .homeTimelineStream(id: id, parameter: HomeTimelineParameter()) + .listen((event) { + final body = event.body; + if (body is EmojiDeletedStreamEvent) completer.complete(body.emojis); + }); + await adminClient.apiService + .post("admin/emoji/delete", {"id": response["id"]}); + await completer.future; + await (controller.removeChannel(id), listener.cancel()).wait; + }); + + test("announcementCreated", () async { + final completer = Completer(); + final client = userClient; + + final controller = await client.streamingService.stream(); + final id = DateTime.now().toIso8601String(); + final listener = controller + .homeTimelineStream(id: id, parameter: HomeTimelineParameter()) + .listen((event) { + final body = event.body; + if (body is AnnouncementCreatedStreamEvent) { + completer.complete(body.announcement); + } + }); + await adminClient.apiService.post("admin/announcements/create", { + "title": "title", + "text": "test", + "imageUrl": "https://example.com", + }); + await completer.future; + await (controller.removeChannel(id), listener.cancel()).wait; + }); + }); }