Package com.sleepycat.db

Examples of com.sleepycat.db.Cursor


                KeyRange.copy(pkRange.beginKey, privPKey);
                status = doGetSearchBoth(lockMode);
                endOperation(null, status, key, pKey, data);
            } else {
                status = OperationStatus.NOTFOUND;
                Cursor oldCursor = beginOperation();
                try {
                    if (pkRange.beginKey == null || !sortedDups) {
                        status = doGetSearchKey(lockMode);
                    } else {
                        KeyRange.copy(pkRange.beginKey, privPKey);
                        status = doGetSearchBothRange(lockMode);
                        if (status == OperationStatus.SUCCESS &&
                            !pkRange.beginInclusive &&
                            pkRange.compare(privPKey, pkRange.beginKey) == 0) {
                            status = doGetNextDup(lockMode);
                        }
                    }
                    if (status == OperationStatus.SUCCESS &&
                        !pkRange.check(privPKey)) {
                        status = OperationStatus.NOTFOUND;
                    }
                } finally {
                    endOperation(oldCursor, status, key, pKey, data);
                }
            }
        } else if (range.singleKey) {
            KeyRange.copy(range.beginKey, privKey);
            status = doGetSearchKey(lockMode);
            endOperation(null, status, key, pKey, data);
        } else {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                if (range.beginKey == null) {
                    status = doGetFirst(lockMode);
                } else {
                    KeyRange.copy(range.beginKey, privKey);
View Full Code Here


            setParams(key, pKey, data);
            status = doGetLast(lockMode);
            endOperation(null, status, null, null, null);
            return status;
        }
        Cursor oldCursor = beginOperation();
        try {
            if (pkRange != null) {
                KeyRange.copy(range.beginKey, privKey);
                boolean doLast = false;
                if (!sortedDups) {
View Full Code Here

            if (pkRange.endKey == null) {
                status = doGetNextDup(lockMode);
                endOperation(null, status, key, pKey, data);
            } else {
                status = OperationStatus.NOTFOUND;
                Cursor oldCursor = beginOperation();
                try {
                    status = doGetNextDup(lockMode);
                    if (status == OperationStatus.SUCCESS &&
                        !pkRange.checkEnd(privPKey, true)) {
                        status = OperationStatus.NOTFOUND;
                    }
                } finally {
                    endOperation(oldCursor, status, key, pKey, data);
                }
            }
        } else if (range.singleKey) {
            status = doGetNextDup(lockMode);
            endOperation(null, status, key, pKey, data);
        } else {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                status = doGetNext(lockMode);
                if (status == OperationStatus.SUCCESS &&
                    !range.check(privKey)) {
                    status = OperationStatus.NOTFOUND;
View Full Code Here

        }
        if (range.singleKey) {
            status = OperationStatus.NOTFOUND;
        } else {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                status = doGetNextNoDup(lockMode);
                if (status == OperationStatus.SUCCESS &&
                    !range.check(privKey)) {
                    status = OperationStatus.NOTFOUND;
View Full Code Here

            if (pkRange.beginKey == null) {
                status = doGetPrevDup(lockMode);
                endOperation(null, status, key, pKey, data);
            } else {
                status = OperationStatus.NOTFOUND;
                Cursor oldCursor = beginOperation();
                try {
                    status = doGetPrevDup(lockMode);
                    if (status == OperationStatus.SUCCESS &&
                        !pkRange.checkBegin(privPKey, true)) {
                        status = OperationStatus.NOTFOUND;
                    }
                } finally {
                    endOperation(oldCursor, status, key, pKey, data);
                }
            }
        } else if (range.singleKey) {
            status = doGetPrevDup(lockMode);
            endOperation(null, status, key, pKey, data);
        } else {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                status = doGetPrev(lockMode);
                if (status == OperationStatus.SUCCESS &&
                    !range.check(privKey)) {
                    status = OperationStatus.NOTFOUND;
View Full Code Here

        }
        if (range.singleKey) {
            status = OperationStatus.NOTFOUND;
        } else {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                status = doGetPrevNoDup(lockMode);
                if (status == OperationStatus.SUCCESS &&
                    !range.check(privKey)) {
                    status = OperationStatus.NOTFOUND;
View Full Code Here

        }
        if (!range.check(key)) {
            status = OperationStatus.NOTFOUND;
        } else if (pkRange != null) {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                shareData(key, privKey);
                status = doGetSearchKey(lockMode);
                if (status == OperationStatus.SUCCESS &&
                    !pkRange.check(privPKey)) {
View Full Code Here

            setParams(key, pKey, data);
            status = doGetSearchKeyRange(lockMode);
            endOperation(null, status, null, null, null);
            return status;
        }
        Cursor oldCursor = beginOperation();
        try {
            shareData(key, privKey);
            status = doGetSearchKeyRange(lockMode);
            if (status == OperationStatus.SUCCESS &&
                (!range.check(privKey) ||
View Full Code Here

            setParams(key, pKey, data);
            status = doGetSearchBothRange(lockMode);
            endOperation(null, status, null, null, null);
            return status;
        }
        Cursor oldCursor = beginOperation();
        try {
            shareData(key, privKey);
            if (secCursor != null) {
                shareData(pKey, privPKey);
            } else {
View Full Code Here

            setParams(key, pKey, data);
            status = doGetNextDup(lockMode);
            endOperation(null, status, null, null, null);
        } else if (pkRange != null && pkRange.endKey != null) {
            status = OperationStatus.NOTFOUND;
            Cursor oldCursor = beginOperation();
            try {
                status = doGetNextDup(lockMode);
                if (status == OperationStatus.SUCCESS &&
                    !pkRange.checkEnd(privPKey, true)) {
                    status = OperationStatus.NOTFOUND;
View Full Code Here

TOP

Related Classes of com.sleepycat.db.Cursor

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.