Package org.jdbi.v3.core.internal
Class EnumStrategies
java.lang.Object
org.jdbi.v3.core.internal.EnumStrategies
- All Implemented Interfaces:
JdbiConfig<EnumStrategies>
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturns a copy of this configuration object.<E extends Enum<E>>
EnumStrategyfindStrategy
(QualifiedType<E> type) Determines which strategy is to be used for a givenQualifiedType
, falling back to reading strategy annotations on the source class and/or using the configured default.void
setRegistry
(ConfigRegistry registry) The registry will inject itself into the configuration object.
-
Constructor Details
-
EnumStrategies
public EnumStrategies()
-
-
Method Details
-
setRegistry
Description copied from interface:JdbiConfig
The registry will inject itself into the configuration object. This can be useful if you need to look up dependencies. You will get a new registry after being copied.- Specified by:
setRegistry
in interfaceJdbiConfig<EnumStrategies>
- Parameters:
registry
- the registry that owns this configuration object
-
findStrategy
Determines which strategy is to be used for a givenQualifiedType
, falling back to reading strategy annotations on the source class and/or using the configured default.- Type Parameters:
E
- theEnum
type- Parameters:
type
- qualified type to derive a strategy from- Returns:
- the strategy by which this enum should be handled
-
createCopy
Description copied from interface:JdbiConfig
Returns a copy of this configuration object. Changes to the copy should not modify the original, and vice-versa.- Specified by:
createCopy
in interfaceJdbiConfig<EnumStrategies>
- Returns:
- a copy of this configuration object.
-