public class MappingR2dbcConverter extends org.springframework.data.relational.core.conversion.BasicRelationalConverter implements R2dbcConverter
Constructor and Description |
---|
MappingR2dbcConverter(MappingContext<? extends org.springframework.data.relational.core.mapping.RelationalPersistentEntity<?>,? extends org.springframework.data.relational.core.mapping.RelationalPersistentProperty> context)
Creates a new
MappingR2dbcConverter given MappingContext . |
MappingR2dbcConverter(MappingContext<? extends org.springframework.data.relational.core.mapping.RelationalPersistentEntity<?>,? extends org.springframework.data.relational.core.mapping.RelationalPersistentProperty> context,
CustomConversions conversions)
|
Modifier and Type | Method and Description |
---|---|
Object |
getArrayValue(ArrayColumns arrayColumns,
org.springframework.data.relational.core.mapping.RelationalPersistentProperty property,
Object value)
Convert a
value into an array representation according to ArrayColumns . |
<T> BiFunction<io.r2dbc.spi.Row,io.r2dbc.spi.RowMetadata,T> |
populateIdIfNecessary(T object)
|
<R> R |
read(Class<R> type,
io.r2dbc.spi.Row row) |
void |
write(Object source,
OutboundRow sink) |
createInstance, getConversions, getConversionService, getMappingContext, getPropertyAccessor, readValue, writeValue
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getConversionService, getMappingContext
public MappingR2dbcConverter(MappingContext<? extends org.springframework.data.relational.core.mapping.RelationalPersistentEntity<?>,? extends org.springframework.data.relational.core.mapping.RelationalPersistentProperty> context)
MappingR2dbcConverter
given MappingContext
.context
- must not be null.public MappingR2dbcConverter(MappingContext<? extends org.springframework.data.relational.core.mapping.RelationalPersistentEntity<?>,? extends org.springframework.data.relational.core.mapping.RelationalPersistentProperty> context, CustomConversions conversions)
context
- must not be null.public <R> R read(Class<R> type, io.r2dbc.spi.Row row)
read
in interface EntityReader<Object,io.r2dbc.spi.Row>
public void write(Object source, OutboundRow sink)
write
in interface EntityWriter<Object,OutboundRow>
public Object getArrayValue(ArrayColumns arrayColumns, org.springframework.data.relational.core.mapping.RelationalPersistentProperty property, Object value)
R2dbcConverter
value
into an array representation according to ArrayColumns
.getArrayValue
in interface R2dbcConverter
arrayColumns
- dialect-specific array handling configuration.public <T> BiFunction<io.r2dbc.spi.Row,io.r2dbc.spi.RowMetadata,T> populateIdIfNecessary(T object)
populateIdIfNecessary
in interface R2dbcConverter
object
- must not be null.Copyright © 2018–2019 Pivotal Software, Inc.. All rights reserved.