Public Member Functions

TAO_Persistent_Strategy Class Reference

Persistent strategy. More...

#include <Active_Object_Map.h>

Inheritance diagram for TAO_Persistent_Strategy:
Inheritance graph
[legend]
Collaboration diagram for TAO_Persistent_Strategy:
Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual int find_servant_using_system_id_and_user_id (const PortableServer::ObjectId &system_id, const PortableServer::ObjectId &user_id, PortableServer::Servant &servant, TAO_Active_Object_Map_Entry *&entry)
 Can be used with any policy.

Detailed Description

Persistent strategy.

Strategy for the PERSISTENT policy.

Definition at line 489 of file Active_Object_Map.h.


Member Function Documentation

int TAO_Persistent_Strategy::find_servant_using_system_id_and_user_id ( const PortableServer::ObjectId system_id,
const PortableServer::ObjectId user_id,
PortableServer::Servant servant,
TAO_Active_Object_Map_Entry *&  entry 
) [virtual]

Can be used with any policy.

Implements TAO_Lifespan_Strategy.

Definition at line 799 of file Active_Object_Map.cpp.

{
  int result =
    this->active_object_map_->id_hint_strategy_->find (system_id,
                                                       entry);
  if (result == 0 && user_id == entry->user_id_)
    {
      if (entry->deactivated_)
        {
          result = -1;
        }
      else if (entry->servant_ == 0)
        {
          result = -1;
        }
      else
        {
          servant = entry->servant_;
        }
    }
  else
    {
      result =
        this->active_object_map_->user_id_map_->find (user_id, entry);

      if (result == 0)
        {
          if (entry->deactivated_)
            {
              result = -1;
            }
          else if (entry->servant_ == 0)
            {
              result = -1;
            }
          else
            {
              servant = entry->servant_;
            }
        }
    }

  if (result == -1)
    {
      entry = 0;
    }

  return result;
}


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines