Package com.storedobject.ui
Class ReferenceLinkListProvider<T extends StoredObject>
java.lang.Object
com.vaadin.flow.data.provider.AbstractDataProvider<T,com.vaadin.flow.function.SerializablePredicate<T>>
com.vaadin.flow.data.provider.ListDataProvider<T>
com.storedobject.ui.AbstractListProvider<T>
com.storedobject.ui.ObjectListProvider<T>
com.storedobject.ui.ReferenceLinkListProvider<T>
- All Implemented Interfaces:
ResourceOwner
,FilterMethods<T>
,ObjectLoader<T>
,EditableProvider<T>
,ObjectLoader<T>
,ViewFilterSupport<T>
,com.vaadin.flow.data.provider.ConfigurableFilterDataProvider<T,
,com.vaadin.flow.function.SerializablePredicate<T>, com.vaadin.flow.function.SerializablePredicate<T>> com.vaadin.flow.data.provider.DataProvider<T,
,com.vaadin.flow.function.SerializablePredicate<T>> com.vaadin.flow.data.provider.InMemoryDataProvider<T>
,Serializable
,AutoCloseable
public class ReferenceLinkListProvider<T extends StoredObject>
extends ObjectListProvider<T>
implements EditableProvider<T>
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.storedobject.ui.ObjectListProvider
ObjectListProvider.LoadCallBack
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
com.vaadin.flow.shared.Registration
addValueChangeTracker
(BiConsumer<AbstractListProvider<T>, Boolean> tracker) boolean
void
clear()
Clear - remove all entries.boolean
boolean
boolean
boolean
boolean
void
load
(ObjectIterator<T> objects) Load the given instances.void
void
refreshItem
(T item) void
reload()
Reload all entries.int
void
savedAll()
This method should be called to reset the status of all rows after all changes are saved.int
size()
Get the instances count.boolean
boolean
Methods inherited from class com.storedobject.ui.ObjectListProvider
applyFilterPredicate, close, contains, get, getCacheLevel, getData, getEffectiveCondition, getFixedFilter, getId, getLoadFilter, getObjectCount, getResource, indexOf, load, load, setLoadFilter, streamAll, streamFiltered
Methods inherited from class com.storedobject.ui.AbstractListProvider
addDataLoadedListener, fetch, filterView, getDataProvider, getItems, getObjectClass, getViewFilter, setFilter, setSortComparator, size
Methods inherited from class com.vaadin.flow.data.provider.ListDataProvider
getFilter, getSortComparator
Methods inherited from class com.vaadin.flow.data.provider.AbstractDataProvider
addDataProviderListener, addListener, fireEvent, refreshItem
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.vaadin.flow.data.provider.DataProvider
addDataProviderListener, refreshItem, withConfigurableFilter, withConfigurableFilter, withConvertedFilter
Methods inherited from interface com.storedobject.ui.EditableProvider
isSavePending, streamAll
Methods inherited from interface com.storedobject.core.FilterMethods
getFilterCondition, setFilter, setFilter, setFilter, setFilter, setFilter, setFilter, setLoadFilter, setViewFilter, setViewFilter
Methods inherited from interface com.vaadin.flow.data.provider.InMemoryDataProvider
addFilter, addFilter, addFilterByValue, addSortComparator, addSortOrder, clearFilters, filteringBy, filteringBy, filteringByEquals, filteringByPrefix, filteringByPrefix, filteringBySubstring, filteringBySubstring, isInMemory, setFilter, setFilterByValue, setSortOrder
Methods inherited from interface com.storedobject.core.ObjectLoader
applyFilter, canContain, getAllowAny, getLinkType, getMaster, getObjectClass, getOrderBy, isAllowAny, load, load, load, load, load, load, load, load, load, load, load, load, load, load, load, load, load, load, load, load, setLinkType, setLinkType, setMaster, setMaster, setOrderBy, setOrderBy
Methods inherited from interface com.storedobject.ui.ObjectLoader
addDataLoadedListener, clear, getDelegatedLoader, setExtraFilter, setExtraFilter, setFilter, setFilter, setFixedFilter, setFixedFilter, setFixedFilter, setFixedFilter
Methods inherited from interface com.storedobject.ui.util.ViewFilterSupport
configure, configure, configure, configureMatch
-
Constructor Details
-
Method Details
-
isChanged
public boolean isChanged() -
addValueChangeTracker
public com.vaadin.flow.shared.Registration addValueChangeTracker(BiConsumer<AbstractListProvider<T>, Boolean> tracker) - Specified by:
addValueChangeTracker
in interfaceEditableProvider<T extends StoredObject>
-
refreshItem
- Specified by:
refreshItem
in interfacecom.vaadin.flow.data.provider.DataProvider<T extends StoredObject,
com.vaadin.flow.function.SerializablePredicate<T extends StoredObject>> - Overrides:
refreshItem
in classcom.vaadin.flow.data.provider.AbstractDataProvider<T extends StoredObject,
com.vaadin.flow.function.SerializablePredicate<T extends StoredObject>>
-
refreshAll
public void refreshAll()- Specified by:
refreshAll
in interfacecom.vaadin.flow.data.provider.DataProvider<T extends StoredObject,
com.vaadin.flow.function.SerializablePredicate<T extends StoredObject>> - Overrides:
refreshAll
in classAbstractListProvider<T extends StoredObject>
-
size
public int size()Description copied from interface:ObjectLoader
Get the instances count.- Specified by:
size
in interfaceObjectLoader<T extends StoredObject>
- Specified by:
size
in interfaceObjectLoader<T extends StoredObject>
- Returns:
- Count.
-
clear
public void clear()Description copied from interface:ObjectLoader
Clear - remove all entries.- Specified by:
clear
in interfaceEditableProvider<T extends StoredObject>
- Specified by:
clear
in interfaceObjectLoader<T extends StoredObject>
- Overrides:
clear
in classObjectListProvider<T extends StoredObject>
-
reload
public void reload()Description copied from interface:ObjectLoader
Reload all entries.- Specified by:
reload
in interfaceObjectLoader<T extends StoredObject>
- Overrides:
reload
in classObjectListProvider<T extends StoredObject>
-
reload
- Specified by:
reload
in interfaceEditableProvider<T extends StoredObject>
-
append
- Specified by:
append
in interfaceEditableProvider<T extends StoredObject>
-
add
- Specified by:
add
in interfaceEditableProvider<T extends StoredObject>
-
delete
- Specified by:
delete
in interfaceEditableProvider<T extends StoredObject>
-
undelete
- Specified by:
undelete
in interfaceEditableProvider<T extends StoredObject>
-
update
- Specified by:
update
in interfaceEditableProvider<T extends StoredObject>
-
load
Description copied from interface:ObjectLoader
Load the given instances. Current "load filter" if set will be applied. However,ObjectLoader.getOrderBy()
result will be ignored. Also, the value returned byObjectLoader.getAllowAny()
will determine whether instanced of the subclasses to be restricted or not.- Specified by:
load
in interfaceObjectLoader<T extends StoredObject>
- Specified by:
load
in interfaceObjectLoader<T extends StoredObject>
- Overrides:
load
in classObjectListProvider<T extends StoredObject>
- Parameters:
objects
- Objects to be loaded.
-
savedAll
public void savedAll()This method should be called to reset the status of all rows after all changes are saved.- Specified by:
savedAll
in interfaceEditableProvider<T extends StoredObject>
-
isAdded
- Specified by:
isAdded
in interfaceEditableProvider<T extends StoredObject>
-
isDeleted
- Specified by:
isDeleted
in interfaceEditableProvider<T extends StoredObject>
-
isEdited
- Specified by:
isEdited
in interfaceEditableProvider<T extends StoredObject>
-
streamAdded
- Specified by:
streamAdded
in interfaceEditableProvider<T extends StoredObject>
-
streamEdited
- Specified by:
streamEdited
in interfaceEditableProvider<T extends StoredObject>
-
streamDeleted
- Specified by:
streamDeleted
in interfaceEditableProvider<T extends StoredObject>
-