org.springframework.data.repository.query

## Interface ParameterAccessor

All Superinterfaces:
  Iterable<Object>

All Known Implementing Classes:
  ParametersParameterAccessor

    public interface ParameterAccessor
    extends Iterable<Object>

Interface to access method parameters. Allows dedicated access to parameters of special types

Author:
  Oliver Gierke, Mark Paluch

### Method Summary

All Methods Instance Methods Abstract Methods Deprecated Methods
`Class<?>` `findDynamicProjection()` Returns the dynamic projection type to be used when executing the query or null if none is defined.
`Object` `getBindableValue(int index)` Returns the bindable value with the given index.
`Optional<Class<?>>` `getDynamicProjection()` Deprecated. use `findDynamicProjection()` instead.
`Pageable` `getPageable()` Returns the `Pageable` of the parameters, if available.
`Sort` `getSort()` Returns the sort instance to be used for query creation.
`boolean` `hasBindableNullValue()` Returns whether one of the bindable parameter values is null.
`Iterator<Object>` `iterator()` Returns an iterator over all bindable parameters.

### Methods inherited from interface java.lang.Iterable

`forEach, spliterator`

### Method Detail

#### getPageable

    Pageable getPageable()

Returns the `Pageable` of the parameters, if available. Returns `null` otherwise.

Returns:

#### getSort

    Sort getSort()

Returns the sort instance to be used for query creation. Will use a `Sort` parameter if available or the `Sort` contained in a `Pageable` if available. Returns `null` if no `Sort` can be found.

Returns:

#### getDynamicProjection

    @Deprecated
    Optional<Class<?>> getDynamicProjection()

Deprecated. use `findDynamicProjection()` instead.
Returns the dynamic projection type to be used when executing the query or null if none is defined.

Returns:
Since:
  1.12

#### findDynamicProjection

    @Nullable
    Class<?> findDynamicProjection()

Returns the dynamic projection type to be used when executing the query or null if none is defined.

Returns:
Since:
  2.2

#### getBindableValue

    Object getBindableValue(int index)

Returns the bindable value with the given index. Bindable means, that `Pageable` and `Sort` values are skipped without noticed in the index. For a method signature taking `String`, `Pageable` , `String`, `#getBindableParameter(1)` would return the second `String` value.

Parameters:
  `index` -
Returns:

#### hasBindableNullValue

    boolean hasBindableNullValue()

Returns whether one of the bindable parameter values is null.

Returns:

#### iterator

    Iterator<Object> iterator()

Returns an iterator over all bindable parameters. This means parameters implementing `Pageable` or `Sort` will not be included in this `Iterator`.

Specified by:
  `iterator` in interface `Iterable<Object>`
Returns: