Reference

ACE_Activation_Queue(3)

Reifies a method into a request. Subclasses typically represent necessary state and behavior.

NAME

ACE_Activation_Queue - Reifies a method into a request. Subclasses typically represent necessary state and behavior.

SYNOPSIS

#include <ace/Activation_Queue.h>
class ACE_Activation_Queue
{
  public:
    ACE_Activation_Queue (
        ACE_Message_Queue<ACE_SYNCH> *new_queue = 0
        );
    virtual ~ACE_Activation_Queue (void);
    ACE_Method_Request *dequeue (ACE_Time_Value *tv = 0);
    int enqueue (
        ACE_Method_Request *new_method_request,
        ACE_Time_Value *tv = 0
        );
    int method_count (void) const;
    int is_empty (void) const;
    int is_full (void) const;
    void dump (void) const;
    ACE_ALLOC_HOOK_DECLARE;
  protected:
    ACE_Message_Queue<ACE_SYNCH> *queue_;
    int delete_queue_;
};

DESCRIPTION

A Method_Request is inserted in the Activation_Queue, where it is subsequently removed by the Scheduler, which invokes its call method..

Initialization and termination methods.

ACE_Activation_Queue (ACE_Message_Queue<ACE_SYNCH> *new_queue = 0);

Constructor.

virtual ~ACE_Activation_Queue (void);

Destructor.

Activate Queue operations.

For the following two methods if timeout == 0, the caller will block until action is possible, else will wait until the absolute time specified in *timeout elapses. These calls will return, however, when queue is closed, deactivated, when a signal occurs, or if the time specified in timeout elapses, (in which case errno

ACE_Method_Request *dequeue (ACE_Time_Value *tv = 0);

Dequeue the next available Method_Request.

int enqueue (
    ACE_Method_Request *new_method_request,
    ACE_Time_Value *tv = 0
    );

Enqueue the Method_Request in priority order. The priority is determined by the priority method of the new_message_request.

int method_count (void) const;

Get the current number of method objects in the queue.

int is_empty (void) const;

Returns 1 if the queue is empty, 0 otherwise.

int is_full (void) const;

Returns 1 if the queue is full, 0 otherwise.

void dump (void) const;

Dump the state of an request.

ACE_ALLOC_HOOK_DECLARE;

Declare the dynamic allocation hooks.

AUTHOR

Andres Kruse [email protected] and Douglas C. Schmidt [email protected]

LIBRARY

ace