TAO_Resource_Factory Class Reference

Factory which manufacturers resources for use by the ORB Core. More...

#include <Resource_Factory.h>

Inheritance diagram for TAO_Resource_Factory:

Inheritance graph
[legend]
Collaboration diagram for TAO_Resource_Factory:

Collaboration graph
[legend]
List of all members.

Public Types

enum  Purging_Strategy { LRU, LFU, FIFO, NOOP }
enum  Resource_Usage { TAO_EAGER, TAO_LAZY }

Public Member Functions

 TAO_Resource_Factory (void)
virtual ~TAO_Resource_Factory (void)
virtual int use_locked_data_blocks (void) const
virtual ACE_Reactorget_reactor (void)
 Return an ACE_Reactor to be utilized.

virtual void reclaim_reactor (ACE_Reactor *reactor)
 Reclaim reactor resources (e.g. deallocate, etc).

virtual TAO_Acceptor_Registryget_acceptor_registry (void)
 Return a reference to the acceptor registry.

virtual TAO_Connector_Registryget_connector_registry (void)
 Return a connector to be utilized.

virtual void use_local_memory_pool (bool)
 Return the Allocator's memory pool type.

virtual int input_cdr_allocator_type_locked (void)
virtual ACE_Allocatoramh_response_handler_allocator (void)
 Access the AMH response handler allocator.

virtual ACE_Allocatorami_response_handler_allocator (void)
 Access the AMI response handler allocator.

virtual TAO_ProtocolFactorySetget_protocol_factories (void)
virtual int init_protocol_factories (void)
virtual TAO_Codeset_Managercodeset_manager (void)
 Gets the codeset manager.

virtual int cache_maximum (void) const
 This denotes the maximum number of connections that can be cached.

virtual int purge_percentage (void) const
virtual int max_muxed_connections (void) const
virtual int get_parser_names (char **&names, int &number_of_names)
virtual ACE_Lockcreate_cached_connection_lock (void)
virtual int locked_transport_cache (void)
virtual ACE_Lockcreate_object_key_table_lock (void)
 Creates a lock needed for the table that stores the object keys.

virtual ACE_Lockcreate_corba_object_lock (void)
 Creates the lock for the CORBA Object.

virtual TAO_Flushing_Strategycreate_flushing_strategy (void)=0
virtual TAO_Connection_Purging_Strategycreate_purging_strategy (void)=0
 Creates the connection purging strategy.

virtual TAO_LF_Strategycreate_lf_strategy (void)=0
virtual auto_ptr< TAO_GIOP_Fragmentation_Strategycreate_fragmentation_strategy (TAO_Transport *transport, CORBA::ULong max_message_size) const=0
 Outgoing fragment creation strategy.

virtual void disable_factory (void)=0
virtual TAO_Resource_Factory::Resource_Usage resource_usage_strategy (void) const=0
 Return the resource usage strategy.

virtual bool drop_replies_during_shutdown () const=0
Access the input CDR allocators.
virtual ACE_Allocatorinput_cdr_dblock_allocator (void)
virtual ACE_Allocatorinput_cdr_buffer_allocator (void)
virtual ACE_Allocatorinput_cdr_msgblock_allocator (void)
Access the output CDR allocators.
virtual ACE_Allocatoroutput_cdr_dblock_allocator (void)
virtual ACE_Allocatoroutput_cdr_buffer_allocator (void)
virtual ACE_Allocatoroutput_cdr_msgblock_allocator (void)

Protected Member Functions

virtual int load_default_protocols (void)

Detailed Description

Factory which manufacturers resources for use by the ORB Core.

This class is a factory/repository for critical ORB Core resources.

Definition at line 109 of file Resource_Factory.h.


Member Enumeration Documentation

enum TAO_Resource_Factory::Purging_Strategy
 

Enumeration values:
LRU  Least Recently Used.
LFU  Least Frequently Used.
FIFO  First In First Out.
NOOP  Dont use any strategy.

Definition at line 113 of file Resource_Factory.h.

00114   {
00115     /// Least Recently Used
00116     LRU,
00117 
00118     /// Least Frequently Used
00119     LFU,
00120 
00121     /// First In First Out
00122     FIFO,
00123 
00124     /// Dont use any strategy.
00125     NOOP
00126   };

enum TAO_Resource_Factory::Resource_Usage
 

Enumeration values:
TAO_EAGER  Use resources in an eager fashion.
TAO_LAZY  Use resources in a lazy manner.

Definition at line 128 of file Resource_Factory.h.

00129     {
00130       /// Use resources in an eager fashion
00131       TAO_EAGER,
00132 
00133       /// Use resources in a lazy manner
00134       TAO_LAZY
00135     };


Constructor & Destructor Documentation

TAO_Resource_Factory::TAO_Resource_Factory void   ) 
 

Definition at line 55 of file Resource_Factory.cpp.

00056 {
00057 }

TAO_Resource_Factory::~TAO_Resource_Factory void   )  [virtual]
 

