Examples of CacheObjectKey


Examples of com.sun.gjc.spi.base.CacheObjectKey

    public PreparedStatement prepareCachedStatement(
            ConnectionWrapper conWrapper, String sql, int[] columnIndexes)
            throws SQLException {
        if (statementCaching) {
            CacheObjectKey key = new CacheObjectKey(sql,
                    CacheObjectKey.PREPARED_STATEMENT, columnIndexes);
            //TODO-SC should a null check be done for statementCache?
            PreparedStatementWrapper ps =
                    (PreparedStatementWrapper)
                    statementCache.checkAndUpdateCache(key);
View Full Code Here

Examples of com.sun.gjc.spi.base.CacheObjectKey

   
    public PreparedStatement prepareCachedStatement(
            ConnectionWrapper conWrapper, String sql, int autoGeneratedKeys)
            throws SQLException {
        if (statementCaching) {
            CacheObjectKey key = new CacheObjectKey(sql,
                    CacheObjectKey.PREPARED_STATEMENT, autoGeneratedKeys);
            //TODO-SC should a null check be done for statementCache?
            PreparedStatementWrapper ps =
                    (PreparedStatementWrapper)
                    statementCache.checkAndUpdateCache(key);
View Full Code Here

Examples of com.sun.gjc.spi.base.CacheObjectKey

    public CallableStatement prepareCachedCallableStatement(
           ConnectionWrapper conWrapper, String sql, int resultSetType,
           int resultSetConcurrency) throws SQLException {
        if (statementCaching) {
            //Adding the sql as well as the Statement type "CS" to the CacheObjectKey object
            CacheObjectKey key = new CacheObjectKey(sql,
                    CacheObjectKey.CALLABLE_STATEMENT, resultSetType, resultSetConcurrency);
            CallableStatementWrapper cs =
                    (CallableStatementWrapper)
                    statementCache.checkAndUpdateCache(key);
            //TODO-SC-DEFER can the usability (isFree()) check be done by the cache
View Full Code Here

Examples of com.sun.gjc.spi.base.CacheObjectKey

    public CallableStatement prepareCachedCallableStatement(
           ConnectionWrapper conWrapper, String sql, int resultSetType,
           int resultSetConcurrency, int resultSetHoldability) throws SQLException {
        if (statementCaching) {
            //Adding the sql as well as the Statement type "CS" to the CacheObjectKey object
            CacheObjectKey key = new CacheObjectKey(sql,
                    CacheObjectKey.CALLABLE_STATEMENT, resultSetType,
                    resultSetConcurrency, resultSetHoldability);
            CallableStatementWrapper cs =
                    (CallableStatementWrapper)
                    statementCache.checkAndUpdateCache(key);
View Full Code Here

Examples of com.sun.gjc.spi.base.CacheObjectKey

    }

    public void purge() {
        Iterator keyIterator = list.keySet().iterator();
        while(keyIterator.hasNext()){
            CacheObjectKey key = (CacheObjectKey)keyIterator.next();
            CacheEntry entry = list.get(key);
            try{
                //TODO Move to a more generic Contract and invoke close()
                //PreparedStatementWrapper could implement the contract instead
                PreparedStatementWrapper ps = (PreparedStatementWrapper)entry.entryObj;
View Full Code Here

Examples of com.sun.gjc.spi.base.CacheObjectKey

    // Used only for purging the bad statements.
    public void purge(Object obj) {
        PreparedStatementWrapper tmpPS = (PreparedStatementWrapper) obj;
        Iterator keyIterator = list.keySet().iterator();
        while(keyIterator.hasNext()){
            CacheObjectKey key = (CacheObjectKey)keyIterator.next();
            CacheEntry entry = list.get(key);
            try{
                //TODO Move to a more generic Contract and invoke close()
                //PreparedStatementWrapper could implement the contract instead
                PreparedStatementWrapper ps = (PreparedStatementWrapper)entry.entryObj;
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.