Examples of LFGlobalObjectiveState


Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

        if (!(obj instanceof LFGlobalObjectiveState)) {
            return false;
        }

        LFGlobalObjectiveState lfGlobalObjectiveState = (LFGlobalObjectiveState) obj;

        long primaryKey = lfGlobalObjectiveState.getPrimaryKey();

        if (getPrimaryKey() == primaryKey) {
            return true;
        } else {
            return false;
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     */
    @Override
    public LFGlobalObjectiveState findByTreeID_First(Integer treeID,
        OrderByComparator orderByComparator)
        throws NoSuchLFGlobalObjectiveStateException, SystemException {
        LFGlobalObjectiveState lfGlobalObjectiveState = fetchByTreeID_First(treeID,
                orderByComparator);

        if (lfGlobalObjectiveState != null) {
            return lfGlobalObjectiveState;
        }
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     */
    @Override
    public LFGlobalObjectiveState findByTreeID_Last(Integer treeID,
        OrderByComparator orderByComparator)
        throws NoSuchLFGlobalObjectiveStateException, SystemException {
        LFGlobalObjectiveState lfGlobalObjectiveState = fetchByTreeID_Last(treeID,
                orderByComparator);

        if (lfGlobalObjectiveState != null) {
            return lfGlobalObjectiveState;
        }
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     */
    @Override
    public LFGlobalObjectiveState[] findByTreeID_PrevAndNext(long id,
        Integer treeID, OrderByComparator orderByComparator)
        throws NoSuchLFGlobalObjectiveStateException, SystemException {
        LFGlobalObjectiveState lfGlobalObjectiveState = findByPrimaryKey(id);

        Session session = null;

        try {
            session = openSession();
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     */
    @Override
    public LFGlobalObjectiveState findByTreeIDAndMapKey(Integer treeID,
        String mapKey)
        throws NoSuchLFGlobalObjectiveStateException, SystemException {
        LFGlobalObjectiveState lfGlobalObjectiveState = fetchByTreeIDAndMapKey(treeID,
                mapKey);

        if (lfGlobalObjectiveState == null) {
            StringBundler msg = new StringBundler(6);

View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

            result = FinderCacheUtil.getResult(FINDER_PATH_FETCH_BY_TREEIDANDMAPKEY,
                    finderArgs, this);
        }

        if (result instanceof LFGlobalObjectiveState) {
            LFGlobalObjectiveState lfGlobalObjectiveState = (LFGlobalObjectiveState) result;

            if (!Validator.equals(treeID, lfGlobalObjectiveState.getTreeID()) ||
                    !Validator.equals(mapKey, lfGlobalObjectiveState.getMapKey())) {
                result = null;
            }
        }

        if (result == null) {
            StringBundler query = new StringBundler(4);

            query.append(_SQL_SELECT_LFGLOBALOBJECTIVESTATE_WHERE);

            if (treeID == null) {
                query.append(_FINDER_COLUMN_TREEIDANDMAPKEY_TREEID_NULL_2);
            } else {
                query.append(_FINDER_COLUMN_TREEIDANDMAPKEY_TREEID_2);
            }

            boolean bindMapKey = false;

            if (mapKey == null) {
                query.append(_FINDER_COLUMN_TREEIDANDMAPKEY_MAPKEY_1);
            } else if (mapKey.equals(StringPool.BLANK)) {
                query.append(_FINDER_COLUMN_TREEIDANDMAPKEY_MAPKEY_3);
            } else {
                bindMapKey = true;

                if (mapKey.equals(StringPool.BLANK)) {
                    query.append(_FINDER_COLUMN_TREEIDANDMAPKEY_MAPKEY_3);
                } else {
                    query.append(_FINDER_COLUMN_TREEIDANDMAPKEY_MAPKEY_2);
                }
            }

            String sql = query.toString();

            Session session = null;

            try {
                session = openSession();

                Query q = session.createQuery(sql);

                QueryPos qPos = QueryPos.getInstance(q);

                if (treeID != null) {
                    qPos.add(treeID.intValue());
                }

                if (bindMapKey) {
                    if (mapKey != null) {
                        qPos.add(mapKey);
                    }
                }

                List<LFGlobalObjectiveState> list = q.list();

                if (list.isEmpty()) {
                    FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_TREEIDANDMAPKEY,
                        finderArgs, list);
                } else {
                    if ((list.size() > 1) && _log.isWarnEnabled()) {
                        _log.warn(
                            "LFGlobalObjectiveStatePersistenceImpl.fetchByTreeIDAndMapKey(Integer, String, boolean) with parameters (" +
                            StringUtil.merge(finderArgs) +
                            ") yields a result set with more than 1 result. This violates the logical unique restriction. There is no order guarantee on which result is returned by this finder.");
                    }

                    LFGlobalObjectiveState lfGlobalObjectiveState = list.get(0);

                    result = lfGlobalObjectiveState;

                    cacheResult(lfGlobalObjectiveState);

                    if ((lfGlobalObjectiveState.getTreeID() != treeID) ||
                            (lfGlobalObjectiveState.getMapKey() == null) ||
                            !lfGlobalObjectiveState.getMapKey().equals(mapKey)) {
                        FinderCacheUtil.putResult(FINDER_PATH_FETCH_BY_TREEIDANDMAPKEY,
                            finderArgs, lfGlobalObjectiveState);
                    }
                }
            } catch (Exception e) {
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     */
    @Override
    public LFGlobalObjectiveState removeByTreeIDAndMapKey(Integer treeID,
        String mapKey)
        throws NoSuchLFGlobalObjectiveStateException, SystemException {
        LFGlobalObjectiveState lfGlobalObjectiveState = findByTreeIDAndMapKey(treeID,
                mapKey);

        return remove(lfGlobalObjectiveState);
    }
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     * @param id the primary key for the new l f global objective state
     * @return the new l f global objective state
     */
    @Override
    public LFGlobalObjectiveState create(long id) {
        LFGlobalObjectiveState lfGlobalObjectiveState = new LFGlobalObjectiveStateImpl();

        lfGlobalObjectiveState.setNew(true);
        lfGlobalObjectiveState.setPrimaryKey(id);

        return lfGlobalObjectiveState;
    }
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

        Session session = null;

        try {
            session = openSession();

            LFGlobalObjectiveState lfGlobalObjectiveState = (LFGlobalObjectiveState) session.get(LFGlobalObjectiveStateImpl.class,
                    primaryKey);

            if (lfGlobalObjectiveState == null) {
                if (_log.isWarnEnabled()) {
                    _log.warn(_NO_SUCH_ENTITY_WITH_PRIMARY_KEY + primaryKey);
View Full Code Here

Examples of com.arcusys.learn.persistence.liferay.model.LFGlobalObjectiveState

     * @throws SystemException if a system exception occurred
     */
    @Override
    public LFGlobalObjectiveState findByPrimaryKey(Serializable primaryKey)
        throws NoSuchLFGlobalObjectiveStateException, SystemException {
        LFGlobalObjectiveState lfGlobalObjectiveState = fetchByPrimaryKey(primaryKey);

        if (lfGlobalObjectiveState == null) {
            if (_log.isWarnEnabled()) {
                _log.warn(_NO_SUCH_ENTITY_WITH_PRIMARY_KEY + primaryKey);
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.