aboutsummaryrefslogtreecommitdiff
path: root/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactoryWithCache.kt
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactoryWithCache.kt')
-rw-r--r--plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactoryWithCache.kt21
1 files changed, 0 insertions, 21 deletions
diff --git a/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactoryWithCache.kt b/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactoryWithCache.kt
deleted file mode 100644
index 0b56e174..00000000
--- a/plugins/base/src/main/kotlin/resolvers/external/ExternalLocationProviderFactoryWithCache.kt
+++ /dev/null
@@ -1,21 +0,0 @@
-/*
- * Copyright 2014-2023 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license.
- */
-
-package org.jetbrains.dokka.base.resolvers.external
-
-import org.jetbrains.dokka.base.resolvers.shared.ExternalDocumentation
-import java.util.concurrent.ConcurrentHashMap
-
-public class ExternalLocationProviderFactoryWithCache(
- public val ext: ExternalLocationProviderFactory
-) : ExternalLocationProviderFactory {
-
- private val locationProviders = ConcurrentHashMap<ExternalDocumentation, CacheWrapper>()
-
- override fun getExternalLocationProvider(doc: ExternalDocumentation): ExternalLocationProvider? =
- locationProviders.getOrPut(doc) { CacheWrapper(ext.getExternalLocationProvider(doc)) }.provider
-
- private class CacheWrapper(val provider: ExternalLocationProvider?)
-}
-