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

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


            FinderCacheUtil.putResult(FINDER_PATH_COUNT_BY_REFID, args,
                Long.valueOf(1));
            FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_REFID, args,
                lfPackage);
        } else {
            LFPackageModelImpl lfPackageModelImpl = (LFPackageModelImpl) lfPackage;

            if ((lfPackageModelImpl.getColumnBitmask() &
                    FINDER_PATH_FETCH_BY_REFID.getColumnBitmask()) != 0) {
                Object[] args = new Object[] { lfPackage.getAssetRefID() };

                FinderCacheUtil.putResult(FINDER_PATH_COUNT_BY_REFID, args,
                    Long.valueOf(1));
View Full Code Here


            }
        }
    }

    protected void clearUniqueFindersCache(LFPackage lfPackage) {
        LFPackageModelImpl lfPackageModelImpl = (LFPackageModelImpl) lfPackage;

        Object[] args = new Object[] { lfPackage.getAssetRefID() };

        FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_REFID, args);
        FinderCacheUtil.removeResult(FINDER_PATH_FETCH_BY_REFID, args);

        if ((lfPackageModelImpl.getColumnBitmask() &
                FINDER_PATH_FETCH_BY_REFID.getColumnBitmask()) != 0) {
            args = new Object[] { lfPackageModelImpl.getOriginalAssetRefID() };

            FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_REFID, args);
            FinderCacheUtil.removeResult(FINDER_PATH_FETCH_BY_REFID, args);
        }
    }
View Full Code Here

        throws SystemException {
        lfPackage = toUnwrappedModel(lfPackage);

        boolean isNew = lfPackage.isNew();

        LFPackageModelImpl lfPackageModelImpl = (LFPackageModelImpl) lfPackage;

        Session session = null;

        try {
            session = openSession();

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

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

        FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST_WITH_PAGINATION);

        if (isNew || !LFPackageModelImpl.COLUMN_BITMASK_ENABLED) {
            FinderCacheUtil.clearCache(FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION);
        }
        else {
            if ((lfPackageModelImpl.getColumnBitmask() &
                    FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_INSTANCE.getColumnBitmask()) != 0) {
                Object[] args = new Object[] {
                        lfPackageModelImpl.getOriginalCourseID()
                    };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_INSTANCE, args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_INSTANCE,
                    args);

                args = new Object[] { lfPackageModelImpl.getCourseID() };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_INSTANCE, args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_INSTANCE,
                    args);
            }

            if ((lfPackageModelImpl.getColumnBitmask() &
                    FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_COURSEID.getColumnBitmask()) != 0) {
                Object[] args = new Object[] {
                        lfPackageModelImpl.getOriginalCourseID()
                    };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_COURSEID, args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_COURSEID,
                    args);

                args = new Object[] { lfPackageModelImpl.getCourseID() };

                FinderCacheUtil.removeResult(FINDER_PATH_COUNT_BY_COURSEID, args);
                FinderCacheUtil.removeResult(FINDER_PATH_WITHOUT_PAGINATION_FIND_BY_COURSEID,
                    args);
            }
View Full Code Here

TOP

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

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.