@Test public void testGetCountOnEmptyWrapper() { final AdapterWrapper wrapper = new AdapterWrapper(null); assertThat(wrapper.getCount(), is(0)); }
@Override public int getCount() { return adapter == null ? 0 : adapter.getCount(); }
AdapterWrapper implements WrapperListAdapter { @Override public int getCount() { return adapter == null ? 0 : adapter.getCount(); } }
AdapterWrapper implements WrapperListAdapter { @Override public int getCount() { return adapter == null ? 0 : adapter.getCount(); } AdapterWrapper(@Nullable final ListAdapter adapter); }
AdapterWrapper implements WrapperListAdapter { @Override public int getCount() { return adapter == null ? 0 : adapter.getCount(); } AdapterWrapper(@Nullable final ListAdapter adapter); @Override @Nullable ListAdapter getWrappedAdapter(); @Override void registerDataSetObserver(@NonNull final DataSetObserver observer); @Override void unregisterDataSetObserver(@NonNull final DataSetObserver observer); @Override boolean isEmpty(); @Override int getCount(); @Override @Nullable Object getItem(final int position); @Override boolean hasStableIds(); @Override long getItemId(final int position); @Override int getViewTypeCount(); @Override int getItemViewType(final int position); @Override View getView(final int position, @Nullable final View convertView, @NonNull final ViewGroup parent); @Override boolean areAllItemsEnabled(); @Override boolean isEnabled(final int position); }
AdapterWrapper implements WrapperListAdapter { @Override public int getCount() { return adapter == null ? 0 : adapter.getCount(); } AdapterWrapper(@Nullable final ListAdapter adapter); @Override @Nullable ListAdapter getWrappedAdapter(); @Override void registerDataSetObserver(@NonNull final DataSetObserver observer); @Override void unregisterDataSetObserver(@NonNull final DataSetObserver observer); @Override boolean isEmpty(); @Override int getCount(); @Override @Nullable Object getItem(final int position); @Override boolean hasStableIds(); @Override long getItemId(final int position); @Override int getViewTypeCount(); @Override int getItemViewType(final int position); @Override View getView(final int position, @Nullable final View convertView, @NonNull final ViewGroup parent); @Override boolean areAllItemsEnabled(); @Override boolean isEnabled(final int position);  }