summaryrefslogtreecommitdiff
path: root/TAO/tao/default_resource.h
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tao/default_resource.h')
-rw-r--r--TAO/tao/default_resource.h117
1 files changed, 58 insertions, 59 deletions
diff --git a/TAO/tao/default_resource.h b/TAO/tao/default_resource.h
index e7e65387d66..0886ca7affc 100644
--- a/TAO/tao/default_resource.h
+++ b/TAO/tao/default_resource.h
@@ -1,19 +1,15 @@
// -*- C++ -*-
-// $Id$
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO
-//
-// = FILENAME
-// default_resource.h
-//
-// = AUTHOR
-// Chris Cleeland
-// Carlos O'Ryan
-//
-// ============================================================================
+
+//=============================================================================
+/**
+ * @file default_resource.h
+ *
+ * $Id$
+ *
+ * @author Chris CleelandCarlos O'Ryan
+ */
+//=============================================================================
+
#ifndef TAO_DEFAULT_RESOURCE_H
#define TAO_DEFAULT_RESOURCE_H
@@ -30,35 +26,36 @@
class TAO_Object_Adapter;
class TAO_IOR_Parser;
+/**
+ * @class TAO_Default_Resource_Factory
+ *
+ * @brief TAO's default resource factory
+ *
+ * Using a <{resource source specifier}> as a discriminator, the
+ * factory can return resource instances which are, e.g., global,
+ * stored in thread-specific storage, stored in shared memory,
+ * etc.
+ */
class TAO_Export TAO_Default_Resource_Factory : public TAO_Resource_Factory
{
- // = TITLE
- // TAO's default resource factory
- //
- // = DESCRIPTION
- // Using a <{resource source specifier}> as a discriminator, the
- // factory can return resource instances which are, e.g., global,
- // stored in thread-specific storage, stored in shared memory,
- // etc.
- //
public:
// = Initialization and termination methods.
+ /// Constructor.
TAO_Default_Resource_Factory (void);
- // Constructor.
+ /// Destructor.
virtual ~TAO_Default_Resource_Factory (void);
- // Destructor.
// = Service Configurator hooks.
+ /// Dynamic linking hook
virtual int init (int argc, char* argv[]);
- // Dynamic linking hook
+ /// Parse svc.conf arguments
int parse_args (int argc, char* argv[]);
- // Parse svc.conf arguments
+ /// = Member Accessors
int get_parser_names (char **&names,
int &number_of_names);
- // = Member Accessors
enum
{
TAO_ALLOCATOR_THREAD_LOCK
@@ -77,8 +74,8 @@ public:
TAO_REACTOR_PER_PRIORITY
};
+ /// Modify and get the source for the CDR allocators
int cdr_allocator_source (void);
- // Modify and get the source for the CDR allocators
// = Resource Retrieval
virtual int use_tss_resources (void) const;
@@ -93,69 +90,71 @@ public:
virtual ACE_Allocator* output_cdr_dblock_allocator (void);
virtual ACE_Allocator* output_cdr_buffer_allocator (void);
virtual TAO_ProtocolFactorySet *get_protocol_factories (void);
-
+
virtual int init_protocol_factories (void);
-
+
virtual TAO_Resource_Factory::Caching_Strategy connection_caching_strategy_type (void) const;
virtual double purge_percentage (void) const;
virtual TAO_Priority_Mapping *get_priority_mapping (void);
virtual ACE_Lock *create_cached_connection_lock (void);
protected:
+ /// Obtain the reactor implementation
virtual ACE_Reactor_Impl *allocate_reactor_impl (void) const;
- // Obtain the reactor implementation
+ /// Add a Parser name to the list of Parser names.
int add_to_ior_parser_names (const char *);
- // Add a Parser name to the list of Parser names.
protected:
+ /// Flag indicating whether resources should be global or
+ /// thread-specific.
int use_tss_resources_;
- // Flag indicating whether resources should be global or
- // thread-specific.
+ /// The type of data blocks that the ORB should use
int use_locked_data_blocks_;
- // The type of data blocks that the ORB should use
+ /// The number of the different types of Parsers.
int parser_names_count_;
- // The number of the different types of Parsers.
+ /// Array consisting of the names of the parsers
char **parser_names_;
- // Array consisting of the names of the parsers
+ /// Index of the current element in the parser_names_ array
int index_;
- // Index of the current element in the parser_names_ array
+ /// list of loaded protocol factories.
TAO_ProtocolFactorySet protocol_factories_;
- // list of loaded protocol factories.
+ /// Specifies the typeof caching strategy we should use for
+ /// connection management.
TAO_Resource_Factory::Caching_Strategy connection_caching_type_;
- // Specifies the typeof caching strategy we should use for
- // connection management.
+ /// Specifies the percentage of entries which should get purged on
+ /// demand.
double purge_percentage_;
- // Specifies the percentage of entries which should get purged on
- // demand.
+ /// If <0> then we create reactors with signal handling disabled.
int reactor_mask_signals_;
- // If <0> then we create reactors with signal handling disabled.
+ /// The scheduling policy used to initialize the priority mapping
+ /// strategy.
int sched_policy_;
- // The scheduling policy used to initialize the priority mapping
- // strategy.
+ /// The type of priority mapping class created by this factory.
int priority_mapping_type_;
- // The type of priority mapping class created by this factory.
+ /**
+ * Flag that is set to 1 if the reactor obtained from the
+ * get_reactor() method is dynamically allocated. If this flag is
+ * set to 1, then the reclaim_reactor() method with call the delete
+ * operator on the given reactor. This flag is necessary to make
+ * sure that a reactor not allocated by the default resource factory
+ * is not reclaimed by the default resource factory. Such a
+ * situation can occur when a resource factory derived from the
+ * default one overrides the get_reactor() method but does not
+ * override the reclaim_reactor() method.
+ */
int dynamically_allocated_reactor_;
- // Flag that is set to 1 if the reactor obtained from the
- // get_reactor() method is dynamically allocated. If this flag is
- // set to 1, then the reclaim_reactor() method with call the delete
- // operator on the given reactor. This flag is necessary to make
- // sure that a reactor not allocated by the default resource factory
- // is not reclaimed by the default resource factory. Such a
- // situation can occur when a resource factory derived from the
- // default one overrides the get_reactor() method but does not
- // override the reclaim_reactor() method.
virtual int load_default_protocols (void);
@@ -166,8 +165,8 @@ private:
TAO_THREAD_LOCK
};
+ /// Type of lock used by the cached connector.
Lock_Type cached_connection_lock_type_;
- // Type of lock used by the cached connector.
};
#if defined (__ACE_INLINE__)