Interface Processor
-
public interface ProcessorAn interface that provides methods to process a document before writing it into database or after reading from the database.- Since:
- 4.0
- Author:
- Anindya Chatterjee
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default voidprocess(PersistentCollection<?> collection)Processes documents in a persistent collection, updates them,and saves the changes back to the collection.default DocumentprocessAfterRead(Document document)Processes a document after reading from the database.default DocumentprocessBeforeWrite(Document document)Processes a document before writing it into database.
-
-
-
Method Detail
-
processBeforeWrite
default Document processBeforeWrite(Document document)
Processes a document before writing it into database.- Parameters:
document- the document- Returns:
- the document
-
processAfterRead
default Document processAfterRead(Document document)
Processes a document after reading from the database.- Parameters:
document- the document- Returns:
- the document
-
process
default void process(PersistentCollection<?> collection)
Processes documents in a persistent collection, updates them,and saves the changes back to the collection.- Parameters:
collection- the collection to process. It can either be aNitriteCollectionor anObjectRepository.
-
-