public interface SpannerConverter extends org.springframework.data.convert.EntityReader<Object,com.google.cloud.spanner.Struct>, org.springframework.data.convert.EntityWriter<Object,com.google.cloud.spanner.Mutation.WriteBuilder>
| Modifier and Type | Method and Description |
|---|---|
<T> List<T> |
mapToList(com.google.cloud.spanner.ResultSet resultSet,
Class<T> entityClass)
Converts a set of Spanner
ResultSet into a list of objects. |
<T> List<T> |
mapToList(com.google.cloud.spanner.ResultSet resultSet,
Class<T> entityClass,
Optional<Set<String>> includeColumns)
Converts a set of Spanner
ResultSet into a list of objects. |
<T> List<T> |
mapToList(com.google.cloud.spanner.ResultSet resultSet,
Class<T> entityClass,
String... includeColumns)
Converts a set of Spanner
ResultSet into a list of objects. |
void |
write(Object source,
com.google.cloud.spanner.Mutation.WriteBuilder sink,
Set<String> includeColumns)
Writes an object's properties to the sink.
|
<T> List<T> mapToList(com.google.cloud.spanner.ResultSet resultSet, Class<T> entityClass)
ResultSet into a list of objects.T - The type of the objects the Spanner results represent.resultSet - The Spanner results to convert. The ResultSet will be exhausted
and closed.entityClass - The type of the objects the Spanner results represent.<T> List<T> mapToList(com.google.cloud.spanner.ResultSet resultSet, Class<T> entityClass, Optional<Set<String>> includeColumns)
ResultSet into a list of objects.T - The type of the objects the Spanner results represent.resultSet - The Spanner results to convert. The ResultSet will be exhausted
and closed.entityClass - The type of the objects the Spanner results represent.includeColumns - the Set of columns to read. If the Set is not present or this
param is null then all columns will be read.<T> List<T> mapToList(com.google.cloud.spanner.ResultSet resultSet, Class<T> entityClass, String... includeColumns)
ResultSet into a list of objects.T - The type of the objects the Spanner results represent.resultSet - The Spanner results to convert. The ResultSet will be exhausted
and closed.entityClass - The type of the objects the Spanner results represent.includeColumns - the columns to read. If none are provided then all columns
are read.void write(Object source, com.google.cloud.spanner.Mutation.WriteBuilder sink, Set<String> includeColumns)
source - the object to writesink - the sink to which to writeincludeColumns - the properties/columns to write. If null, then all columns
are written.Copyright © 2018 Pivotal Software, Inc.. All rights reserved.