- Type Parameters:
FH- the type of the fact handleV- the type of the value associated with the fact handle
- All Known Implementing Classes:
FactStorageWrapper
public interface FactStorage<FH extends FactHandle,V>
A fact storage interface
-
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Clears the memoryRetrieves a fact value by fact handle.voidInserts a fact into the delta storage.Deletes a fact from the memory for bothMemoryScope.DELTAandMemoryScope.MAINscopes.stream()Returns stream of currently stored values.
-
Method Details
-
insert
Inserts a fact into the delta storage.- Parameters:
factHandle- the handle for the fact to be insertedvalue- the value associated with the fact handle
-
remove
Deletes a fact from the memory for bothMemoryScope.DELTAandMemoryScope.MAINscopes.- Parameters:
factHandle- the previously assigned fact handle- Returns:
- the previously existing value, or
nullif no value was associated with the fact handle
-
get
Retrieves a fact value by fact handle.- Parameters:
factHandle- the handle for the fact to be retrieved- Returns:
- the value associated with the fact handle, or null if not found
-
stream
Returns stream of currently stored values.- Returns:
- stream of currently stored mappings.
-
clear
void clear()Clears the memory
-