Package org.eclipse.persistence.queries

Examples of org.eclipse.persistence.queries.Cursor


        Closeable closeable = null;
        if (query instanceof JpaQuery) {
            JpaQuery<T> elQuery = (JpaQuery<T>) query;
            elQuery.setHint(QueryHints.RESULT_SET_TYPE, ResultSetType.ForwardOnly);
            elQuery.setHint(QueryHints.SCROLLABLE_CURSOR, true);
            final Cursor cursor = elQuery.getResultCursor();
            closeable = new Closeable() {
                @Override
                public void close() throws IOException {
                    cursor.close();
                }
            };
            iterator = cursor;
        } else {
            iterator = query.getResultList().iterator();
View Full Code Here

TOP

Related Classes of org.eclipse.persistence.queries.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.