public class TableDataContainer<I>
extends java.lang.Object
implements com.vaadin.v7.data.Container, com.vaadin.v7.data.Container.ItemSetChangeNotifier
com.vaadin.v7.data.Container.Editor, com.vaadin.v7.data.Container.Filter, com.vaadin.v7.data.Container.Filterable, com.vaadin.v7.data.Container.Hierarchical, com.vaadin.v7.data.Container.Indexed, com.vaadin.v7.data.Container.ItemSetChangeEvent, com.vaadin.v7.data.Container.ItemSetChangeListener, com.vaadin.v7.data.Container.ItemSetChangeNotifier, com.vaadin.v7.data.Container.Ordered, com.vaadin.v7.data.Container.PropertySetChangeEvent, com.vaadin.v7.data.Container.PropertySetChangeListener, com.vaadin.v7.data.Container.PropertySetChangeNotifier, com.vaadin.v7.data.Container.SimpleFilterable, com.vaadin.v7.data.Container.Sortable, com.vaadin.v7.data.Container.Viewer
Modifier and Type | Field and Description |
---|---|
protected TableItemsEventsDelegate<I> |
dataEventsDelegate |
protected boolean |
ignoreListeners |
protected java.util.Map<java.lang.Object,TableItemWrapper> |
itemsCache |
protected java.util.List<com.vaadin.v7.data.Container.ItemSetChangeListener> |
itemSetChangeListeners |
protected io.jmix.core.common.event.Subscription |
itemSetChangeSubscription |
protected java.util.Collection<java.lang.Object> |
properties |
protected java.util.List<com.vaadin.v7.data.Property.ValueChangeListener> |
propertyValueChangeListeners |
protected io.jmix.core.common.event.Subscription |
selectedItemChangeSubscription |
protected io.jmix.core.common.event.Subscription |
stateChangeSubscription |
protected TableItems<I> |
tableItems |
protected io.jmix.core.common.event.Subscription |
valueChangeSubscription |
protected static com.vaadin.v7.data.Property.ValueChangeEvent |
VOID_VALUE_CHANGE_EVENT |
protected java.util.Queue<TableItemWrapper> |
wrappersPool |
Constructor and Description |
---|
TableDataContainer(TableItems<I> tableItems,
TableItemsEventsDelegate<I> dataEventsDelegate) |
Modifier and Type | Method and Description |
---|---|
boolean |
addContainerProperty(java.lang.Object propertyId,
java.lang.Class<?> type,
java.lang.Object defaultValue) |
java.lang.Object |
addItem() |
com.vaadin.v7.data.Item |
addItem(java.lang.Object itemId) |
void |
addItemSetChangeListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener) |
void |
addListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener) |
void |
addValueChangeListener(com.vaadin.v7.data.Property.ValueChangeListener propertyValueChangeListener) |
protected void |
beforeFireItemSetChanged() |
protected void |
beforeFireStateChanged(BindingState state) |
protected TableItemWrapper |
borrowItemWrapper() |
boolean |
containsId(java.lang.Object itemId) |
protected void |
datasourceItemSetChanged(TableItems.ItemSetChangeEvent<I> e) |
protected void |
datasourceSelectedItemChanged(TableItems.SelectedItemChangeEvent<I> e) |
protected void |
datasourceStateChanged(DataUnit.StateChangeEvent e) |
protected void |
datasourceValueChanged(TableItems.ValueChangeEvent<I> e) |
protected void |
fireItemSetChanged() |
com.vaadin.v7.data.Property |
getContainerProperty(java.lang.Object itemId,
java.lang.Object propertyId) |
java.util.Collection<?> |
getContainerPropertyIds() |
I |
getInternalItem(java.lang.Object itemId) |
com.vaadin.v7.data.Item |
getItem(java.lang.Object itemId) |
java.util.Collection<?> |
getItemIds() |
protected com.vaadin.v7.data.Item |
getItemWrapper(java.lang.Object dataItem,
java.lang.Object itemId) |
protected TableItemWrapper |
getItemWrapperNonCached(java.lang.Object item,
java.lang.Object itemId) |
TableItems<I> |
getTableItems() |
java.lang.Class<?> |
getType(java.lang.Object propertyId) |
boolean |
removeAllItems() |
boolean |
removeContainerProperty(java.lang.Object propertyId) |
boolean |
removeItem(java.lang.Object itemId) |
void |
removeItemSetChangeListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener) |
void |
removeListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener) |
protected void |
resetCachedItems() |
protected void |
returnItemWrapper(TableItemWrapper tableItemWrapper) |
void |
setProperties(java.util.Collection<java.lang.Object> properties) |
int |
size() |
void |
unbind() |
protected static final com.vaadin.v7.data.Property.ValueChangeEvent VOID_VALUE_CHANGE_EVENT
protected TableItems<I> tableItems
protected TableItemsEventsDelegate<I> dataEventsDelegate
protected boolean ignoreListeners
protected java.util.Collection<java.lang.Object> properties
protected java.util.Map<java.lang.Object,TableItemWrapper> itemsCache
protected java.util.Queue<TableItemWrapper> wrappersPool
protected java.util.List<com.vaadin.v7.data.Container.ItemSetChangeListener> itemSetChangeListeners
protected java.util.List<com.vaadin.v7.data.Property.ValueChangeListener> propertyValueChangeListeners
protected io.jmix.core.common.event.Subscription itemSetChangeSubscription
protected io.jmix.core.common.event.Subscription valueChangeSubscription
protected io.jmix.core.common.event.Subscription stateChangeSubscription
protected io.jmix.core.common.event.Subscription selectedItemChangeSubscription
public TableDataContainer(TableItems<I> tableItems, TableItemsEventsDelegate<I> dataEventsDelegate)
public void setProperties(java.util.Collection<java.lang.Object> properties)
public void unbind()
@Nullable public com.vaadin.v7.data.Item getItem(java.lang.Object itemId)
getItem
in interface com.vaadin.v7.data.Container
@Nullable public I getInternalItem(java.lang.Object itemId)
protected com.vaadin.v7.data.Item getItemWrapper(java.lang.Object dataItem, java.lang.Object itemId)
protected TableItemWrapper borrowItemWrapper()
protected void returnItemWrapper(TableItemWrapper tableItemWrapper)
protected TableItemWrapper getItemWrapperNonCached(java.lang.Object item, java.lang.Object itemId)
protected void fireItemSetChanged()
public java.util.Collection<?> getContainerPropertyIds()
getContainerPropertyIds
in interface com.vaadin.v7.data.Container
public java.util.Collection<?> getItemIds()
getItemIds
in interface com.vaadin.v7.data.Container
@Nullable public com.vaadin.v7.data.Property getContainerProperty(java.lang.Object itemId, java.lang.Object propertyId)
getContainerProperty
in interface com.vaadin.v7.data.Container
public java.lang.Class<?> getType(java.lang.Object propertyId)
getType
in interface com.vaadin.v7.data.Container
public int size()
size
in interface com.vaadin.v7.data.Container
public boolean containsId(java.lang.Object itemId)
containsId
in interface com.vaadin.v7.data.Container
public com.vaadin.v7.data.Item addItem(java.lang.Object itemId) throws java.lang.UnsupportedOperationException
addItem
in interface com.vaadin.v7.data.Container
java.lang.UnsupportedOperationException
public java.lang.Object addItem() throws java.lang.UnsupportedOperationException
addItem
in interface com.vaadin.v7.data.Container
java.lang.UnsupportedOperationException
public boolean removeItem(java.lang.Object itemId) throws java.lang.UnsupportedOperationException
removeItem
in interface com.vaadin.v7.data.Container
java.lang.UnsupportedOperationException
public boolean addContainerProperty(java.lang.Object propertyId, java.lang.Class<?> type, java.lang.Object defaultValue) throws java.lang.UnsupportedOperationException
addContainerProperty
in interface com.vaadin.v7.data.Container
java.lang.UnsupportedOperationException
public boolean removeContainerProperty(java.lang.Object propertyId) throws java.lang.UnsupportedOperationException
removeContainerProperty
in interface com.vaadin.v7.data.Container
java.lang.UnsupportedOperationException
public boolean removeAllItems() throws java.lang.UnsupportedOperationException
removeAllItems
in interface com.vaadin.v7.data.Container
java.lang.UnsupportedOperationException
public void addItemSetChangeListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener)
addItemSetChangeListener
in interface com.vaadin.v7.data.Container.ItemSetChangeNotifier
public void addListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener)
addListener
in interface com.vaadin.v7.data.Container.ItemSetChangeNotifier
public void removeItemSetChangeListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener)
removeItemSetChangeListener
in interface com.vaadin.v7.data.Container.ItemSetChangeNotifier
public void removeListener(com.vaadin.v7.data.Container.ItemSetChangeListener listener)
removeListener
in interface com.vaadin.v7.data.Container.ItemSetChangeNotifier
protected void resetCachedItems()
protected void datasourceItemSetChanged(TableItems.ItemSetChangeEvent<I> e)
protected void beforeFireItemSetChanged()
protected void datasourceValueChanged(TableItems.ValueChangeEvent<I> e)
protected void beforeFireStateChanged(BindingState state)
protected void datasourceStateChanged(DataUnit.StateChangeEvent e)
protected void datasourceSelectedItemChanged(TableItems.SelectedItemChangeEvent<I> e)
public TableItems<I> getTableItems()
public void addValueChangeListener(com.vaadin.v7.data.Property.ValueChangeListener propertyValueChangeListener)