Class DomainDataRegionImpl

  • All Implemented Interfaces:
    org.hibernate.cache.spi.DomainDataRegion, org.hibernate.cache.spi.ExtendedStatisticsSupport, org.hibernate.cache.spi.Region, org.infinispan.hibernate.cache.commons.InfinispanBaseRegion, org.infinispan.hibernate.cache.commons.InfinispanDataRegion, org.infinispan.hibernate.cache.commons.TimeSource

    public class DomainDataRegionImpl
    extends Object
    implements org.hibernate.cache.spi.DomainDataRegion, org.infinispan.hibernate.cache.commons.InfinispanDataRegion
    Since:
    3.5
    Author:
    Chris Bredesen, Galder ZamarreƱo
    • Constructor Detail

      • DomainDataRegionImpl

        public DomainDataRegionImpl​(org.infinispan.AdvancedCache cache,
                                    org.hibernate.cache.cfg.spi.DomainDataRegionConfig config,
                                    InfinispanRegionFactory factory,
                                    org.hibernate.cache.spi.CacheKeysFactory cacheKeysFactory)
    • Method Detail

      • getEntityDataAccess

        public org.hibernate.cache.spi.access.EntityDataAccess getEntityDataAccess​(org.hibernate.metamodel.model.domain.NavigableRole rootEntityRole)
        Specified by:
        getEntityDataAccess in interface org.hibernate.cache.spi.DomainDataRegion
      • getNaturalIdDataAccess

        public org.hibernate.cache.spi.access.NaturalIdDataAccess getNaturalIdDataAccess​(org.hibernate.metamodel.model.domain.NavigableRole rootEntityRole)
        Specified by:
        getNaturalIdDataAccess in interface org.hibernate.cache.spi.DomainDataRegion
      • getCollectionDataAccess

        public org.hibernate.cache.spi.access.CollectionDataAccess getCollectionDataAccess​(org.hibernate.metamodel.model.domain.NavigableRole collectionRole)
        Specified by:
        getCollectionDataAccess in interface org.hibernate.cache.spi.DomainDataRegion
      • getCacheKeysFactory

        public org.hibernate.cache.spi.CacheKeysFactory getCacheKeysFactory()
      • getTombstoneExpiration

        public long getTombstoneExpiration()
        Specified by:
        getTombstoneExpiration in interface org.infinispan.hibernate.cache.commons.InfinispanDataRegion
      • getExpiringMetaParam

        public org.infinispan.functional.MetaParam.MetaLifespan getExpiringMetaParam()
        Specified by:
        getExpiringMetaParam in interface org.infinispan.hibernate.cache.commons.InfinispanDataRegion
      • getComparator

        public Comparator<Object> getComparator​(String subclass)
        Specified by:
        getComparator in interface org.infinispan.hibernate.cache.commons.InfinispanDataRegion
      • runInvalidation

        protected void runInvalidation()
      • destroy

        public void destroy()
                     throws org.infinispan.commons.CacheException
        Specified by:
        destroy in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
        Specified by:
        destroy in interface org.hibernate.cache.spi.Region
        Throws:
        org.infinispan.commons.CacheException
      • config

        public org.hibernate.cache.cfg.spi.DomainDataRegionConfig config()
      • getName

        public String getName()
        Specified by:
        getName in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
        Specified by:
        getName in interface org.hibernate.cache.spi.Region
      • nextTimestamp

        public long nextTimestamp()
        Specified by:
        nextTimestamp in interface org.infinispan.hibernate.cache.commons.TimeSource
      • checkValid

        public boolean checkValid()
        Checks if the region is valid for operations such as storing new data in the region, or retrieving data from the region.
        Specified by:
        checkValid in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
        Returns:
        true if the region is valid, false otherwise
      • clear

        public void clear()
        Specified by:
        clear in interface org.hibernate.cache.spi.Region
      • beginInvalidation

        public void beginInvalidation()
        Specified by:
        beginInvalidation in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
      • endInvalidation

        public void endInvalidation()
        Specified by:
        endInvalidation in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
      • getLastRegionInvalidation

        public long getLastRegionInvalidation()
        Specified by:
        getLastRegionInvalidation in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
      • getCache

        public org.infinispan.AdvancedCache getCache()
        Specified by:
        getCache in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
      • getRegionFactory

        public InfinispanRegionFactory getRegionFactory()
        Specified by:
        getRegionFactory in interface org.hibernate.cache.spi.Region
      • getElementCountInMemory

        public long getElementCountInMemory()
        Specified by:
        getElementCountInMemory in interface org.hibernate.cache.spi.ExtendedStatisticsSupport
        Specified by:
        getElementCountInMemory in interface org.infinispan.hibernate.cache.commons.InfinispanBaseRegion
      • getElementCountOnDisk

        public long getElementCountOnDisk()
        Specified by:
        getElementCountOnDisk in interface org.hibernate.cache.spi.ExtendedStatisticsSupport
      • getSizeInMemory

        public long getSizeInMemory()
        Specified by:
        getSizeInMemory in interface org.hibernate.cache.spi.ExtendedStatisticsSupport