Package org.jdbi.v3.core.config.internal
Class ConfigCaches
java.lang.Object
org.jdbi.v3.core.config.internal.ConfigCaches
- All Implemented Interfaces:
JdbiConfig<ConfigCaches>
Hold metadata caches which maps various JVM constants into pre-parsed forms.
For example, bean property accessors, or normalized enum constants.
Note that unlike most JdbiConfig types, this cache is Jdbi level and shared,
so it should not hold data that needs to respect reconfiguration.
Additionally, currently there is no expiration policy, as nearly all keys are
references to JVM constant pool entries.
This makes it unsuitable as a general-purpose shared cache.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionDoes not actually create a copy!!static <K,V> ConfigCache<K, V> declare(BiFunction<ConfigRegistry, K, V> computer) static <K,V> ConfigCache<K, V> declare(Function<K, ?> keyNormalizer, BiFunction<ConfigRegistry, K, V> computer) static <K,V> ConfigCache<K, V> static <K,V> ConfigCache<K, V> Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jdbi.v3.core.config.JdbiConfig
setRegistry
-
Field Details
-
caches
-
-
Constructor Details
-
ConfigCaches
public ConfigCaches()
-
-
Method Details
-
createCopy
Does not actually create a copy!!- Specified by:
createCopyin interfaceJdbiConfig<ConfigCaches>- Returns:
- a copy of this configuration object.
-
declare
-
declare
-
declare
-
declare
public static <K,V> ConfigCache<K,V> declare(Function<K, ?> keyNormalizer, BiFunction<ConfigRegistry, K, V> computer)
-