ehcache

net.sf.ehcache.transaction.manager.selector
Class JndiSelector

java.lang.Object
  extended by net.sf.ehcache.transaction.manager.selector.Selector
      extended by net.sf.ehcache.transaction.manager.selector.JndiSelector
Direct Known Subclasses:
GenericJndiSelector, GlassfishSelector

public abstract class JndiSelector
extends Selector

Abstract selector performing JNDI lookup

Author:
Ludovic Orban

Constructor Summary
JndiSelector(String vendor, String jndiName)
          Constructor
 
Method Summary
protected  TransactionManager doLookup()
          Lookup the transaction manager.
 String getJndiName()
          Get the configured JNDI name to look up
 void setJndiName(String jndiName)
          Set the configured JNDI name to look up
 
Methods inherited from class net.sf.ehcache.transaction.manager.selector.Selector
getTransactionManager, getVendor, registerResource, unregisterResource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JndiSelector

public JndiSelector(String vendor,
                    String jndiName)
Constructor

Parameters:
vendor - the transaction manager vendor name
jndiName - the JNDI name to look up
Method Detail

getJndiName

public String getJndiName()
Get the configured JNDI name to look up

Returns:
the JNDI name to look up

setJndiName

public void setJndiName(String jndiName)
Set the configured JNDI name to look up

Parameters:
jndiName - the JNDI name to look up

doLookup

protected TransactionManager doLookup()
Lookup the transaction manager.

Specified by:
doLookup in class Selector
Returns:
the transaction manager, or null if it could not be looked up.

ehcache

Copyright 2001-2016, Terracotta, Inc.