@Test public void testPutHeader() { final TestModule module = new TestModule(); final int headersCount = 10; for (int i = 0; i < headersCount; i++) { module.putHeader(i, createTestHeader("Header for: " + i)); } assertThat(module.size(), is(headersCount)); }
protected void putHeader(final int position, @NonNull final H header) { this.headers.append(position, header); }
HeadersModule extends AdapterModule { protected void putHeader(final int position, @NonNull final H header) { this.headers.append(position, header); } }
HeadersModule extends AdapterModule { protected void putHeader(final int position, @NonNull final H header) { this.headers.append(position, header); }  }
HeadersModule extends AdapterModule { protected void putHeader(final int position, @NonNull final H header) { this.headers.append(position, header); }  boolean isEmpty(); int size(); boolean isHeaderAt(final int position); @Nullable H getHeader(final int position); @NonNull SparseArray<H> getHeaders(); void clearHeaders(); int correctPosition(final int position); int countHeadersBeforePosition(final int position); void setHeaderStyleAttr(@AttrRes final int styleAttr); @AttrRes int getHeaderStyleAttr(); @NonNull abstract VH createViewHolder(@NonNull ViewGroup parent, int viewType); @NonNull final SimpleHeaderHolder createSimpleHeaderHolder(@NonNull ViewGroup parent); abstract void bindViewHolder(@NonNull VH viewHolder, int position); }
HeadersModule extends AdapterModule { protected void putHeader(final int position, @NonNull final H header) { this.headers.append(position, header); }  boolean isEmpty(); int size(); boolean isHeaderAt(final int position); @Nullable H getHeader(final int position); @NonNull SparseArray<H> getHeaders(); void clearHeaders(); int correctPosition(final int position); int countHeadersBeforePosition(final int position); void setHeaderStyleAttr(@AttrRes final int styleAttr); @AttrRes int getHeaderStyleAttr(); @NonNull abstract VH createViewHolder(@NonNull ViewGroup parent, int viewType); @NonNull final SimpleHeaderHolder createSimpleHeaderHolder(@NonNull ViewGroup parent); abstract void bindViewHolder(@NonNull VH viewHolder, int position);  }