org.jboss.hibernate.cache
Class DeployedTreeCacheProvider

java.lang.Object
  extended by org.jboss.hibernate.cache.DeployedTreeCacheProvider
All Implemented Interfaces:
org.hibernate.cache.CacheProvider

public class DeployedTreeCacheProvider
extends Object
implements org.hibernate.cache.CacheProvider

A Hibernate CacheProvider implementation which knows how to obtain a deployed JBossCache via its JMX ObjectName.

Version:
$Revision: 57193 $
Author:
Steve Ebersole

Field Summary
static String DEFAULT_OBJECT_NAME
           
static String OBJECT_NAME_PROP
           
 
Constructor Summary
DeployedTreeCacheProvider()
           
 
Method Summary
 org.hibernate.cache.Cache buildCache(String name, Properties properties)
          Called by Hibernate in order to build the given named cache "region".
 boolean isMinimalPutsEnabledByDefault()
           
 long nextTimestamp()
           
 void start(Properties properties)
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OBJECT_NAME_PROP

public static final String OBJECT_NAME_PROP
See Also:
Constant Field Values

DEFAULT_OBJECT_NAME

public static final String DEFAULT_OBJECT_NAME
See Also:
Constant Field Values
Constructor Detail

DeployedTreeCacheProvider

public DeployedTreeCacheProvider()
Method Detail

start

public void start(Properties properties)
           throws org.hibernate.cache.CacheException
Specified by:
start in interface org.hibernate.cache.CacheProvider
Throws:
org.hibernate.cache.CacheException

stop

public void stop()
Specified by:
stop in interface org.hibernate.cache.CacheProvider

isMinimalPutsEnabledByDefault

public boolean isMinimalPutsEnabledByDefault()
Specified by:
isMinimalPutsEnabledByDefault in interface org.hibernate.cache.CacheProvider

buildCache

public org.hibernate.cache.Cache buildCache(String name,
                                            Properties properties)
                                     throws org.hibernate.cache.CacheException
Called by Hibernate in order to build the given named cache "region".

Specified by:
buildCache in interface org.hibernate.cache.CacheProvider
Parameters:
name - The cache "region" name.
properties - The configuration properties.
Returns:
The constructed Cache wrapper around the jndi-deployed TreeCache.
Throws:
org.hibernate.cache.CacheException - Generally indicates a problem locating the TreeCache.

nextTimestamp

public long nextTimestamp()
Specified by:
nextTimestamp in interface org.hibernate.cache.CacheProvider


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.