IORManip_IIOP_Filter.h

Go to the documentation of this file.
00001 // $Id: IORManip_IIOP_Filter.h 78285 2007-05-08 11:14:41Z elliott_c $
00002 
00003 // =========================================================================
00004 //
00005 // = LIBRARY
00006 //    TAO
00007 //
00008 // = FILENAME
00009 //    IORManip_IIOP_Filter.h
00010 //
00011 // = AUTHOR
00012 //    Chad Elliott <elliott_c@ociweb.com>
00013 //
00014 // =========================================================================
00015 
00016 #ifndef TAO_IORMANIP_IIOP_FILTER_H
00017 #define TAO_IORMANIP_IIOP_FILTER_H
00018 #include /**/ "ace/pre.h"
00019 
00020 #include "IORManip_Filter.h"
00021 
00022 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00023 # pragma once
00024 #endif /* ACE_LACKS_PRAGMA_ONCE */
00025 
00026 #if defined (TAO_HAS_IIOP) && (TAO_HAS_IIOP != 0)
00027 
00028 #include "tao/IIOP_EndpointsC.h"
00029 #include "ace/SString.h"
00030 
00031 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
00032 
00033 class TAO_IIOP_Profile;
00034 namespace TAO
00035 {
00036   class IIOPEndpointSequence;
00037 }
00038 
00039 class TAO_IORManip_Export TAO_IORManip_IIOP_Filter: public TAO_IORManip_Filter
00040 {
00041 public:
00042   struct Profile_Info
00043   {
00044     ACE_CString host_name_;
00045     TAO_GIOP_Message_Version version_;
00046     CORBA::UShort port_;
00047   };
00048 
00049   /// Constructor.
00050   TAO_IORManip_IIOP_Filter (void);
00051 
00052   /// Destructor.
00053   virtual ~TAO_IORManip_IIOP_Filter (void);
00054 
00055   /// Compares the profile to the profile info.
00056   virtual CORBA::Boolean compare_profile_info (
00057                          const TAO_IORManip_IIOP_Filter::Profile_Info& left,
00058                          const TAO_IORManip_IIOP_Filter::Profile_Info& right);
00059 
00060   /// Empty virtual method to match on the profile info.
00061   /// Users must provide an implementation to use the first
00062   /// form of sanitize_profiles().
00063   virtual CORBA::Boolean profile_info_matches (
00064                          const TAO_IORManip_IIOP_Filter::Profile_Info& pinfo);
00065 
00066 protected:
00067 
00068   /// This is the bulk of the filtering code.
00069   virtual void filter_and_add (TAO_Profile* profile,
00070                                TAO_MProfile& profiles,
00071                                TAO_Profile* guideline = 0);
00072 
00073 private:
00074 
00075   /// Fill in the Profile_Info with information from the profile.
00076   int fill_profile_info (TAO_Profile* profile,
00077                          TAO_IORManip_IIOP_Filter::Profile_Info& pinfo);
00078 
00079   /// Get the endpoint sequence from the profile.
00080   int get_endpoints (TAO_Profile* profile,
00081                      TAO::IIOPEndpointSequence& endpoints);
00082 
00083   /// Allocate a new IIOP Profile based on the profile passed in.
00084   TAO_IIOP_Profile* create_profile (TAO_Profile* profile);
00085 };
00086 
00087 TAO_END_VERSIONED_NAMESPACE_DECL
00088 
00089 #endif /* TAO_HAS_IIOP && TAO_HAS_IIOP != 0 */
00090 
00091 #include /**/ "ace/post.h"
00092 #endif /* TAO_IORMANIP_IIOP_FILTER_H */

Generated on Tue Feb 2 17:43:35 2010 for TAO_IORManipulation by  doxygen 1.4.7