public class Mappers extends Object implements JdbiConfig<Mappers>
This configuration is merely a convenience class, and does not have any
configuration of its own. All methods delegate to RowMappers or
ColumnMappers.
| Constructor and Description |
|---|
Mappers() |
| Modifier and Type | Method and Description |
|---|---|
Mappers |
createCopy()
Returns a copy of this configuration object.
|
<T> Optional<RowMapper<T>> |
findFor(Class<T> type)
Obtain a mapper for the given type.
|
<T> Optional<RowMapper<T>> |
findFor(GenericType<T> type)
Obtain a mapper for the given type.
|
Optional<RowMapper<?>> |
findFor(Type type)
Obtain a mapper for the given type.
|
void |
setRegistry(ConfigRegistry registry)
The registry will inject itself into the configuration object.
|
public Mappers createCopy()
JdbiConfigcreateCopy in interface JdbiConfig<Mappers>public <T> Optional<RowMapper<T>> findFor(Class<T> type)
T - the type of the mapper to findtype - the target type to map topublic <T> Optional<RowMapper<T>> findFor(GenericType<T> type)
T - the type of the mapper to findtype - the target type to map topublic Optional<RowMapper<?>> findFor(Type type)
type - the target type to map topublic void setRegistry(ConfigRegistry registry)
JdbiConfigsetRegistry in interface JdbiConfig<Mappers>registry - the registry that owns this configuration objectCopyright © 2017. All rights reserved.