Package javax.persistence

Examples of javax.persistence.CacheRetrieveMode


     * @param properties
     */
    private void configureCurrentCacheModes(FetchPlan fetch, Map<String, Object> properties) {
        if (properties == null)
            return;
        CacheRetrieveMode rMode = JPAProperties.getEnumValue(CacheRetrieveMode.class,
                JPAProperties.CACHE_RETRIEVE_MODE, properties);
        if (rMode != null) {
            fetch.setCacheRetrieveMode(JPAProperties.convertToKernelValue(DataCacheRetrieveMode.class,
                    JPAProperties.CACHE_RETRIEVE_MODE, rMode));
            properties.remove(JPAProperties.CACHE_RETRIEVE_MODE);
View Full Code Here


      session.setCacheMode( previousCacheMode );
    }
  }

  public CacheMode determineAppropriateLocalCacheMode(Map<String, Object> localProperties) {
    CacheRetrieveMode retrieveMode = null;
    CacheStoreMode storeMode = null;
    if ( localProperties != null ) {
      retrieveMode = determineCacheRetrieveMode( localProperties );
      storeMode = determineCacheStoreMode( localProperties );
    }
View Full Code Here

      }
      else if ( HINT_FLUSH_MODE.equals( hintName ) ) {
        applied = applyFlushModeHint( ConfigurationHelper.getFlushMode( value ) );
      }
      else if ( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE.equals( hintName ) ) {
        final CacheRetrieveMode retrieveMode = (CacheRetrieveMode) value;

        CacheStoreMode storeMode = hints != null
            ? (CacheStoreMode) hints.get( AvailableSettings.SHARED_CACHE_STORE_MODE )
            : null;
        if ( storeMode == null ) {
          storeMode = (CacheStoreMode) entityManager.getProperties().get( AvailableSettings.SHARED_CACHE_STORE_MODE );
        }
        applied = applyCacheModeHint( CacheModeHelper.interpretCacheMode( storeMode, retrieveMode ) );
      }
      else if ( AvailableSettings.SHARED_CACHE_STORE_MODE.equals( hintName ) ) {
        final CacheStoreMode storeMode = (CacheStoreMode) value;

        CacheRetrieveMode retrieveMode = hints != null
            ? (CacheRetrieveMode) hints.get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE )
            : null;
        if ( retrieveMode == null ) {
          retrieveMode = (CacheRetrieveMode) entityManager.getProperties().get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE );
        }
View Full Code Here

      getSession().setCacheMode( previousCacheMode );
    }
  }

  public CacheMode determineAppropriateLocalCacheMode(Map<String, Object> localProperties) {
    CacheRetrieveMode retrieveMode = null;
    CacheStoreMode storeMode = null;
    if ( localProperties != null ) {
      retrieveMode = determineCacheRetrieveMode( localProperties );
      storeMode = determineCacheStoreMode( localProperties );
    }
View Full Code Here

      getSession().setCacheMode( previousCacheMode );
    }
  }

  public CacheMode determineAppropriateLocalCacheMode(Map<String, Object> localProperties) {
    CacheRetrieveMode retrieveMode = null;
    CacheStoreMode storeMode = null;
    if ( localProperties != null ) {
      retrieveMode = determineCacheRetrieveMode( localProperties );
      storeMode = determineCacheStoreMode( localProperties );
    }
View Full Code Here

      }
      else if ( HINT_FLUSH_MODE.equals( hintName ) ) {
        applyFlushMode( ConfigurationHelper.getFlushMode( value ) );
      }
      else if ( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE.equals( hintName ) ) {
        final CacheRetrieveMode retrieveMode = (CacheRetrieveMode) value;

        CacheStoreMode storeMode = hints != null
            ? (CacheStoreMode) hints.get( AvailableSettings.SHARED_CACHE_STORE_MODE )
            : null;
        if ( storeMode == null ) {
          storeMode = (CacheStoreMode) entityManager.getProperties()
              .get( AvailableSettings.SHARED_CACHE_STORE_MODE );
        }
        applyCacheMode(
            CacheModeHelper.interpretCacheMode( storeMode, retrieveMode )
        );
      }
      else if ( AvailableSettings.SHARED_CACHE_STORE_MODE.equals( hintName ) ) {
        final CacheStoreMode storeMode = (CacheStoreMode) value;

        CacheRetrieveMode retrieveMode = hints != null
            ? (CacheRetrieveMode) hints.get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE )
            : null;
        if ( retrieveMode == null ) {
          retrieveMode = (CacheRetrieveMode) entityManager.getProperties()
              .get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE );
