-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
the logic related to getting specific folder data was done with isolate
- Loading branch information
Showing
12 changed files
with
129 additions
and
39 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
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
23 changes: 15 additions & 8 deletions
23
...cker_feature/data/models/telegram_file_image_with_compressed_and_original_path_model.dart
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,19 +1,26 @@ | ||
import 'package:yahay/features/telegram_file_picker_feature/domain/entities/telegram_file_image_with_compressed_and_original_path_entity.dart'; | ||
|
||
final class TelegramFileImageWithCompressedAndOriginalPathModel | ||
extends TelegramFileImageWithCompressedAndOriginalPathEntity { | ||
TelegramFileImageWithCompressedAndOriginalPathModel( | ||
final class TelegramPathFolderFileModel extends TelegramPathFolderFile { | ||
TelegramPathFolderFileModel( | ||
super.file, { | ||
super.originalPath, | ||
super.isFolder, | ||
super.isImage, | ||
super.isVideo, | ||
super.fileExtension, | ||
}); | ||
|
||
TelegramFileImageWithCompressedAndOriginalPathModel? fromEntity( | ||
TelegramFileImageWithCompressedAndOriginalPathEntity? entity, | ||
TelegramPathFolderFileModel? fromEntity( | ||
TelegramPathFolderFile? entity, | ||
) { | ||
if (entity == null) return null; | ||
return TelegramFileImageWithCompressedAndOriginalPathModel( | ||
file, | ||
originalPath: originalPath, | ||
return TelegramPathFolderFileModel( | ||
entity.file, | ||
originalPath: entity.originalPath, | ||
isFolder: entity.isFolder, | ||
isImage: entity.isImage, | ||
isVideo: entity.isVideo, | ||
fileExtension: entity.fileExtension, | ||
); | ||
} | ||
} |
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
12 changes: 10 additions & 2 deletions
12
...feature/domain/entities/telegram_file_image_with_compressed_and_original_path_entity.dart
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,11 +1,19 @@ | ||
import 'dart:io'; | ||
|
||
base class TelegramFileImageWithCompressedAndOriginalPathEntity { | ||
base class TelegramPathFolderFile { | ||
final File file; | ||
final String? originalPath; | ||
final bool isFolder; | ||
final bool isImage; | ||
final bool isVideo; | ||
final String? fileExtension; | ||
|
||
TelegramFileImageWithCompressedAndOriginalPathEntity( | ||
TelegramPathFolderFile( | ||
this.file, { | ||
this.originalPath, | ||
this.isFolder = false, | ||
this.isImage = false, | ||
this.isVideo = false, | ||
this.fileExtension, | ||
}); | ||
} |
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
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