com.here.msdkui.routing

## Class WaypointListAdapter

- java.lang.Object
- - androidx.recyclerview.widget.RecyclerView.Adapter<WaypointListAdapter.WaypointsListViewHolder>
  - - com.here.msdkui.routing.WaypointListAdapter

-     public class WaypointListAdapter
      extends androidx.recyclerview.widget.RecyclerView.Adapter<WaypointListAdapter.WaypointsListViewHolder>

  An adapter class that acts as a bridge between a `WaypointEntry` list and the `WaypointListAdapter.WaypointsListViewHolder` views that will be shown in a `WaypointList`.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `class` | `WaypointListAdapter.WaypointsListViewHolder` The view holder used for this adapter.

    - ### Nested classes/interfaces inherited from class androidx.recyclerview.widget.RecyclerView.Adapter

      `androidx.recyclerview.widget.RecyclerView.Adapter.StateRestorationPolicy`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `WaypointListAdapter(java.util.List<WaypointEntry> entries)` Constructs a new instance using a list of `WaypointEntry` elements.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `getItemCount()`
    `void` | `onAttachedToRecyclerView(androidx.recyclerview.widget.RecyclerView recyclerView)`
    `void` | `onBindViewHolder(WaypointListAdapter.WaypointsListViewHolder holder, int position)`
    `WaypointListAdapter.WaypointsListViewHolder` | `onCreateViewHolder(android.view.ViewGroup parent, int viewType)`
    `void` | `setListener(WaypointList.Listener listener)` Sets a listener to get notified on user interactions done on the `WaypointList`.

    - ### Methods inherited from class androidx.recyclerview.widget.RecyclerView.Adapter

      `bindViewHolder, createViewHolder, findRelativeAdapterPositionIn, getItemId, getItemViewType, getStateRestorationPolicy, hasObservers, hasStableIds, notifyDataSetChanged, notifyItemChanged, notifyItemChanged, notifyItemInserted, notifyItemMoved, notifyItemRangeChanged, notifyItemRangeChanged, notifyItemRangeInserted, notifyItemRangeRemoved, notifyItemRemoved, onBindViewHolder, onDetachedFromRecyclerView, onFailedToRecycleView, onViewAttachedToWindow, onViewDetachedFromWindow, onViewRecycled, registerAdapterDataObserver, setHasStableIds, setStateRestorationPolicy, unregisterAdapterDataObserver`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### WaypointListAdapter

          public WaypointListAdapter(@NonNull
                                     java.util.List<WaypointEntry> entries)

      Constructs a new instance using a list of `WaypointEntry` elements.
      Parameters:
        `entries` - a list of `WaypointEntry` objects.

  - ### Method Detail

    - #### onAttachedToRecyclerView

          public void onAttachedToRecyclerView(androidx.recyclerview.widget.RecyclerView recyclerView)

      Overrides:
        `onAttachedToRecyclerView` in class `androidx.recyclerview.widget.RecyclerView.Adapter<WaypointListAdapter.WaypointsListViewHolder>`

    - #### getItemCount

          public int getItemCount()

      Specified by:
        `getItemCount` in class `androidx.recyclerview.widget.RecyclerView.Adapter<WaypointListAdapter.WaypointsListViewHolder>`

    - #### onCreateViewHolder

          public WaypointListAdapter.WaypointsListViewHolder onCreateViewHolder(android.view.ViewGroup parent,
                                                                                int viewType)

      Specified by:
        `onCreateViewHolder` in class `androidx.recyclerview.widget.RecyclerView.Adapter<WaypointListAdapter.WaypointsListViewHolder>`

    - #### onBindViewHolder

          public void onBindViewHolder(WaypointListAdapter.WaypointsListViewHolder holder,
                                       int position)

      Specified by:
        `onBindViewHolder` in class `androidx.recyclerview.widget.RecyclerView.Adapter<WaypointListAdapter.WaypointsListViewHolder>`

    - #### setListener

          public void setListener(WaypointList.Listener listener)

      Sets a listener to get notified on user interactions done on the `WaypointList`.
      Parameters:
        `listener` - the listener to set.