code: public int getItemViewType(@NonNull T items, int position) {
  
          if (items == null) {
              throw new NullPointerException("Items datasource is null!");
          }
  
          int delegatesCount = delegates.size();
          for (int i = 0; i < delegatesCount; i++) {
              AdapterDelegate<T> delegate = delegates.valueAt(i);
              if (delegate.isForViewType(items, position)) {
                  return delegates.keyAt(i);
              }
          }
  
          if (fallbackDelegate != null) {
              return FALLBACK_DELEGATE_VIEW_TYPE;
          }
  
          throw new NullPointerException(
                  "No AdapterDelegate added that matches position=" + position + " in data source");
      }
docs: Must be called from {@link RecyclerView.Adapter#getItemViewType(int)}. Internally it scans all
  the registered {@link AdapterDelegate} and picks the right one to return the ViewType integer.
  
  @param items    Adapter's data source
  @param position the position in adapters data source
  @return the ViewType (integer). Returns {@link #FALLBACK_DELEGATE_VIEW_TYPE} in case that the
  fallback adapter delegate should be used
  @throws NullPointerException if no {@link AdapterDelegate} has been found that is
  responsible for the given data element in data set (No {@link AdapterDelegate} for the given
  ViewType)
  @throws NullPointerException if items is null