Find_Worker_T.h

Go to the documentation of this file.
00001 /* -*- C++ -*- */
00002 /**
00003  *  @file Find_Worker_T.h
00004  *
00005  *  Find_Worker_T.h,v 1.12 2006/03/14 06:14:34 jtc Exp
00006  *
00007  *  @author Pradeep Gore <pradeep@oomworks.com>
00008  *
00009  *
00010  */
00011 
00012 #ifndef TAO_Notify_FIND_WORKER_T_H
00013 #define TAO_Notify_FIND_WORKER_T_H
00014 #include /**/ "ace/pre.h"
00015 
00016 #include "orbsvcs/Notify/notify_serv_export.h"
00017 
00018 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00019 # pragma once
00020 #endif /* ACE_LACKS_PRAGMA_ONCE */
00021 
00022 #include "orbsvcs/ESF/ESF_Proxy_Collection.h"
00023 #include "orbsvcs/ESF/ESF_Worker.h"
00024 #include "orbsvcs/Notify/Container_T.h"
00025 #include "orbsvcs/Notify/Object.h"
00026 
00027 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00028 
00029 /**
00030  * @class TAO_Notify_Find_Worker_T
00031  *
00032  * @brief Helper to locate a TYPE given its ID.
00033  *
00034  */
00035 template <class TYPE, class INTERFACE, class INTERFACE_PTR, class EXCEPTION>
00036 class TAO_Notify_Serv_Export TAO_Notify_Find_Worker_T : public TAO_ESF_Worker<TYPE>
00037 {
00038   typedef TAO_Notify_Container_T<TYPE> CONTAINER;
00039   typedef TAO_ESF_Proxy_Collection<TYPE> COLLECTION;
00040 
00041 public:
00042   /// Constructor
00043   TAO_Notify_Find_Worker_T (void);
00044 
00045   /// Find the Type.
00046   TYPE* find (const TAO_Notify_Object::ID id, CONTAINER& container ACE_ENV_ARG_DECL);
00047 
00048   /// Find and resolve to the Interface.
00049   INTERFACE_PTR resolve (const TAO_Notify_Object::ID id, CONTAINER& container ACE_ENV_ARG_DECL);
00050 
00051 protected:
00052   ///= TAO_ESF_Worker method
00053   void work (TYPE* object ACE_ENV_ARG_DECL);
00054 
00055   /// The id we're looking for.
00056   TAO_Notify_Object::ID id_;
00057 
00058   /// The result
00059   TYPE* result_;
00060 };
00061 
00062 TAO_END_VERSIONED_NAMESPACE_DECL
00063 
00064 #if defined (__ACE_INLINE__)
00065 #include "orbsvcs/Notify/Find_Worker_T.inl"
00066 #endif /* __ACE_INLINE__ */
00067 
00068 #if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
00069 #include "orbsvcs/Notify/Find_Worker_T.cpp"
00070 #endif /* ACE_TEMPLATES_REQUIRE_SOURCE */
00071 
00072 #if defined (ACE_TEMPLATES_REQUIRE_PRAGMA)
00073 #pragma implementation ("Find_Worker_T.cpp")
00074 #endif /* ACE_TEMPLATES_REQUIRE_PRAGMA */
00075 
00076 #include /**/ "ace/post.h"
00077 #endif /* TAO_Notify_FIND_WORKER_T_H */

Generated on Thu Nov 9 13:24:12 2006 for TAO_CosNotification by doxygen 1.3.6