question: public int interpolateOutOfBoundsScroll ( RecyclerView recyclerView , int viewSize , int viewSizeOutOfBounds , int totalSize , long msSinceStartScroll ) { final int maxScroll = getMaxDragScroll ( recyclerView ) ; final int absOutOfBounds = Math . abs ( viewSizeOutOfBounds ) ; final int direction = ( int ) Math . signum ( viewSizeOutOfBounds ) ; float outOfBoundsRatio = Math . min ( 1f , 1f * absOutOfBounds / viewSize ) ; final int cappedScroll = ( int ) ( direction * maxScroll * sDragViewScrollCapInterpolator . getInterpolation ( outOfBoundsRatio ) ) ; final float timeRatio ; if ( msSinceStartScroll > DRAG_SCROLL_ACCELERATION_LIMIT_TIME_MS ) { timeRatio = 1f ; } else { timeRatio = ( float ) msSinceStartScroll / DRAG_SCROLL_ACCELERATION_LIMIT_TIME_MS ; } final int value = ( int ) ( cappedScroll * sDragScrollInterpolator . getInterpolation ( timeRatio ) ) ; if ( value == 0 ) { return viewSizeOutOfBounds > 0 ? 1 : - 1 ; } return value ; }
target:  Called by the ItemTouchHelper when user is dragging a view out of bounds. <p> You can override this method to decide how much RecyclerView should scroll in response to this action. Default implementation calculates a value based on the amount of View out of bounds and the time it spent there. The longer user keeps the View out of bounds, the faster the list will scroll. Similarly, the larger portion of the View is out of bounds, the faster the RecyclerView will scroll.