belongs to Maven artifact com.android.support:recyclerview-v7:28.0.0-alpha1
RecyclerView.SmoothScroller.ScrollVectorProvider
public
static
interface
RecyclerView.SmoothScroller.ScrollVectorProvider
android.support.v7.widget.RecyclerView.SmoothScroller.ScrollVectorProvider |
Known Indirect Subclasses |
An interface which is optionally implemented by custom RecyclerView.LayoutManager
to provide a hint to a RecyclerView.SmoothScroller
about the location of the target position.
Summary
Public methods | |
---|---|
abstract
PointF
|
computeScrollVectorForPosition(int targetPosition)
Should calculate the vector that points to the direction where the target position can be found. |
Public methods
computeScrollVectorForPosition
PointF computeScrollVectorForPosition (int targetPosition)
Should calculate the vector that points to the direction where the target position can be found.
This method is used by the LinearSmoothScroller
to initiate a scroll towards
the target position.
The magnitude of the vector is not important. It is always normalized before being
used by the LinearSmoothScroller
.
LayoutManager should not check whether the position exists in the adapter or not.
Parameters | |
---|---|
targetPosition |
int : the target position to which the returned vector should point |
Returns | |
---|---|
PointF |
the scroll vector for a given position. |
Annotations
Interfaces
- ActionMenuView.OnMenuItemClickListener
- PopupMenu.OnDismissListener
- PopupMenu.OnMenuItemClickListener
- RecyclerView.ChildDrawingOrderCallback
- RecyclerView.ItemAnimator.ItemAnimatorFinishedListener
- RecyclerView.LayoutManager.LayoutPrefetchRegistry
- RecyclerView.OnChildAttachStateChangeListener
- RecyclerView.OnItemTouchListener
- RecyclerView.RecyclerListener
- RecyclerView.SmoothScroller.ScrollVectorProvider
- SearchView.OnCloseListener
- SearchView.OnQueryTextListener
- SearchView.OnSuggestionListener
- ShareActionProvider.OnShareTargetSelectedListener
- ThemedSpinnerAdapter
- Toolbar.OnMenuItemClickListener
Classes
- ActionMenuView
- ActionMenuView.LayoutParams
- AppCompatAutoCompleteTextView
- AppCompatButton
- AppCompatCheckBox
- AppCompatCheckedTextView
- AppCompatEditText
- AppCompatImageButton
- AppCompatImageView
- AppCompatMultiAutoCompleteTextView
- AppCompatRadioButton
- AppCompatRatingBar
- AppCompatSeekBar
- AppCompatSpinner
- AppCompatTextView
- CardView
- DefaultItemAnimator
- DividerItemDecoration
- GridLayout
- GridLayout.Alignment
- GridLayout.LayoutParams
- GridLayout.Spec
- GridLayoutManager
- GridLayoutManager.DefaultSpanSizeLookup
- GridLayoutManager.LayoutParams
- GridLayoutManager.SpanSizeLookup
- LinearLayoutCompat
- LinearLayoutCompat.LayoutParams
- LinearLayoutManager
- LinearLayoutManager.LayoutChunkResult
- LinearSmoothScroller
- LinearSnapHelper
- ListPopupWindow
- OrientationHelper
- PagerSnapHelper
- PopupMenu
- RecyclerView
- RecyclerView.Adapter
- RecyclerView.AdapterDataObserver
- RecyclerView.EdgeEffectFactory
- RecyclerView.ItemAnimator
- RecyclerView.ItemAnimator.ItemHolderInfo
- RecyclerView.ItemDecoration
- RecyclerView.LayoutManager
- RecyclerView.LayoutManager.Properties
- RecyclerView.LayoutParams
- RecyclerView.OnFlingListener
- RecyclerView.OnScrollListener
- RecyclerView.RecycledViewPool
- RecyclerView.Recycler
- RecyclerView.SimpleOnItemTouchListener
- RecyclerView.SmoothScroller
- RecyclerView.SmoothScroller.Action
- RecyclerView.State
- RecyclerView.ViewCacheExtension
- RecyclerView.ViewHolder
- RecyclerViewAccessibilityDelegate
- RecyclerViewAccessibilityDelegate.ItemDelegate
- SearchView
- ShareActionProvider
- SimpleItemAnimator
- SnapHelper
- StaggeredGridLayoutManager
- StaggeredGridLayoutManager.LayoutParams
- SwitchCompat
- ThemedSpinnerAdapter.Helper
- Toolbar
- Toolbar.LayoutParams
- Toolbar.SavedState
- TooltipCompat