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