Package org.apache.openjpa.datacache

Examples of org.apache.openjpa.datacache.QueryKey


    }

    public long getExecutionCount(String queryKey) {
        QueryStatistics<QueryKey> stats = getStatistics();
        if (stats != null) {
            QueryKey qk = findKey(queryKey);
            return stats.getExecutionCount(qk);
        }
        return NO_STATS;
    }
View Full Code Here


    }

    public long getTotalExecutionCount(String queryKey) {
        QueryStatistics<QueryKey> stats = getStatistics();
        if (stats != null) {
            QueryKey qk = findKey(queryKey);
            return stats.getTotalExecutionCount(qk);
        }
        return NO_STATS;
    }
View Full Code Here

    }

    public long getHitCount(String queryKey) {
        QueryStatistics<QueryKey> stats = getStatistics();
        if (stats != null) {
            QueryKey qk = findKey(queryKey);
            return stats.getHitCount(qk);
        }
        return NO_STATS;
    }
View Full Code Here

    }

    public long getTotalHitCount(String queryKey) {
        QueryStatistics<QueryKey> stats = getStatistics();
        if (stats != null) {
            QueryKey qk = findKey(queryKey);
            return stats.getTotalHitCount(qk);
        }
        return NO_STATS;
    }
View Full Code Here

     * query may have cached results, but they cannot be
     * valid (i.e. they can't be returned to the user)
     */
    static void assertInCache(AbstractTestCase tc, Query query, Boolean inCache,
        Object[] args) {
        QueryKey qk = QueryKey.newInstance(query, args);
        Broker broker = query.getBroker();
        BrokerFactory factory = broker.getBrokerFactory();

        QueryCache qc = cacheManager(factory).getSystemQueryCache();
        if (inCache == Boolean.FALSE && qc.get(qk) != null) {
View Full Code Here

TOP

Related Classes of org.apache.openjpa.datacache.QueryKey

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.