Send feedback
Class ValueBinder<R>
Stay organized with collections
Save and categorize content based on your preferences.
6.116.0 (latest)
6.111.1
6.108.0
6.107.0
6.103.0
6.102.1
6.101.1
6.100.0
6.99.0
6.98.1
6.97.1
6.96.1
6.95.1
6.94.0
6.93.0
6.89.0
6.88.0
6.87.0
6.86.0
6.85.0
6.83.0
6.82.0
6.80.1
6.79.0
6.77.0
6.74.1
6.72.0
6.71.0
6.69.0
6.68.0
6.66.0
6.65.1
6.62.0
6.60.0
6.58.0
6.57.0
6.56.0
6.55.0
6.54.0
6.53.0
6.52.1
6.51.0
6.50.1
6.49.0
6.25.1
6.24.0
6.23.4
6.22.0
6.21.2
6.20.0
6.19.1
6.18.0
6.17.4
6.14.1
public abstract class ValueBinder<R>
An interface for binding a Value in some context. Users of the Cloud Spanner client
library never create a ValueBinder directly; instead this interface is returned from
other parts of the library involved in Value construction. For example, Mutation.WriteBuilder#set(String) returns a binder to bind a column value, and
Statement#bind(String) returns a binder to bind a parameter to a value.
ValueBinder subclasses typically carry state and are therefore not thread-safe,
although the core implementation itself is thread-safe.
Type Parameter
Methods
to(boolean value)
public R to ( boolean value )
Binds to Value.bool(value)
Parameter
Returns
to(ByteArray value)
public R to ( ByteArray value )
Binds to Value.bytes(value)
Parameter
Name
Description
value
com.google.cloud.ByteArray
Returns
to(Date value)
Binds to Value.date(value)
Parameter
Name
Description
value
com.google.cloud.Date
Returns
to(Timestamp value)
public R to ( Timestamp value )
Binds to Value.timestamp(value)
Parameter
Name
Description
value
com.google.cloud.Timestamp
Returns
to(Struct value)
public R to ( Struct value )
Binds a non-NULL struct value to Value.struct(value)
Parameter
Returns
to(Type type, Struct value)
public R to ( Type type , Struct value )
Binds a nullable Struct reference with given Type to
Value.struct(type,value
Parameters
Returns
to(Value value)
Parameter
Name
Description
value
Value
Returns
to(double value)
public R to ( double value )
Binds to Value.float64(value)
Parameter
Returns
to(Boolean value)
public R to ( Boolean value )
Binds to Value.bool(value)
Parameter
Returns
to(Double value)
public R to ( Double value )
Binds to Value.float64(value)
Parameter
Returns
to(Long value)
Binds to Value.int64(value)
Parameter
Name
Description
value
Long
Returns
to(String value)
public R to ( String value )
Binds to Value.string(value)
Parameter
Returns
to(BigDecimal value)
public R to ( BigDecimal value )
Binds to Value.numeric(value)
Parameter
Returns
to(long value)
Binds to Value.int64(value)
Parameter
Name
Description
value
long
Returns
toBoolArray(boolean[] values)
public R toBoolArray ( boolean [] values )
Binds to Value.boolArray(values)
Parameter
Returns
toBoolArray(boolean[] values, int pos, int length)
public R toBoolArray ( boolean [] values , int pos , int length )
Binds to Value.boolArray(values, int, pos)
Parameters
Returns
toBoolArray(Iterable<Boolean> values)
public R toBoolArray ( Iterable<Boolean> values )
Binds to Value.boolArray(values)
Parameter
Returns
toBytesArray(Iterable<ByteArray> values)
public R toBytesArray ( Iterable<ByteArray> values )
Binds to Value.bytesArray(values)
Parameter
Name
Description
values
Iterable <com.google.cloud.ByteArray >
Returns
toDateArray(Iterable<Date> values)
public R toDateArray ( Iterable<Date> values )
Binds to Value.dateArray(values)
Parameter
Name
Description
values
Iterable <com.google.cloud.Date >
Returns
toFloat64Array(double[] values)
public R toFloat64Array ( double [] values )
Binds to Value.float64Array(values)
Parameter
Name
Description
values
double []
Returns
toFloat64Array(double[] values, int pos, int length)
public R toFloat64Array ( double [] values , int pos , int length )
Binds to Value.float64Array(values, pos, length)
Parameters
Returns
toFloat64Array(Iterable<Double> values)
public R toFloat64Array ( Iterable<Double> values )
Binds to Value.float64Array(values)
Parameter
Returns
toInt64Array(Iterable<Long> values)
public R toInt64Array ( Iterable<Long> values )
Binds to Value.int64Array(values)
Parameter
Returns
toInt64Array(long[] values)
public R toInt64Array ( long [] values )
Binds to Value.int64Array(values)
Parameter
Name
Description
values
long []
Returns
toInt64Array(long[] values, int pos, int length)
public R toInt64Array ( long [] values , int pos , int length )
Binds to Value.int64Array(values, pos, length)
Parameters
Returns
toJsonArray(Iterable<String> values)
public R toJsonArray ( Iterable<String> values )
Binds to Value.jsonArray(values)
Parameter
Returns
toNumericArray(Iterable<BigDecimal> values)
public R toNumericArray ( Iterable<BigDecimal> values )
Binds to Value.numericArray(values)
Parameter
Returns
toPgNumericArray(Iterable<String> values)
public R toPgNumericArray ( Iterable<String> values )
Binds to Value.pgNumericArray(values)
Parameter
Returns
toStringArray(Iterable<String> values)
public R toStringArray ( Iterable<String> values )
Binds to Value.stringArray(values)
Parameter
Returns
toStructArray(Type elementType, Iterable<Struct> values)
public R toStructArray ( Type elementType , Iterable<Struct> values )
Binds to Value.structArray(fieldTypes, values)
Parameters
Returns
toTimestampArray(Iterable<Timestamp> values)
public R toTimestampArray ( Iterable<Timestamp> values )
Binds to Value.timestampArray(values)
Parameter
Name
Description
values
Iterable <com.google.cloud.Timestamp >
Returns
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-04-26 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2026-04-26 UTC."],[],[]]