compile-time проверка IStorageInfo
This commit is contained in:
@@ -9,9 +9,9 @@ class StorageFileManagementUseCase {
|
|||||||
private var _storage: IStorage? = null
|
private var _storage: IStorage? = null
|
||||||
|
|
||||||
fun setStorage(storage: IStorageInfo) {
|
fun setStorage(storage: IStorageInfo) {
|
||||||
//if(storage !is IStorage)
|
when (storage) {
|
||||||
// throw Exception("Can not manage storage on StorageInfo")
|
is IStorage -> _storage = storage
|
||||||
_storage = storage as IStorage
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
suspend fun getAllFiles(): List<IFile> {
|
suspend fun getAllFiles(): List<IFile> {
|
||||||
|
|||||||
Reference in New Issue
Block a user