Interface ReactiveBeforeSaveCallback<T>
- All Superinterfaces:
EntityCallback<T>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Entity callback triggered before save of a row.
- Since:
- 2.2
- Author:
- Mark Paluch
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionorg.reactivestreams.Publisher<T>
onBeforeSave
(T entity, com.datastax.oss.driver.api.core.CqlIdentifier tableName, com.datastax.oss.driver.api.core.cql.Statement<?> statement) Entity callback method invoked before a domain object is saved.
-
Method Details
-
onBeforeSave
org.reactivestreams.Publisher<T> onBeforeSave(T entity, com.datastax.oss.driver.api.core.CqlIdentifier tableName, com.datastax.oss.driver.api.core.cql.Statement<?> statement) Entity callback method invoked before a domain object is saved. Can return either the same of a modified instance of the domain object and can modifyStatement
contents. This method is called after converting theentity
toStatement
so effectively the row is used as outcome of invoking this callback.- Parameters:
entity
- the domain object to save.tableName
- name of the table.statement
-Statement
representing theentity
operation.- Returns:
- a
Publisher
emitting the domain object to be persisted.
-