Package com.arcusys.learn.persistence.liferay.model.impl

Examples of com.arcusys.learn.persistence.liferay.model.impl.LFQuizQuestionModelImpl


        throws SystemException {
        lfQuizQuestion = toUnwrappedModel(lfQuizQuestion);

        boolean isNew = lfQuizQuestion.isNew();

        LFQuizQuestionModelImpl lfQuizQuestionModelImpl = (LFQuizQuestionModelImpl) lfQuizQuestion;

        Session session = null;

        try {
            session = openSession();

            if (lfQuizQuestion.isNew()) {
                session.save(lfQuizQuestion);

                lfQuizQuestion.setNew(false);
            } else {
                session.merge(lfQuizQuestion);
            }
        } catch (Exception e) {
            throw processException(e);
        } finally {
            closeSession(session);
        }

        FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST_WITH_PAGINATION);

        if (isNew || !LFQuizQuestionModelImpl.COLUMN_BITMASK_ENABLED) {
            FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION);
        }
        else {
            if ((lfQuizQuestionModelImpl.getColumnBitmask() &
                    FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_QUIZID.getColumnBitmask()) != 0) {
                Object[] args = new Object[] {
                        lfQuizQuestionModelImpl.getOriginalQuizId()
                    };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_QUIZID, args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_QUIZID,
                    args);

                args = new Object[] { lfQuizQuestionModelImpl.getQuizId() };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_QUIZID, args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_QUIZID,
                    args);
            }

            if ((lfQuizQuestionModelImpl.getColumnBitmask() &
                    FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_QUIZANDCATEGORY.getColumnBitmask()) != 0) {
                Object[] args = new Object[] {
                        lfQuizQuestionModelImpl.getOriginalQuizId(),
                        lfQuizQuestionModelImpl.getOriginalCategoryId()
                    };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_QUIZANDCATEGORY,
                    args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_QUIZANDCATEGORY,
                    args);

                args = new Object[] {
                        lfQuizQuestionModelImpl.getQuizId(),
                        lfQuizQuestionModelImpl.getCategoryId()
                    };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_QUIZANDCATEGORY,
                    args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_QUIZANDCATEGORY,
View Full Code Here

TOP

Related Classes of com.arcusys.learn.persistence.liferay.model.impl.LFQuizQuestionModelImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.