Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

Connection_Recycling_Strategy.h

Go to the documentation of this file.
00001 /* -*- C++ -*- */
00002 
00003 //=============================================================================
00004 /**
00005  *  @file   Connection_Recycling_Strategy.h
00006  *
00007  *  $Id: Connection_Recycling_Strategy.h,v 1.1.1.1 2003/02/21 18:36:32 chad Exp $
00008  *
00009  *  @author Doug Schmidt
00010  */
00011 //=============================================================================
00012 #ifndef ACE_CONNECTION_RECYCLING_STRATEGY_H
00013 #define ACE_CONNECTION_RECYCLING_STRATEGY_H
00014 #include "ace/pre.h"
00015 
00016 #include "ace/Recyclable.h"
00017 
00018 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00019 # pragma once
00020 #endif /* ACE_LACKS_PRAGMA_ONCE */
00021 
00022 
00023 
00024 
00025 /**
00026  * @class ACE_Connection_Recycling_Strategy
00027  *
00028  * @brief Defines the interface for a connection recycler.
00029  */
00030 
00031 class ACE_Export ACE_Connection_Recycling_Strategy
00032 {
00033 public:
00034   /// Virtual Destructor
00035   virtual ~ACE_Connection_Recycling_Strategy (void);
00036 
00037   /// Remove from cache.
00038   virtual int purge (const void *recycling_act) = 0;
00039 
00040   /// Add to cache.
00041   virtual int cache (const void *recycling_act) = 0;
00042 
00043   virtual int recycle_state (const void *recycling_act,
00044                              ACE_Recyclable_State new_state) = 0;
00045 
00046   /// Get/Set <recycle_state>.
00047   virtual ACE_Recyclable_State recycle_state (const void *recycling_act) const = 0;
00048 
00049   /// Mark as closed.
00050   virtual int mark_as_closed (const void *recycling_act) = 0;
00051 
00052   /// Mark as closed.(non-locking version)
00053   virtual int mark_as_closed_i (const void *recycling_act) = 0;
00054 
00055   /// Cleanup hint and reset <*act_holder> to zero if <act_holder != 0>.
00056   virtual int cleanup_hint (const void *recycling_act,
00057                             void **act_holder = 0) = 0;
00058 
00059 protected:
00060   /// Default ctor.
00061   ACE_Connection_Recycling_Strategy (void);
00062 };
00063 
00064 
00065 
00066 #include "ace/post.h"
00067 #endif /*ACE_CONNECTION_RECYCLING_STRATEGY*/

Generated on Mon Jun 16 11:19:24 2003 for ACE by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002