mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-18 14:58:47 +00:00
#723 - Breaking API - Change BeanPersistListener to return void rather than boolean for inserted(), updated() and deleted()
This commit is contained in:
1 parent
676f0d7a24
commit
1c162b9b18
4 files changed
+30
-55
No files matched your search
+6
-18
@@ -83,33 +83,21 @@ public class ChainedBeanPersistListener implements BeanPersistListener {
|
||||
}
|
||||
}
|
||||
|
||||
public boolean deleted(Object bean) {
|
||||
boolean notifyCluster = false;
|
||||
public void deleted(Object bean) {
|
||||
for (int i = 0; i < chain.length; i++) {
|
||||
if (chain[i].deleted(bean)) {
|
||||
notifyCluster = true;
|
||||
}
|
||||
chain[i].deleted(bean);
|
||||
}
|
||||
return notifyCluster;
|
||||
}
|
||||
|
||||
public boolean inserted(Object bean) {
|
||||
boolean notifyCluster = false;
|
||||
public void inserted(Object bean) {
|
||||
for (int i = 0; i < chain.length; i++) {
|
||||
if (chain[i].inserted(bean)) {
|
||||
notifyCluster = true;
|
||||
}
|
||||
chain[i].inserted(bean);
|
||||
}
|
||||
return notifyCluster;
|
||||
}
|
||||
|
||||
public boolean updated(Object bean, Set<String> updatedProperties) {
|
||||
boolean notifyCluster = false;
|
||||
public void updated(Object bean, Set<String> updatedProperties) {
|
||||
for (int i = 0; i < chain.length; i++) {
|
||||
if (chain[i].updated(bean, updatedProperties)) {
|
||||
notifyCluster = true;
|
||||
}
|
||||
chain[i].updated(bean, updatedProperties);
|
||||
}
|
||||
return notifyCluster;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user