@Test public void testGetItemIdsRangeIndexOutOfBoundsDueToSizeChange() { IndexedContainer ic = new IndexedContainer(); ic.addItem(new Object()); Assert.assertEquals( "Container returned too many items when the range was >> container size", 1, ic.getItemIds(0, 10).size()); }
@Override public Object addItem() { final Object id = generateId(); addItem(id); return id; }
IndexedContainer extends
        AbstractInMemoryContainer<Object, Object, Item> implements
        Container.PropertySetChangeNotifier, Property.ValueChangeNotifier,
        Container.Sortable, Cloneable, Container.Filterable,
        Container.SimpleFilterable { @Override public Object addItem() { final Object id = generateId(); addItem(id); return id; } }
IndexedContainer extends
        AbstractInMemoryContainer<Object, Object, Item> implements
        Container.PropertySetChangeNotifier, Property.ValueChangeNotifier,
        Container.Sortable, Cloneable, Container.Filterable,
        Container.SimpleFilterable { @Override public Object addItem() { final Object id = generateId(); addItem(id); return id; } IndexedContainer();  IndexedContainer(Collection<?> itemIds); }
IndexedContainer extends
        AbstractInMemoryContainer<Object, Object, Item> implements
        Container.PropertySetChangeNotifier, Property.ValueChangeNotifier,
        Container.Sortable, Cloneable, Container.Filterable,
        Container.SimpleFilterable { @Override public Object addItem() { final Object id = generateId(); addItem(id); return id; } IndexedContainer();  IndexedContainer(Collection<?> itemIds); @Override Collection<?> getContainerPropertyIds(); @Override Class<?> getType(Object propertyId); @Override Property getContainerProperty(Object itemId, Object propertyId); @Override boolean addContainerProperty(Object propertyId, Class<?> type,
            Object defaultValue); @Override boolean removeAllItems(); @Override Object addItem(); @Override Item addItem(Object itemId); @Override boolean removeItem(Object itemId); @Override boolean removeContainerProperty(Object propertyId); @Override Item addItemAfter(Object previousItemId, Object newItemId); @Override Object addItemAfter(Object previousItemId); @Override Item addItemAt(int index, Object newItemId); @Override Object addItemAt(int index); @Override void addPropertySetChangeListener(
            Container.PropertySetChangeListener listener); @Override void removePropertySetChangeListener(
            Container.PropertySetChangeListener listener); @Override void addValueChangeListener(Property.ValueChangeListener listener); @Override void removeValueChangeListener(
            Property.ValueChangeListener listener); @Override Collection<?> getListeners(Class<?> eventType); @Override void sort(Object[] propertyId, boolean[] ascending); @Override Collection<?> getSortableContainerPropertyIds(); @Override ItemSorter getItemSorter(); @Override void setItemSorter(ItemSorter itemSorter); @Deprecated @Override Object clone(); @Override void addContainerFilter(Object propertyId, String filterString,
            boolean ignoreCase, boolean onlyMatchPrefix); @Override void removeAllContainerFilters(); @Override void removeContainerFilters(Object propertyId); @Override void addContainerFilter(Filter filter); @Override void removeContainerFilter(Filter filter); @Override boolean hasContainerFilters(); @Override Collection<Filter> getContainerFilters(); }
IndexedContainer extends
        AbstractInMemoryContainer<Object, Object, Item> implements
        Container.PropertySetChangeNotifier, Property.ValueChangeNotifier,
        Container.Sortable, Cloneable, Container.Filterable,
        Container.SimpleFilterable { @Override public Object addItem() { final Object id = generateId(); addItem(id); return id; } IndexedContainer();  IndexedContainer(Collection<?> itemIds); @Override Collection<?> getContainerPropertyIds(); @Override Class<?> getType(Object propertyId); @Override Property getContainerProperty(Object itemId, Object propertyId); @Override boolean addContainerProperty(Object propertyId, Class<?> type,
            Object defaultValue); @Override boolean removeAllItems(); @Override Object addItem(); @Override Item addItem(Object itemId); @Override boolean removeItem(Object itemId); @Override boolean removeContainerProperty(Object propertyId); @Override Item addItemAfter(Object previousItemId, Object newItemId); @Override Object addItemAfter(Object previousItemId); @Override Item addItemAt(int index, Object newItemId); @Override Object addItemAt(int index); @Override void addPropertySetChangeListener(
            Container.PropertySetChangeListener listener); @Override void removePropertySetChangeListener(
            Container.PropertySetChangeListener listener); @Override void addValueChangeListener(Property.ValueChangeListener listener); @Override void removeValueChangeListener(
            Property.ValueChangeListener listener); @Override Collection<?> getListeners(Class<?> eventType); @Override void sort(Object[] propertyId, boolean[] ascending); @Override Collection<?> getSortableContainerPropertyIds(); @Override ItemSorter getItemSorter(); @Override void setItemSorter(ItemSorter itemSorter); @Deprecated @Override Object clone(); @Override void addContainerFilter(Object propertyId, String filterString,
            boolean ignoreCase, boolean onlyMatchPrefix); @Override void removeAllContainerFilters(); @Override void removeContainerFilters(Object propertyId); @Override void addContainerFilter(Filter filter); @Override void removeContainerFilter(Filter filter); @Override boolean hasContainerFilters(); @Override Collection<Filter> getContainerFilters();  }