throws SystemException {
lfRollupRule = toUnwrappedModel(lfRollupRule);
boolean isNew = lfRollupRule.isNew();
LFRollupRuleModelImpl lfRollupRuleModelImpl = (LFRollupRuleModelImpl) lfRollupRule;
Session session = null;
try {
session = openSession();
if (lfRollupRule.isNew()) {
session.save(lfRollupRule);
lfRollupRule.setNew(false);
} else {
session.merge(lfRollupRule);
}
} catch (Exception e) {
throw processException(e);
} finally {
closeSession(session);
}
FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST_WITH_PAGINATION);
if (isNew || !LFRollupRuleModelImpl.COLUMN_BITMASK_ENABLED) {
FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION);
}
else {
if ((lfRollupRuleModelImpl.getColumnBitmask() &
FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_SEQUENCINGID.getColumnBitmask()) != 0) {
Object[] args = new Object[] {
lfRollupRuleModelImpl.getOriginalSequencingID()
};
FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_SEQUENCINGID,
args);
FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_SEQUENCINGID,
args);
args = new Object[] { lfRollupRuleModelImpl.getSequencingID() };
FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_SEQUENCINGID,
args);
FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_SEQUENCINGID,
args);