Definition at line 59 of file Resource_Factory.cpp.

00060 {
00061 }


Member Function Documentation

ACE_Allocator * TAO_Resource_Factory::amh_response_handler_allocator void   )  [virtual]
 

Access the AMH response handler allocator.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 141 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::amh_response_handler_allocator().

00142 {
00143   return 0;
00144 }

ACE_Allocator * TAO_Resource_Factory::ami_response_handler_allocator void   )  [virtual]
 

Access the AMI response handler allocator.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 147 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::ami_response_handler_allocator().

00148 {
00149   return 0;
00150 }

int TAO_Resource_Factory::cache_maximum void   )  const [virtual]
 

This denotes the maximum number of connections that can be cached.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 171 of file Resource_Factory.cpp.

References TAO_CONNECTION_CACHE_MAXIMUM.

00172 {
00173   return TAO_CONNECTION_CACHE_MAXIMUM;
00174 }

TAO_Codeset_Manager * TAO_Resource_Factory::codeset_manager void   )  [virtual]
 

Gets the codeset manager.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 165 of file Resource_Factory.cpp.

Referenced by TAO_ORB_Core::codeset_manager().

00166 {
00167   return 0;
00168 }

ACE_Lock * TAO_Resource_Factory::create_cached_connection_lock void   )  [virtual]
 

Creates the lock for the lock needed in the Cache Map

Deprecated:

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 197 of file Resource_Factory.cpp.

Referenced by TAO_Asynch_Reply_Dispatcher_Base::TAO_Asynch_Reply_Dispatcher_Base(), and TAO_Connection_Handler::TAO_Connection_Handler().

00198 {
00199   return 0;
00200 }

ACE_Lock * TAO_Resource_Factory::create_corba_object_lock void   )  [virtual]
 

Creates the lock for the CORBA Object.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 215 of file Resource_Factory.cpp.

Referenced by CORBA::Object::Object().

00216 {
00217   return 0;
00218 }

virtual TAO_Flushing_Strategy* TAO_Resource_Factory::create_flushing_strategy void   )  [pure virtual]
 

Creates the flushing strategy. The new instance is owned by the caller.

Implemented in TAO_Default_Resource_Factory.

virtual auto_ptr<TAO_GIOP_Fragmentation_Strategy> TAO_Resource_Factory::create_fragmentation_strategy TAO_Transport transport,
CORBA::ULong  max_message_size
const [pure virtual]
 

Outgoing fragment creation strategy.

Implemented in TAO_Default_Resource_Factory.

Referenced by TAO_ORB_Core::fragmentation_strategy().

virtual TAO_LF_Strategy* TAO_Resource_Factory::create_lf_strategy void   )  [pure virtual]
 

Creates the leader followers strategy. The new instance is owned by the caller.

Implemented in TAO_Default_Resource_Factory.

Referenced by TAO_Thread_Lane_Resources_Manager::TAO_Thread_Lane_Resources_Manager().

ACE_Lock * TAO_Resource_Factory::create_object_key_table_lock void   )  [virtual]
 

Creates a lock needed for the table that stores the object keys.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 209 of file Resource_Factory.cpp.

Referenced by TAO::ObjectKey_Table::init().

00210 {
00211   return 0;
00212 }

virtual TAO_Connection_Purging_Strategy* TAO_Resource_Factory::create_purging_strategy void   )  [pure virtual]
 

Creates the connection purging strategy.

Implemented in TAO_Default_Resource_Factory.

virtual void TAO_Resource_Factory::disable_factory void   )  [pure virtual]
 

Disables the factory. When a new factory is installed and used, this function should be called on the previously used (default) factory. This should result in proper error reporting if the user attempts to set options on an unused factory.

Implemented in TAO_Default_Resource_Factory.

virtual bool TAO_Resource_Factory::drop_replies_during_shutdown  )  const [pure virtual]
 

Return the value of the strategy that indicates whether the ORB should wait for the replies during shutdown or drop replies during shutdown.

Implemented in TAO_Default_Resource_Factory.

Referenced by TAO_Thread_Lane_Resources::cleanup_rw_transports(), TAO_Leader_Follower::set_client_thread(), and TAO_Thread_Lane_Resources::shutdown_reactor().

TAO_Acceptor_Registry * TAO_Resource_Factory::get_acceptor_registry void   )  [virtual]
 

Return a reference to the acceptor registry.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 88 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::acceptor_registry().

00089 {
00090   return 0;
00091 }

TAO_Connector_Registry * TAO_Resource_Factory::get_connector_registry void   )  [virtual]
 

Return a connector to be utilized.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 82 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::connector_registry().

00083 {
00084   return 0;
00085 }

int TAO_Resource_Factory::get_parser_names char **&  names,
int &  number_of_names
[virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 190 of file Resource_Factory.cpp.

Referenced by TAO_Parser_Registry::open().

00192 {
00193   return 0;
00194 }

TAO_ProtocolFactorySet * TAO_Resource_Factory::get_protocol_factories void   )  [virtual]
 

