Class ConvertingParameterAccessor
java.lang.Object
org.springframework.data.cassandra.repository.query.ConvertingParameterAccessor
- All Implemented Interfaces:
Iterable<Object>, CassandraParameterAccessor, ParameterAccessor
Custom
ParameterAccessor that uses a CassandraConverter to
convert parameters.
Only intended for internal use.
- Since:
- 1.5
- Author:
- Mark Paluch, Chris Bono
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionConvertingParameterAccessor(CassandraConverter converter, CassandraParameterAccessor delegate) -
Method Summary
Modifier and TypeMethodDescription@Nullable CassandraTypefindCassandraType(int index) Returns theCassandraTypefor the declared method parameter.@Nullable Class<?> @Nullable ObjectgetBindableValue(int index) @Nullable com.datastax.oss.driver.api.core.type.DataTypegetDataType(int index) Returns the CassandraDataTypefor the declared parameter if the type is asimple type.getLimit()Class<?> getParameterType(int index) The actual parameter type (after unwrapping).@Nullable QueryOptionsReturns theQueryOptionsassociated with the associated Repository query method.@Nullable ScoregetScore()getSort()@Nullable ObjectgetValue(int parameterIndex) Get the value of the parameter at the given index.Object[]Returns the raw parameter values of the underlying query method.@Nullable Vectorbooleaniterator()Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Constructor Details
-
ConvertingParameterAccessor
public ConvertingParameterAccessor(CassandraConverter converter, CassandraParameterAccessor delegate)
-
-
Method Details
-
getScrollPosition
- Specified by:
getScrollPositionin interfaceCassandraParameterAccessor- Specified by:
getScrollPositionin interfaceParameterAccessor
-
getScoringFunction
Description copied from interface:CassandraParameterAccessor- Specified by:
getScoringFunctionin interfaceCassandraParameterAccessor- Returns:
- the scoring function or null if none is provided.
-
getVector
- Specified by:
getVectorin interfaceParameterAccessor
-
getScore
- Specified by:
getScorein interfaceParameterAccessor
-
getScoreRange
- Specified by:
getScoreRangein interfaceParameterAccessor
-
getPageable
- Specified by:
getPageablein interfaceParameterAccessor
-
getSort
- Specified by:
getSortin interfaceParameterAccessor
-
getLimit
- Specified by:
getLimitin interfaceParameterAccessor
-
findDynamicProjection
- Specified by:
findDynamicProjectionin interfaceParameterAccessor
-
getBindableValue
- Specified by:
getBindableValuein interfaceParameterAccessor
-
findCassandraType
Description copied from interface:CassandraParameterAccessorReturns theCassandraTypefor the declared method parameter.- Specified by:
findCassandraTypein interfaceCassandraParameterAccessor- Parameters:
index- the parameter index- Returns:
- the Cassandra
CassandraTypeor null. - See Also:
-
getDataType
public @Nullable com.datastax.oss.driver.api.core.type.DataType getDataType(int index) Description copied from interface:CassandraParameterAccessorReturns the CassandraDataTypefor the declared parameter if the type is asimple type. Parameter types may be specified usingCassandraType.- Specified by:
getDataTypein interfaceCassandraParameterAccessor- Parameters:
index- the parameter index- Returns:
- the Cassandra
DataTypeor null if the parameter type cannot be determined fromCassandraSimpleTypeHolder - See Also:
-
getParameterType
Description copied from interface:CassandraParameterAccessorThe actual parameter type (after unwrapping).- Specified by:
getParameterTypein interfaceCassandraParameterAccessor- Parameters:
index- the parameter index- Returns:
- the parameter type, never null.
-
getQueryOptions
Description copied from interface:CassandraParameterAccessorReturns theQueryOptionsassociated with the associated Repository query method.- Specified by:
getQueryOptionsin interfaceCassandraParameterAccessor- Returns:
- the
QueryOptionsor null if none.
-
hasBindableNullValue
public boolean hasBindableNullValue()- Specified by:
hasBindableNullValuein interfaceParameterAccessor
-
iterator
-
getValues
Description copied from interface:CassandraParameterAccessorReturns the raw parameter values of the underlying query method.- Specified by:
getValuesin interfaceCassandraParameterAccessor- Returns:
- the raw parameter values passed to the underlying query method.
-
getValue
Description copied from interface:CassandraParameterAccessorGet the value of the parameter at the given index. In contrast toParameterAccessor.getBindableValue(int), this method has access to all parameters.- Specified by:
getValuein interfaceCassandraParameterAccessor- Parameters:
parameterIndex-- Returns:
-