Skip to content
This repository has been archived by the owner on Feb 22, 2024. It is now read-only.

Introduce result type #24

Merged
merged 24 commits into from Jun 30, 2021
Merged

Introduce result type #24

merged 24 commits into from Jun 30, 2021

Conversation

yrezgui
Copy link
Collaborator

@yrezgui yrezgui commented Jun 21, 2021

  • Upgrade ModernStorage to 1.5.10 Keep using Kotlin 1.4.32 due to compiler bug
  • Rename MediaStoreClient.kt to MediaStoreRepository.kt
  • Add permission handlers to MediaStoreRepository
  • Rename MediaResource to FileResource
  • Add @parcelize to FileResource
  • Expand media support to audio files
  • Simplify API naming
  • Add file scanning feature
  • Update sample app
  • Add guide
  • Upgrade project version
  • Add docs publishing action

Upgrade ModernStorage to 1.5.10
Rename MediaStoreClient.kt to MediaStoreRepository.kt
Add permission handlers to MediaStoreRepository
Rename MediaResource to FileResource
Add @parcelize to FileResource
Expand media support to audio files
Simplify API naming
Add file scanning feature
Update sample app
Upgrade ModernStorage to 1.5.10
Rename MediaStoreClient.kt to MediaStoreRepository.kt
Add permission handlers to MediaStoreRepository
Rename MediaResource to FileResource
Add @parcelize to FileResource
Expand media support to audio files
Simplify API naming
Add file scanning feature
Update sample app

withContext(Dispatchers.IO) {
val response = httpClient.newCall(request).execute()
return withContext(Dispatchers.IO) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
return withContext(Dispatchers.IO) {
return withContext(ioDispatcher) {

The IO dispatcher should be injected into the ViewModel to make testing easier

@yrezgui yrezgui added this to To Do in Roadmap Jun 22, 2021
@yrezgui yrezgui moved this from To Do to In Progress in Roadmap Jun 22, 2021
yrezgui and others added 2 commits June 22, 2021 22:18
Remove companion object
Simplify scanning logic
Update api metadata
…e/MediaStoreViewModel.kt

Co-authored-by: Lukas Valkovic <lukasvalkovic@users.noreply.github.com>
@google-cla
Copy link

google-cla bot commented Jun 22, 2021

We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for all the commit author(s) or Co-authors. If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google.
In order to pass this check, please resolve this problem and then comment @googlebot I fixed it.. If the bot doesn't comment, it means it doesn't think anything has changed.

ℹ️ Googlers: Go here for more info.

@google-cla
Copy link

google-cla bot commented Jun 23, 2021

We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for all the commit author(s) or Co-authors. If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google.
In order to pass this check, please resolve this problem and then comment @googlebot I fixed it.. If the bot doesn't comment, it means it doesn't think anything has changed.

ℹ️ Googlers: Go here for more info.

Format code
@google-cla
Copy link

google-cla bot commented Jun 23, 2021

We found a Contributor License Agreement for you (the sender of this pull request), but were unable to find agreements for all the commit author(s) or Co-authors. If you authored these, maybe you used a different email address in the git commits than was used to sign the CLA (login here to double check)? If these were authored by someone else, then they will need to sign a CLA as well, and confirm that they're okay with these being contributed to Google.
In order to pass this check, please resolve this problem and then comment @googlebot I fixed it.. If the bot doesn't comment, it means it doesn't think anything has changed.

ℹ️ Googlers: Go here for more info.

@lukasvalkovic
Copy link

@googlebot I fixed it.

Format code
Standardize argument names
Generate api metadata
Compiler bug with Result type when using suspend functions
Set FileType.NONE as FileResource type property (until I can figure out how to get media type value from MediaStore)
…olumn property

Extend UnsupportedMediaUriException from IllegalArgumentException instead of UnsupportedOperationException
Simplify FileResource.getEnum method logic
@yrezgui yrezgui merged commit f2e5b62 into main Jun 30, 2021
Roadmap automation moved this from In Progress to Done Jun 30, 2021
@yrezgui yrezgui deleted the introduce-result-type branch June 30, 2021 14:04
This was referenced Jun 30, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants