Reference

ACE_Concurrency_Strategy(3)

Defines the interface for specifying a concurrency strategy for a SVC_HANDLER.

NAME

ACE_Concurrency_Strategy - Defines the interface for specifying a concurrency strategy for a SVC_HANDLER.

SYNOPSIS

#include <ace/ACE_Strategies_T.h>
template<class SVC_HANDLER>
class ACE_Concurrency_Strategy
{
  public:
    ACE_Concurrency_Strategy (int flags = 0);
    virtual int activate_svc_handler (
        SVC_HANDLER *svc_handler,
        void *arg = 0
        );
    virtual ~ACE_Concurrency_Strategy (void);
    void dump (void) const;
    ACE_ALLOC_HOOK_DECLARE;
  protected:
    int flags_;
};

DESCRIPTION

Default behavior is to activate the SVC_HANDLER by calling its open method (which allows the SVC_HANDLER to define its own concurrency strategy). However, subclasses can override this default strategy to do more sophisticated concurrency activations (such as creating the SVC_HANDLER as an active object via multi-threading or multi-processing).

Factory method.

virtual int activate_svc_handler (
    SVC_HANDLER *svc_handler,
    void *arg = 0
    );

Activate the svc_handler with an appropriate concurrency strategy. The default behavior of this method is to activate the SVC_HANDLER by calling its open method (which allows the SVC_HANDLER to define its own concurrency strategy).

virtual ~ACE_Concurrency_Strategy (void);

void dump (void) const;

Dump the state of an object.

ACE_ALLOC_HOOK_DECLARE;

Declare the dynamic allocation hooks.

AUTHOR

Doug Schmidt

LIBRARY

ace