EhcacheHibernateMBeanRegistrationImpl (Hibernate JavaDocs)
Date: 2012-04-05

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.hibernate.cache.ehcache.management.impl
Class EhcacheHibernateMBeanRegistrationImpl

    java.lang.Object
      org.hibernate.cache.ehcache.management.impl.EhcacheHibernateMBeanRegistrationImpl

All Implemented Interfaces:
  net.sf.ehcache.event.CacheManagerEventListener, EhcacheHibernateMBeanRegistration

    public class EhcacheHibernateMBeanRegistrationImpl

extends Object
implements EhcacheHibernateMBeanRegistration, net.sf.ehcache.event.CacheManagerEventListener

Implementation of `EhcacheHibernateMBeanRegistration`. Also implements `CacheManagerEventListener`. Deregisters mbeans when the associated cachemanager is shutdown.

Constructor Summary
`EhcacheHibernateMBeanRegistrationImpl()`

Method Summary
`void` | `dispose()`
`void` | `enableHibernateStatisticsSupport(SessionFactory sessionFactory)` Enable hibernate statistics in the mbean.
`net.sf.ehcache.Status` | `getStatus()`
`void` | `init()` No-op in this case
`void` | `notifyCacheAdded(String cacheName)` No-op in this case
`void` | `notifyCacheRemoved(String cacheName)` No-op in this case
`void` | `registerMBeanForCacheManager(net.sf.ehcache.CacheManager manager, Properties properties)` Registers MBean for the input manager and session factory properties.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### EhcacheHibernateMBeanRegistrationImpl

    public EhcacheHibernateMBeanRegistrationImpl()

Method Detail

### registerMBeanForCacheManager

    public void registerMBeanForCacheManager(net.sf.ehcache.CacheManager manager,
                                             Properties properties)
                                      throws Exception

  Registers MBean for the input manager and session factory properties.

  MBeans will be registered based on the input session factory name. If the input name is null or blank, the name of the cache-manager is used

  Specified by:
    `registerMBeanForCacheManager` in interface `EhcacheHibernateMBeanRegistration`
  Throws:
    `Exception`

### enableHibernateStatisticsSupport

    public void enableHibernateStatisticsSupport(SessionFactory sessionFactory)

  Enable hibernate statistics in the mbean.

  Specified by:
    `enableHibernateStatisticsSupport` in interface `EhcacheHibernateMBeanRegistration`

### dispose

    public void dispose()
                 throws net.sf.ehcache.CacheException

  Specified by:
    `dispose` in interface `net.sf.ehcache.event.CacheManagerEventListener`
  Throws:
    `net.sf.ehcache.CacheException`

### getStatus

    public net.sf.ehcache.Status getStatus()

  Specified by:
    `getStatus` in interface `net.sf.ehcache.event.CacheManagerEventListener`

### init

    public void init()
              throws net.sf.ehcache.CacheException

  No-op in this case

  Specified by:
    `init` in interface `net.sf.ehcache.event.CacheManagerEventListener`
  Throws:
    `net.sf.ehcache.CacheException`

### notifyCacheAdded

    public void notifyCacheAdded(String cacheName)

  No-op in this case

  Specified by:
    `notifyCacheAdded` in interface `net.sf.ehcache.event.CacheManagerEventListener`

### notifyCacheRemoved

    public void notifyCacheRemoved(String cacheName)

  No-op in this case

  Specified by:
    `notifyCacheRemoved` in interface `net.sf.ehcache.event.CacheManagerEventListener`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2012 Red Hat, Inc. All Rights Reserved.