com.cafesoft.core.pool
Class StandardObjectPoolConfig

java.lang.Object
  |
  +--com.cafesoft.core.pool.StandardObjectPoolConfig
All Implemented Interfaces:
Debuggable, ObjectPoolConfig

public class StandardObjectPoolConfig
extends Object
implements ObjectPoolConfig

The standard implementation of the ObjectPoolConfig interface. This implementation is a no frills implementation of the ObjectPoolConfig interface. This implementation serves as a very good base class that all extend ObjectPool configuration objects should extend.

Since:
11/11/03
See Also:
ObjectPoolConfig

Constructor Summary
StandardObjectPoolConfig()
          Create a new StandardObjectPoolConfig object.
StandardObjectPoolConfig(Logger logger)
          Create a new StandardObjectPoolConfig object.
StandardObjectPoolConfig(Logger logger, boolean debug)
          Create a new StandardObjectPoolConfig object.
StandardObjectPoolConfig(Logger logger, String debug)
          Create a new StandardObjectPoolConfig object.
 
Method Summary
 boolean getDebug()
          Determine if debugging is enabled.
 Logger getLogger()
          Get the Logger.
 boolean setDebug(boolean enable)
          Enable or disable debugging.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StandardObjectPoolConfig

public StandardObjectPoolConfig()
Create a new StandardObjectPoolConfig object. This constructor will create a StandardObjectPoolConfig object and will use a StdoutLogger as it's logger and will disable debugging by default.


StandardObjectPoolConfig

public StandardObjectPoolConfig(Logger logger)
Create a new StandardObjectPoolConfig object. This constructor will create a StandardObjectPoolConfig object with the given Logger object and will disable debugging.

Parameters:
logger - the Logger object to use.

StandardObjectPoolConfig

public StandardObjectPoolConfig(Logger logger,
                                String debug)
Create a new StandardObjectPoolConfig object.

Parameters:
logger - the Logger object to use.
debug - a String value that contains a textual version of the boolean value to enable/disable debugging.

StandardObjectPoolConfig

public StandardObjectPoolConfig(Logger logger,
                                boolean debug)
Create a new StandardObjectPoolConfig object.

Parameters:
logger - the Logger object to use.
debug - boolean flag to enable/disable debugging.
Method Detail

getLogger

public Logger getLogger()
Get the Logger.

Specified by:
getLogger in interface ObjectPoolConfig
Returns:
a Logger object used to log all important ObjectPool debug statements.

getDebug

public boolean getDebug()
Determine if debugging is enabled.

Specified by:
getDebug in interface ObjectPoolConfig
Returns:
true if debugging is enabled, false otherwise.

setDebug

public boolean setDebug(boolean enable)
Enable or disable debugging.

Specified by:
setDebug in interface Debuggable
Parameters:
enable - if true, enable debugging, else disable debugging.
Returns:
the previous value of the debug flag, which is useful for restoring the debug state if temporarily changed.


Generated on 8:41:50 AM June 06, 2005, © 1996-2005 Cafésoft LLC. All rights reserved.