org.jboss.ejb3
Class InfinitePool

java.lang.Object
  extended by org.jboss.ejb3.pool.AbstractPool
      extended by org.jboss.ejb3.InfinitePool
All Implemented Interfaces:
Pool

public class InfinitePool
extends AbstractPool

A pool that has no constraints.

Version:
$Revision: 67042 $
Author:
Carlo de Wolf

Field Summary
 
Fields inherited from class org.jboss.ejb3.pool.AbstractPool
container, createCount, injectors, removeCount
 
Constructor Summary
InfinitePool()
           
 
Method Summary
 void destroy()
          Destroy the pool.
 BeanContext<?> get()
          Creates if no object is available in pool.
 BeanContext<?> get(Class[] initTypes, Object[] initValues)
           
 int getAvailableCount()
           
 int getCurrentSize()
           
 int getMaxSize()
           
 void release(BeanContext ctx)
          Put bean back in pool
 void remove(BeanContext ctx)
          Destroy bean.
 void setMaxSize(int maxSize)
           
 
Methods inherited from class org.jboss.ejb3.pool.AbstractPool
create, create, discard, getCreateCount, getRemoveCount, initialize, setInjectors
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InfinitePool

public InfinitePool()
Method Detail

destroy

public void destroy()
Description copied from interface: Pool
Destroy the pool.


get

public BeanContext<?> get()
Description copied from interface: Pool
Creates if no object is available in pool. ejbCreate will be called if created


get

public BeanContext<?> get(Class[] initTypes,
                          Object[] initValues)

getAvailableCount

public int getAvailableCount()

getCurrentSize

public int getCurrentSize()

getMaxSize

public int getMaxSize()

release

public void release(BeanContext ctx)
Description copied from interface: Pool
Put bean back in pool


remove

public void remove(BeanContext ctx)
Description copied from interface: Pool
Destroy bean. ejbRemove callback is executed

Specified by:
remove in interface Pool
Overrides:
remove in class AbstractPool

setMaxSize

public void setMaxSize(int maxSize)
Specified by:
setMaxSize in interface Pool
Specified by:
setMaxSize in class AbstractPool


Copyright © 2009 JBoss, a division of Red Hat, Inc.. All Rights Reserved.