KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > omg > PortableServer > portable > Delegate


1 /*
2  * @(#)Delegate.java 1.11 03/12/19
3  *
4  * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7 package org.omg.PortableServer.portable;
8
9 import org.omg.PortableServer.Servant JavaDoc;
10 import org.omg.PortableServer.POA JavaDoc;
11
12 /**
13  * The portability package contains interfaces and classes
14  * that are designed for and intended to be used by ORB
15  * implementor. It exposes the publicly defined APIs that
16  * are used to connect stubs and skeletons to the ORB.
17  * The Delegate interface provides the ORB vendor specific
18  * implementation of PortableServer::Servant.
19  * Conformant to spec CORBA V2.3.1, ptc/00-01-08.pdf
20  */

21 public interface Delegate {
22 /**
23  * Convenience method that returns the instance of the ORB
24  * currently associated with the Servant.
25  * @param Self the servant.
26  * @return ORB associated with the Servant.
27  */

28     org.omg.CORBA.ORB JavaDoc orb(Servant JavaDoc Self);
29
30 /**
31  * This allows the servant to obtain the object reference for
32  * the target CORBA Object it is incarnating for that request.
33  * @param Self the servant.
34  * @return Object reference associated with the request.
35  */

36     org.omg.CORBA.Object JavaDoc this_object(Servant JavaDoc Self);
37
38 /**
39  * The method _poa() is equivalent to
40  * calling PortableServer::Current:get_POA.
41  * @param Self the servant.
42  * @return POA associated with the servant.
43  */

44     POA JavaDoc poa(Servant JavaDoc Self);
45
46 /**
47  * The method _object_id() is equivalent
48  * to calling PortableServer::Current::get_object_id.
49  * @param Self the servant.
50  * @return ObjectId associated with this servant.
51  */

52     byte[] object_id(Servant JavaDoc Self);
53
54 /**
55  * The default behavior of this function is to return the
56  * root POA from the ORB instance associated with the servant.
57  * @param Self the servant.
58  * @return POA associated with the servant class.
59  */

60     POA JavaDoc default_POA(Servant JavaDoc Self);
61
62 /**
63  * This method checks to see if the specified repid is present
64  * on the list returned by _all_interfaces() or is the
65  * repository id for the generic CORBA Object.
66  * @param Self the servant.
67  * @param Repository_Id the repository_id to be checked in the
68  * repository list or against the id of generic CORBA
69  * object.
70  * @return boolean indicating whether the specified repid is
71  * in the list or is same as that got generic CORBA
72  * object.
73  */

74     boolean is_a(Servant JavaDoc Self, String JavaDoc Repository_Id);
75
76 /**
77  * This operation is used to check for the existence of the
78  * Object.
79  * @param Self the servant.
80  * @return boolean true to indicate that object does not exist,
81  * and false otherwise.
82  */

83     boolean non_existent(Servant JavaDoc Self);
84     //Simon And Ken Will Ask About Editorial Changes
85
//In Idl To Java For The Following Signature.
86

87 /**
88  * This operation returns an object in the Interface Repository
89  * which provides type information that may be useful to a program.
90  * @param self the servant.
91  * @return type information corresponding to the object.
92  */

93     // The get_interface() method has been replaced by get_interface_def()
94
//org.omg.CORBA.Object get_interface(Servant Self);
95

96     org.omg.CORBA.Object JavaDoc get_interface_def(Servant JavaDoc self);
97 }
98
99
Popular Tags