Package org.drools.ruleunits.api
Interface DataStore<T>
-
- Type Parameters:
T- The type of objects managed by this DataSource.
- All Superinterfaces:
DataSource<T>
public interface DataStore<T> extends DataSource<T>
ADataSourceof mutable data.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.drools.ruleunits.api.DataSource
DataSource.Factory, DataSource.FactoryHolder
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DataHandleadd(T object)Add an object to this DataStore.voidremove(DataHandle handle)Deletes the fact for which the givenDataHandlewas assigned.voidremove(T object)Deletes a fact from this DataStore.voidupdate(DataHandle handle, T object)Updates the fact for which the givenDataHandlewas assigned with the new fact set as the second parameter in this method.-
Methods inherited from interface org.drools.ruleunits.api.DataSource
subscribe
-
-
-
-
Method Detail
-
add
DataHandle add(T object)
Add an object to this DataStore.- Returns:
- The
DataHandleto be further modified
-
update
void update(DataHandle handle, T object)
Updates the fact for which the givenDataHandlewas assigned with the new fact set as the second parameter in this method. It is also possible to optionally specify the set of properties that have been modified.- Parameters:
handle- the FactHandle for the fact to be updated.object- the new value for the fact being updated.
-
remove
void remove(DataHandle handle)
Deletes the fact for which the givenDataHandlewas assigned.- Parameters:
handle- the handle whose fact is to be retracted.
-
remove
void remove(T object)
Deletes a fact from this DataStore.
-
-