final Persistability persistability = determinePersistability();
this.persistability = persistability;
}
private Persistability determinePersistability() {
final NotPersistableFacet notPersistableFacet = getFacet(NotPersistableFacet.class);
if (notPersistableFacet == null) {
return Persistability.USER_PERSISTABLE;
}
final InitiatedBy initiatedBy = notPersistableFacet.value();
if (initiatedBy == InitiatedBy.USER_OR_PROGRAM) {
return Persistability.TRANSIENT;
} else if (initiatedBy == InitiatedBy.USER) {
return Persistability.PROGRAM_PERSISTABLE;
} else {