aboutsummaryrefslogtreecommitdiff
path: root/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt')
-rw-r--r--plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt25
1 files changed, 3 insertions, 22 deletions
diff --git a/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt b/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt
index 83de9911..10d9fffa 100644
--- a/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt
+++ b/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactory.kt
@@ -1,26 +1,7 @@
package org.jetbrains.dokka.base.resolvers.external
-import org.jetbrains.dokka.links.DRI
-import java.util.concurrent.ConcurrentHashMap
-
-
-interface ExternalLocationProvider {
-
- val param: String
- fun DRI.toLocation(): String
-}
+import org.jetbrains.dokka.base.resolvers.shared.ExternalDocumentationInfo
interface ExternalLocationProviderFactory {
-
- fun getExternalLocationProvider(param: String): ExternalLocationProvider?
-}
-
-class ExternalLocationProviderFactoryWithCache(val ext: ExternalLocationProviderFactory) : ExternalLocationProviderFactory {
-
- private val locationProviders = ConcurrentHashMap<String, CacheWrapper>()
-
- override fun getExternalLocationProvider(param: String): ExternalLocationProvider? =
- locationProviders.getOrPut(param) { CacheWrapper(ext.getExternalLocationProvider(param)) }.provider
-}
-
-private class CacheWrapper(val provider: ExternalLocationProvider?) \ No newline at end of file
+ fun getExternalLocationProvider(docInfo: ExternalDocumentationInfo): ExternalLocationProvider?
+} \ No newline at end of file