-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b7f55ba
commit 4dd6e21
Showing
15 changed files
with
539 additions
and
228 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,113 +1,116 @@ | ||
## v4.0.12 (Sep 15, 2023) | ||
|
||
### Improvements | ||
- Fixed the bug regarding parent FileMessage type | ||
- Updated regarding statistics | ||
|
||
## v4.0.11 (Sep 12, 2023) | ||
|
||
### Improvements | ||
- Fixed the bug regarding the url encoding of `userId`. | ||
- Fixed the bug regarding the url encoding of `userId` | ||
|
||
## v4.0.10 (Aug 31, 2023) | ||
|
||
### Improvements | ||
- Fixed the bug regarding the `FeedChannel` caching. | ||
- Fixed the bug regarding the `FeedChannel` caching | ||
|
||
## v4.0.9 (Aug 30, 2023) | ||
|
||
### Improvements | ||
- Fixed the bug regarding the `hasNext` in `BaseMessageCollection`. | ||
- Fixed the bug when the `reverse` is `true` in `MessageListParams` regarding `BaseMessageCollection`. | ||
- Improved stability. | ||
- Fixed the bug regarding the `hasNext` in `BaseMessageCollection` | ||
- Fixed the bug when the `reverse` is `true` in `MessageListParams` regarding `BaseMessageCollection` | ||
- Improved stability | ||
|
||
## v4.0.8 (Aug 22, 2023) | ||
|
||
### Features | ||
- Replaced `Map<String, String> templateVariables` with `Map<String, dynamic> templateVariables` in `NotificationData`. | ||
- Added `tags` in `NotificationData`. | ||
- Replaced `Map<String, String> templateVariables` with `Map<String, dynamic> templateVariables` in `NotificationData` | ||
- Added `tags` in `NotificationData` | ||
|
||
### Improvements | ||
- Improved stability. | ||
- Improved stability | ||
|
||
## v4.0.7 (Aug 18, 2023) | ||
|
||
### Features | ||
- Added `notificationData` in `BaseMessage`. | ||
- Added `notificationData` in `BaseMessage` | ||
|
||
### Improvements | ||
- Fixed the bug regarding `unreadMessageCount` in `FeedChannel`. | ||
- Fixed the bug regarding `unreadMessageCount` in `FeedChannel` | ||
|
||
## v4.0.6 (Aug 16, 2023) | ||
|
||
### Features | ||
|
||
#### Notification | ||
- Added `isTemplateLabelEnabled`, `isCategoryFilterEnabled` and `notificationCategories` in `FeedChannel`. | ||
- Added `authenticateFeed()`, `refreshNotificationCollections()` in `SendbirdChat`. | ||
- Added `isTemplateLabelEnabled`, `isCategoryFilterEnabled` and `notificationCategories` in `FeedChannel` | ||
- Added `authenticateFeed()`, `refreshNotificationCollections()` in `SendbirdChat` | ||
|
||
### Improvements | ||
- Improved stability. | ||
- Improved stability | ||
|
||
## v4.0.5 (Jul 14, 2023) | ||
|
||
### Features | ||
- Added `SendbirdStatistics` for internal use. | ||
- Added `SendbirdStatistics` for internal use | ||
|
||
### Improvements | ||
- Improved stability. | ||
- Improved stability | ||
|
||
## v4.0.4 (Jul 3, 2023) | ||
|
||
### Improvements | ||
- Fixed the bug regarding `resendFileMessage()`. | ||
- Fixed the bug regarding connectivity events. | ||
- Fixed the bug regarding `resendFileMessage()` | ||
- Fixed the bug regarding connectivity events | ||
|
||
## v4.0.3 (Jun 30, 2023) | ||
|
||
### Features | ||
|
||
#### FeedChannel | ||
- Added `FeedChannelListQuery` | ||
- Added `FeedChannel`. | ||
- Added `feed` in `ChannelType`. | ||
- Added `getMyFeedChannelChangeLogs()` with `FeedChannelChangeLogsParams` in SendbirdChat. | ||
- Added `FeedChannel` | ||
- Added `feed` in `ChannelType` | ||
- Added `getMyFeedChannelChangeLogs()` with `FeedChannelChangeLogsParams` in SendbirdChat | ||
- Added `getTotalUnreadMessageCountWithFeedChannel() | ||
` in SendbirdChat. | ||
- Added `FeedChannelHandler`. | ||
- Added `onTotalUnreadMessageCountChanged()` in `UserEventHandler` and `UnreadMessageCount`. | ||
` in SendbirdChat | ||
- Added `FeedChannelHandler` | ||
- Added `onTotalUnreadMessageCountChanged()` in `UserEventHandler` and `UnreadMessageCount` | ||
|
||
#### Collection for notifications | ||
- Added `NotificationCollection`, `NotificationCollectionHandler` and `NotificationContext`. | ||
- Added `BaseMessageCollection`, `BaseMessageCollectionHandler` and `BaseMessageContext`. | ||
- Added `FeedChannelContext`, `BaseChannelContext`. | ||
- Added `NotificationCollection`, `NotificationCollectionHandler` and `NotificationContext` | ||
- Added `BaseMessageCollection`, `BaseMessageCollectionHandler` and `BaseMessageContext` | ||
- Added `FeedChannelContext`, `BaseChannelContext` | ||
|
||
#### ChatNotification for GroupChannel | ||
- Added `isChatNotification` in GroupChannel. | ||
- Added `includeChatNotification` in `GroupChannelListQuery` and `GroupChannelChangeLogsParams`. | ||
- Added `isChatNotification` in GroupChannel | ||
- Added `includeChatNotification` in `GroupChannelListQuery` and `GroupChannelChangeLogsParams` | ||
|
||
#### Setting and Template for Notification | ||
- Added `getGlobalNotificationChannelSetting() | ||
` and `GlobalNotificationChannelSetting` in SendbirdChat. | ||
- Added `getNotificationTemplateListByToken() | ||
` with `NotificationTemplateListParams` and `NotificationTemplateList` in SendbirdChat. | ||
- Added `getNotificationTemplate() | ||
` and `NotificationTemplate` in SendbirdChat. | ||
- Added `getGlobalNotificationChannelSetting()` and `GlobalNotificationChannelSetting` in SendbirdChat | ||
- Added `getNotificationTemplateListByToken()` with `NotificationTemplateListParams` and `NotificationTemplateList` in SendbirdChat | ||
- Added `getNotificationTemplate()` and `NotificationTemplate` in SendbirdChat | ||
|
||
#### NotificationInfo | ||
- Added `NotificationInfo`. | ||
- Added `notificationInfo` in `AppInfo`. | ||
- Added `NotificationInfo` | ||
- Added `notificationInfo` in `AppInfo` | ||
|
||
### Improvements | ||
- Improved stability. | ||
- Improved stability | ||
|
||
## v4.0.2 (Jun 23, 2023) | ||
- Improved stability. | ||
- Improved stability | ||
|
||
## v4.0.1 (Jun 14, 2023) | ||
- Improved stability. | ||
- Improved stability | ||
|
||
## v4.0.0 (May 31, 2023) | ||
> To see detailed changes, please refer to the [migration guide](https://sendbird.com/docs/chat/v4/flutter/getting-started/migration-guide). | ||
> To see detailed changes, please refer to the [migration guide](https://sendbird.com/docs/chat/v4/flutter/getting-started/migration-guide) | ||
### Features | ||
- Added `GroupChannelCollection`, `GroupChannelContext` and `GroupChannelCollectionHandler`. | ||
- Added `MessageCollection`, `MessageContext` and `MessageCollectionHandler`. | ||
- Added `enum CollectionEventSource`. | ||
- Added `GroupChannelCollection`, `GroupChannelContext` and `GroupChannelCollectionHandler` | ||
- Added `MessageCollection`, `MessageContext` and `MessageCollectionHandler` | ||
- Added `enum CollectionEventSource` | ||
|
||
## v3 Changelog | ||
Please refer to [this page](https://github.com/sendbird/sendbird-chat-sdk-flutter/blob/v3/CHANGELOG.md). | ||
Please refer to [this page](https://github.com/sendbird/sendbird-chat-sdk-flutter/blob/v3/CHANGELOG.md) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
// Copyright (c) 2023 Sendbird, Inc. All rights reserved. | ||
|
||
import 'package:sendbird_chat_sdk/src/internal/main/logger/sendbird_logger.dart'; | ||
import 'package:sendbird_chat_sdk/src/internal/main/stats/default_stat.dart'; | ||
import 'package:sendbird_chat_sdk/src/internal/main/stats/stat_type.dart'; | ||
|
||
class ApiResultStat extends DefaultStat { | ||
final String endpoint; // endpoint | ||
final String method; // 'GET|POST|PUT|DELETE' | ||
final bool success; // success or not | ||
final int latency; // roundtrip latency | ||
final int? errorCode; // error code if exist | ||
final String? errorDescription; // detailed error message | ||
|
||
ApiResultStat({ | ||
required int ts, | ||
required this.endpoint, | ||
required this.method, | ||
required this.success, | ||
required this.latency, | ||
this.errorCode, | ||
this.errorDescription, | ||
}) : super(StatType.apiResult, ts); | ||
|
||
@override | ||
Map<String, dynamic> toJson() { | ||
final json = <String, dynamic>{ | ||
'endpoint': endpoint, | ||
'method': method, | ||
'success': success, | ||
'latency': latency, | ||
'error_code': errorCode, | ||
'error_description': errorDescription, | ||
}; | ||
final result = super.toJson(); | ||
result['data'] = json; | ||
return result; | ||
} | ||
|
||
// { | ||
// 'stat_type' : 'api:result', | ||
// 'ts': int, // timestamp for log creation, | ||
// 'data' : { | ||
// 'endpoint': String, | ||
// 'method': String, | ||
// 'success': bool, | ||
// 'latency': int, | ||
// 'error_code': int?, | ||
// 'error_description': String?, | ||
// }, | ||
// } | ||
static ApiResultStat? fromJson({ | ||
required int ts, | ||
required Map<String, dynamic> data, | ||
}) { | ||
try { | ||
final String? endpoint = data['endpoint'] as String?; | ||
final String? method = data['method'] as String?; | ||
final bool? success = data['success'] as bool?; | ||
final int? latency = data['latency'] as int?; | ||
final int? errorCode = data['error_code'] as int?; | ||
final String? errorDescription = data['error_description'] as String?; | ||
|
||
if (endpoint == null || | ||
method == null || | ||
success == null || | ||
latency == null) { | ||
return null; | ||
} | ||
|
||
return ApiResultStat( | ||
ts: ts, | ||
endpoint: endpoint, | ||
method: method, | ||
success: success, | ||
latency: latency, | ||
errorCode: errorCode, | ||
errorDescription: errorDescription, | ||
); | ||
} catch (e) { | ||
sbLog.d(StackTrace.current, 'e: ${e.toString()}'); | ||
} | ||
return null; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.