diff --git a/lib/voe-extractor/build.gradle.kts b/lib/voe-extractor/build.gradle.kts index c26cbc8a82..a503203dd6 100644 --- a/lib/voe-extractor/build.gradle.kts +++ b/lib/voe-extractor/build.gradle.kts @@ -1,3 +1,7 @@ plugins { id("lib-android") } + +dependencies { + implementation(project(":lib:playlist-utils")) +} \ No newline at end of file diff --git a/lib/voe-extractor/src/main/java/eu/kanade/tachiyomi/lib/voeextractor/VoeExtractor.kt b/lib/voe-extractor/src/main/java/eu/kanade/tachiyomi/lib/voeextractor/VoeExtractor.kt index e589ad7954..a9c3293adb 100644 --- a/lib/voe-extractor/src/main/java/eu/kanade/tachiyomi/lib/voeextractor/VoeExtractor.kt +++ b/lib/voe-extractor/src/main/java/eu/kanade/tachiyomi/lib/voeextractor/VoeExtractor.kt @@ -1,26 +1,44 @@ package eu.kanade.tachiyomi.lib.voeextractor +import android.util.Base64 import eu.kanade.tachiyomi.animesource.model.Video +import eu.kanade.tachiyomi.lib.playlistutils.PlaylistUtils import eu.kanade.tachiyomi.network.GET import eu.kanade.tachiyomi.util.asJsoup +import kotlinx.serialization.Serializable +import kotlinx.serialization.json.Json import okhttp3.OkHttpClient +import uy.kohesive.injekt.injectLazy class VoeExtractor(private val client: OkHttpClient) { - fun videoFromUrl(url: String, quality: String? = null, prefix: String = ""): Video? { + + private val json: Json by injectLazy() + + private val playlistUtils by lazy { PlaylistUtils(client) } + + @Serializable + data class VideoLinkDTO(val file: String) + + fun videosFromUrl(url: String, prefix: String = ""): List