The protocol factory list is implemented in this class since a) it will be a global resource and b) it is initialized at start up and then not altered. Returns a container holding the list of loaded protocols.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 153 of file Resource_Factory.cpp.

00154 {
00155   return 0;
00156 }

ACE_Reactor * TAO_Resource_Factory::get_reactor void   )  [virtual]
 

Return an ACE_Reactor to be utilized.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 70 of file Resource_Factory.cpp.

Referenced by TAO_Leader_Follower::reactor().

00071 {
00072   return 0;
00073 }

int TAO_Resource_Factory::init_protocol_factories void   )  [virtual]
 

This method will loop through the protocol list and using the protocol name field this method will retrieve a pointer to the associated protocol factory from the service configurator. It is assumed that only one thread will call this method at ORB initialization. NON-THREAD-SAFE

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 159 of file Resource_Factory.cpp.

00160 {
00161   return -1;
00162 }

int TAO_Resource_Factory::input_cdr_allocator_type_locked void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 117 of file Resource_Factory.cpp.

00118 {
00119   return -1;
00120 }

ACE_Allocator * TAO_Resource_Factory::input_cdr_buffer_allocator void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 105 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::input_cdr_buffer_allocator().

00106 {
00107   return 0;
00108 }

ACE_Allocator * TAO_Resource_Factory::input_cdr_dblock_allocator void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 99 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::input_cdr_dblock_allocator(), and TAO_Thread_Lane_Resources::transport_message_buffer_allocator().

00100 {
00101   return 0;
00102 }

ACE_Allocator * TAO_Resource_Factory::input_cdr_msgblock_allocator void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 111 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::input_cdr_msgblock_allocator().

00112 {
00113   return 0;
00114 }

int TAO_Resource_Factory::load_default_protocols void   )  [protected, virtual]
 

Loads the default protocols. This method is used so that the advanced_resource.cpp can call the one in default_resource.cpp without calling unnecessary functions.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 221 of file Resource_Factory.cpp.

00222 {
00223   return 0;
00224 }

int TAO_Resource_Factory::locked_transport_cache void   )  [virtual]
 

Should the transport cache have a lock or not? Return 1 if the transport cache needs to be locked else return 0

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 203 of file Resource_Factory.cpp.

Referenced by TAO::Transport_Cache_Manager::Transport_Cache_Manager().

00204 {
00205   return 0;
00206 }

int TAO_Resource_Factory::max_muxed_connections void   )  const [virtual]
 

Return the number of muxed connections that are allowed for a remote endpoint

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 183 of file Resource_Factory.cpp.

00184 {
00185   return 0;
00186 }

ACE_Allocator * TAO_Resource_Factory::output_cdr_buffer_allocator void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 129 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::output_cdr_buffer_allocator().

00130 {
00131   return 0;
00132 }

ACE_Allocator * TAO_Resource_Factory::output_cdr_dblock_allocator void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 123 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::output_cdr_dblock_allocator().

00124 {
00125   return 0;
00126 }

ACE_Allocator * TAO_Resource_Factory::output_cdr_msgblock_allocator void   )  [virtual]
 

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 135 of file Resource_Factory.cpp.

Referenced by TAO_Thread_Lane_Resources::output_cdr_msgblock_allocator().

00136 {
00137   return 0;
00138 }

int TAO_Resource_Factory::purge_percentage void   )  const [virtual]
 

This denotes the amount of entries to remove from the connection cache.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 177 of file Resource_Factory.cpp.

00178 {
00179   return 0;
00180 }

void TAO_Resource_Factory::reclaim_reactor ACE_Reactor reactor  )  [virtual]
 

Reclaim reactor resources (e.g. deallocate, etc).

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 76 of file Resource_Factory.cpp.

Referenced by TAO_Leader_Follower::~TAO_Leader_Follower().

00077 {
00078   return;
00079 }

virtual TAO_Resource_Factory::Resource_Usage TAO_Resource_Factory::resource_usage_strategy void   )  const [pure virtual]
 

Return the resource usage strategy.

Implemented in TAO_Default_Resource_Factory.

Referenced by operator>>().

void TAO_Resource_Factory::use_local_memory_pool bool   )  [virtual]
 

Return the Allocator's memory pool type.

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 94 of file Resource_Factory.cpp.

00095 {
00096 }

int TAO_Resource_Factory::use_locked_data_blocks void   )  const [virtual]
 

@ Backwards compatibility, return 1 if the ORB core should use Locked_Data_Blocks

Reimplemented in TAO_Default_Resource_Factory.

Definition at line 64 of file Resource_Factory.cpp.

Referenced by TAO_ORB_Core::create_input_cdr_data_block(), and TAO_ORB_Core::locking_strategy().

00065 {
00066   return 0;
00067 }


The documentation for this class was generated from the following files:
Generated on Thu Nov 9 12:23:25 2006 for TAO by doxygen 1.3.6