Package io.jmix.samples.rest.service
Class TestInMemoryDataStore
java.lang.Object
io.jmix.samples.rest.service.TestInMemoryDataStore
- All Implemented Interfaces:
DataStore
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
long
getCount
(LoadContext<?> context) Returns the number of entity instances for the given query passed in theLoadContext
.long
getCount
(ValueLoadContext context) Returns the number of key-value pairs for the given query passed in theValueLoadContext
.getName()
This data store instance name with which it is registered inStores
.load
(LoadContext<?> context) Loads a single entity instance.loadList
(LoadContext<?> context) Loads collection of entity instances.loadValues
(ValueLoadContext context) Loads list of key-value pairs.save
(SaveContext context) Saves a collection of entity instances.void
Sets this data store instance name with which it is registered inStores
.
-
Constructor Details
-
TestInMemoryDataStore
public TestInMemoryDataStore()
-
-
Method Details
-
getName
Description copied from interface:DataStore
This data store instance name with which it is registered inStores
. -
setName
Description copied from interface:DataStore
Sets this data store instance name with which it is registered inStores
. -
load
Description copied from interface:DataStore
Loads a single entity instance. -
loadList
Description copied from interface:DataStore
Loads collection of entity instances. -
getCount
Description copied from interface:DataStore
Returns the number of entity instances for the given query passed in theLoadContext
. -
save
Description copied from interface:DataStore
Saves a collection of entity instances. -
loadValues
Description copied from interface:DataStore
Loads list of key-value pairs.- Specified by:
loadValues
in interfaceDataStore
- Parameters:
context
- defines a query for scalar values and a list of keys for returned KeyValueEntity- Returns:
- list of KeyValueEntity instances
-
getCount
Description copied from interface:DataStore
Returns the number of key-value pairs for the given query passed in theValueLoadContext
. -
clear
public void clear()
-