IOR.pidl

Go to the documentation of this file.
00001 /**
00002  * @file IOR.pidl
00003  *
00004  * IOR.pidl,v 1.9 2006/05/09 07:34:04 jwillemsen Exp
00005  *
00006  * @brief Pre-compiled IDL source for the TAO_IOP namespace.
00007  *
00008  * This file was used to generate the code in IORC.{h,cpp}.
00009  *
00010  * To regenerate the code use:
00011  *
00012  * tao_idl \
00013  *        -o orig -Gp -Gd -Ge 1 -GA -Sci \
00014  *          -Wb,export_macro=TAO_IORManip_Export \
00015  *          -Wb,export_include="ior_manip_export.h" \
00016  *          -Wb,pre_include="ace/pre.h" \
00017  *          -Wb,post_include="ace/post.h" \
00018  *   IOR.pidl
00019  *
00020  */
00021 
00022 #ifndef TAO_IOR_PIDL
00023 #define TAO_IOR_PIDL
00024 
00025 module TAO_IOP
00026 {
00027   /**
00028    * @exception EmptyProfileList
00029    *
00030    * @brief @@ Bala, please describe this exception
00031    */
00032   exception EmptyProfileList {};
00033 
00034   /**
00035    * @exception NotFound
00036    *
00037    * @brief @@ Bala, please describe this exception
00038    */
00039   exception NotFound {};
00040 
00041   /**
00042    * @exception Duplicate
00043    *
00044    * @brief @@ Bala, please describe this exception
00045    */
00046   exception Duplicate {};
00047 
00048   /**
00049    * @exception Invalid_IOR
00050    *
00051    * @brief @@ Bala, please describe this exception
00052    */
00053   exception Invalid_IOR {};
00054 
00055   /**
00056    * @exception MultiProfileList
00057    *
00058    * @brief @@ Bala, please describe this exception
00059    */
00060   exception MultiProfileList {};
00061 
00062   /**
00063    * @interface TAO_IOR_Property
00064    *
00065    * Allows setting properties  by the different services in the
00066    * IOR. The implementations of this interface would reside in the
00067    * services. This interface essentially performs a role of a
00068    * callback object.
00069    *
00070    * @todo This interface seems redundant in the face of the
00071    * PortableInterceptor::IORInterceptor and the
00072    * ObjectReferenceTemplate.  If that is the case we should deprecate
00073    * it and remove it.
00074    */
00075   local interface TAO_IOR_Property
00076   {
00077     /// Operation that would set the required properties in the <ior>
00078     /// as needed by the service.
00079     boolean set_property (inout Object ior)
00080       raises (Invalid_IOR);
00081 
00082     /// Sets the profile ior1, in the profile ior2 to be a
00083     /// primary.
00084     boolean set_primary (inout Object ior1,
00085                          in Object ior2)
00086       raises (Duplicate, NotFound);
00087 
00088     /// Returns the ior  of the primary from <ior> if it has been
00089     /// set. Else returns a NotFound exception
00090     Object get_primary (in Object ior)
00091       raises (NotFound);
00092 
00093     /// Returns a true or false depending on whether a primary member
00094     /// has been set in <ior>
00095     boolean is_primary_set (in Object ior);
00096 
00097     /// If any of the IOR's within the IOGR has a primary tag, just
00098     /// remove it. Returns zero if no primary was found.
00099     boolean remove_primary_tag (inout Object iogr)
00100       raises (NotFound);
00101   };
00102 
00103   /**
00104    * @interface TAO_IOR_Manipulation
00105    *
00106    * @brief Allows applications to manipulate object references.
00107    *
00108    * Manipulating Object References.  While this interface does not
00109    * assume the use of CORBA complient IOPs, the IOP termonology is
00110    * used throughout.
00111    * Object references (Object) are used since they encapsulate the
00112    * notion of object references and IORs.
00113    * Note, an IOR contains one or more profiles and a profile can be
00114    * considered to represent the location or route to a specific instance
00115    * of an object.
00116    * A profile may also contain supplimentary information useful for
00117    * differrent services such as security.
00118    * All Object references may have multiple profiles
00119    */
00120   local interface TAO_IOR_Manipulation
00121   {
00122       typedef sequence <Object> IORList;
00123 
00124       Object merge_iors (in IORList iors)
00125         raises (EmptyProfileList,Duplicate,Invalid_IOR);
00126       // Create a new object reference by merging the profiles lists in the
00127       // supplied list of one or more object references.
00128 
00129       Object add_profiles (in Object ior1,
00130                            in Object ior2)
00131         raises (EmptyProfileList, Duplicate, Invalid_IOR);
00132       // copy the profile list from "ior2" to "ior1".
00133       // Note on ordering, while the current implementation will place
00134       // the profiles from ior2 (which are not already in ior1) on the
00135       // end of the profile list in ior1, there is no guarantee this ordering
00136       // will be maintained.  For example, string_to_object or object_to_string
00137       // may reorder the profile lists.  So, if it is important to use one
00138       // profile before another then policies should be used along with tagged
00139       // components/tagged profiles.
00140 
00141       Object remove_profiles (in Object ior1,
00142                               in Object ior2)
00143         raises (Invalid_IOR, EmptyProfileList, NotFound);
00144       // Any profile in ior1 which matches at least one profile in ior2
00145       // will be removed.  Returns a new object reference
00146 
00147 
00148       boolean set_property (in TAO_IOR_Property prop,
00149                             in Object ior)
00150         raises (Invalid_IOR, Duplicate);
00151       // Allows setting of properties as defined by the <prop> object
00152       // in the <ior> list
00153 
00154       // @@ Primary is specific to FT.. But let us have these
00155       // @@ operations around. Further, as we pass the property object
00156       // @@ around the implementation will not be tied with the FT
00157       // @@ service. Any service can use their own ways of defining a
00158       // @@ primary. For example FT service uses IOP::TAG_FT_PRIMARY
00159       // @@ to identify a primary and some other service could use
00160       // @@ something else. But the actual implementation of the
00161       // @@ property object would take care of that.
00162       boolean set_primary (in TAO_IOR_Property prop,
00163                            in Object ior1,
00164                            in Object ior2)
00165         raises (Invalid_IOR, Duplicate, MultiProfileList, NotFound);
00166       // Sets the profile ior1, in the profile ior2 to be a
00167       // primary. If ior1 is a multi-profile IOR then the operation
00168       // raises the MultiProfileList exception. If ior1 is not found
00169       // in ior2, it raises an Invalid_IOR exception. If ior2 has a
00170       // primary already defined then it raises a Duplicate
00171       // exception.
00172 
00173       /// If any of the IOR's within the IOGR has a primary tag, just remove
00174       /// it. Return zero if no primary found.
00175       boolean remove_primary_tag (in TAO_IOR_Property prop,
00176                                   in Object ior);
00177 
00178 
00179       Object get_primary (in TAO_IOR_Property prop,
00180                           in Object ior)
00181         raises (NotFound);
00182       // Returns the ior  of the primary from <ior> if it has been
00183       // set. Else returns a NotFound exception
00184 
00185       boolean is_primary_set (in TAO_IOR_Property prop,
00186                               in Object ior);
00187       // Returns a true or false depending on whether a primary member
00188       // has been set in <ior>
00189 
00190       unsigned long is_in_ior(in Object ior1, in Object ior2)
00191         raises (NotFound);
00192       // returns number of profiles which are in both ior1 and ior2.
00193 
00194       unsigned long get_profile_count (in Object ior)
00195         raises (EmptyProfileList);
00196       // This will return the number of profiles contained in the
00197       // corresponding object reference for this object.
00198   };
00199 };
00200 
00201 #endif /* TAO_IOR_PIDL */

Generated on Thu Nov 9 13:06:04 2006 for TAO_IORManipulation by doxygen 1.3.6