Yokan / rebuild
Course 1 8624561

ResolvableAnimeSource.kt

vendor/yokan-ext/src/androidMain/kotlin/eu/kanade/tachiyomi/animesource/online/ResolvableAnimeSource.kt

implementation44 lines
1package eu.kanade.tachiyomi.animesource.online23import eu.kanade.tachiyomi.animesource.AnimeSource4import eu.kanade.tachiyomi.animesource.model.SAnime5import eu.kanade.tachiyomi.animesource.model.SEpisode67/**8 * A source that may handle opening an SAnime or SEpisode for a given URI.9 *10 * @since extensions-lib 1411 */12interface ResolvableAnimeSource : AnimeSource {13    /**14     * Returns what the given URI may open.15     * Returns [UriType.Unknown] if the source is not able to resolve the URI.16     *17     * @since extensions-lib 1418     */19    fun getUriType(uri: String): UriType2021    /**22     * Called if [getUriType] is [UriType.Anime].23     * Returns the corresponding SAnime, if possible.24     *25     * @since extensions-lib 1426     */27    suspend fun getAnime(uri: String): SAnime?2829    /**30     * Called if [getUriType] is [UriType.Episode].31     * Returns the corresponding SEpisode, if possible.32     *33     * @since extensions-lib 1434     */35    suspend fun getEpisode(uri: String): SEpisode?36}3738sealed interface UriType {39    data object Anime : UriType4041    data object Episode : UriType4243    data object Unknown : UriType44}45

Search chapters, reference and source filenames.