View Full Code Here

      }
      else if ( HINT_FLUSH_MODE.equals( hintName ) ) {
        applyFlushMode( ConfigurationHelper.getFlushMode( value ) );
      }
      else if ( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE.equals( hintName ) ) {
        final CacheRetrieveMode retrieveMode = (CacheRetrieveMode) value;

        CacheStoreMode storeMode = hints != null
            ? (CacheStoreMode) hints.get( AvailableSettings.SHARED_CACHE_STORE_MODE )
            : null;
        if ( storeMode == null ) {
          storeMode = (CacheStoreMode) entityManager.getProperties()
              .get( AvailableSettings.SHARED_CACHE_STORE_MODE );
        }
        applyCacheMode(
            CacheModeHelper.interpretCacheMode( storeMode, retrieveMode )
        );
      }
      else if ( AvailableSettings.SHARED_CACHE_STORE_MODE.equals( hintName ) ) {
        final CacheStoreMode storeMode = (CacheStoreMode) value;

        CacheRetrieveMode retrieveMode = hints != null
            ? (CacheRetrieveMode) hints.get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE )
            : null;
        if ( retrieveMode == null ) {
          retrieveMode = (CacheRetrieveMode) entityManager.getProperties()
              .get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE );
View Full Code Here

      getSession().setCacheMode( previousCacheMode );
    }
  }

  public CacheMode determineAppropriateLocalCacheMode(Map<String, Object> localProperties) {
    CacheRetrieveMode retrieveMode = null;
    CacheStoreMode storeMode = null;
    if ( localProperties != null ) {
      retrieveMode = determineCacheRetrieveMode( localProperties );
      storeMode = determineCacheStoreMode( localProperties );
    }
View Full Code Here

      }
      else if ( HINT_FLUSH_MODE.equals( hintName ) ) {
        applyFlushMode( ConfigurationHelper.getFlushMode( value ) );
      }
      else if ( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE.equals( hintName ) ) {
        final CacheRetrieveMode retrieveMode = (CacheRetrieveMode) value;

        CacheStoreMode storeMode = hints != null
            ? (CacheStoreMode) hints.get( AvailableSettings.SHARED_CACHE_STORE_MODE )
            : null;
        if ( storeMode == null ) {
          storeMode = (CacheStoreMode) entityManager.getProperties()
              .get( AvailableSettings.SHARED_CACHE_STORE_MODE );
        }
        applyCacheMode(
            CacheModeHelper.interpretCacheMode( storeMode, retrieveMode )
        );
      }
      else if ( AvailableSettings.SHARED_CACHE_STORE_MODE.equals( hintName ) ) {
        final CacheStoreMode storeMode = (CacheStoreMode) value;

        CacheRetrieveMode retrieveMode = hints != null
            ? (CacheRetrieveMode) hints.get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE )
            : null;
        if ( retrieveMode == null ) {
          retrieveMode = (CacheRetrieveMode) entityManager.getProperties()
              .get( AvailableSettings.SHARED_CACHE_RETRIEVE_MODE );
View Full Code Here

      getSession().setCacheMode( previousCacheMode );
    }
  }

  public CacheMode determineAppropriateLocalCacheMode(Map<String, Object> localProperties) {
    CacheRetrieveMode retrieveMode = null;
    CacheStoreMode storeMode = null;
    if ( localProperties != null ) {
      retrieveMode = determineCacheRetrieveMode( localProperties );
      storeMode = determineCacheStoreMode( localProperties );
    }
View Full Code Here

TOP

Related Classes of javax.persistence.CacheRetrieveMode

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.