com.cafesoft.core.message
Class MessageDecoderObjectPool

java.lang.Object
  |
  +--com.cafesoft.core.message.MessageDecoderObjectPool

public class MessageDecoderObjectPool
extends Object

An ObjectPool of MessageDecoder Objects

Since:
3/5/02

Constructor Summary
MessageDecoderObjectPool(MessageServiceProvider msp)
          Creates a MessageDecoderObjectPool with the specified MessageServiceProvider.
 
Method Summary
 void close()
          Close the MessageEncoderObjectPool This method closes the ObjectPool and cleans up any dangling references.
 MessageDecoder getMessageDecoder()
          Get a MessageDecoder Object from the ObjectPool
 void initialize(Properties properties)
          Initialize the MessageDecoderObjectPool
 void releaseMessageDecoder(MessageDecoder messageDecoder)
          Returns the specified MessageDecoder to the pool.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageDecoderObjectPool

public MessageDecoderObjectPool(MessageServiceProvider msp)
Creates a MessageDecoderObjectPool with the specified MessageServiceProvider.

Parameters:
msp - provides services needed by the messaging framework
Method Detail

initialize

public void initialize(Properties properties)
                throws LifecycleException
Initialize the MessageDecoderObjectPool

Parameters:
properties - the initialization Properties object
Throws:
LifecycleException - thrown if an error occurs initializing the MessageDecoderObjectPool

getMessageDecoder

public MessageDecoder getMessageDecoder()
                                 throws MessageDecoderException
Get a MessageDecoder Object from the ObjectPool

Returns:
a MessageDecoder Object
Throws:
MessageDecoderException - thrown if an error occurs getting a MessageDecoder Object from the ObjectPool. Typically this will be some sort of Object creation error that occurs.

releaseMessageDecoder

public void releaseMessageDecoder(MessageDecoder messageDecoder)
Returns the specified MessageDecoder to the pool.

Parameters:
messageDecoder - the MessageDecoder to be returned to the ObjectPool
Throws:
IllegalArgumentException - thrown if the MessageDecoder parameter is null. Note: UNCHECKED EXCEPTION

close

public void close()
Close the MessageEncoderObjectPool

This method closes the ObjectPool and cleans up any dangling references.



Generated on 10:40:31 AM September 10, 2003, © 1996-2003 Cafésoft LLC. All rights reserved.