-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #365 from stakwork/tt/fix/feed-repository
Feed Repository refactor
- Loading branch information
Showing
23 changed files
with
79 additions
and
61 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
File renamed without changes.
File renamed without changes.
32 changes: 32 additions & 0 deletions
32
...ncept-repository-feed/src/main/java/chat/sphinx/concept_repository_feed/FeedRepository.kt
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,32 @@ | ||
package chat.sphinx.concept_repository_feed | ||
|
||
import chat.sphinx.wrapper_chat.ChatHost | ||
import chat.sphinx.wrapper_common.chat.ChatUUID | ||
import chat.sphinx.wrapper_common.dashboard.ChatId | ||
import chat.sphinx.wrapper_common.feed.FeedId | ||
import chat.sphinx.wrapper_common.feed.FeedUrl | ||
import chat.sphinx.wrapper_common.feed.Subscribed | ||
import chat.sphinx.wrapper_feed.Feed | ||
import chat.sphinx.wrapper_podcast.Podcast | ||
import chat.sphinx.wrapper_podcast.PodcastSearchResultRow | ||
import kotlinx.coroutines.flow.Flow | ||
|
||
interface FeedRepository { | ||
fun getPodcastByChatId(chatId: ChatId): Flow<Podcast?> | ||
fun getPodcastById(feedId: FeedId): Flow<Podcast?> | ||
fun searchPodcastBy(searchTerm: String): Flow<List<PodcastSearchResultRow>> | ||
|
||
suspend fun updateFeedContent( | ||
chatId: ChatId, | ||
host: ChatHost, | ||
feedUrl: FeedUrl, | ||
chatUUID: ChatUUID?, | ||
subscribed: Subscribed, | ||
currentEpisodeId: FeedId? | ||
) | ||
|
||
fun getFeedByChatId(chatId: ChatId): Flow<Feed?> | ||
fun getFeedById(feedId: FeedId): Flow<Feed?> | ||
|
||
suspend fun toggleFeedSubscribeState(feedId: FeedId, currentSubscribeState: Subscribed) | ||
} |
13 changes: 0 additions & 13 deletions
13
...ository-podcast/src/main/java/chat/sphinx/concept_repository_podcast/PodcastRepository.kt
This file was deleted.
Oops, something went wrong.
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
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
Oops, something went wrong.