src/share/classes/javax/rmi/CORBA/UtilDelegate.java

changeset 1
55540e827aef
child 158
91006f157c46
equal deleted inserted replaced
-1:000000000000 1:55540e827aef
1 /*
2 * Copyright 1999-2001 Sun Microsystems, Inc. All Rights Reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Sun designates this
8 * particular file as subject to the "Classpath" exception as provided
9 * by Sun in the LICENSE file that accompanied this code.
10 *
11 * This code is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * version 2 for more details (a copy is included in the LICENSE file that
15 * accompanied this code).
16 *
17 * You should have received a copy of the GNU General Public License version
18 * 2 along with this work; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 *
21 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
22 * CA 95054 USA or visit www.sun.com if you need additional information or
23 * have any questions.
24 */
25 /*
26 * Licensed Materials - Property of IBM
27 * RMI-IIOP v1.0
28 * Copyright IBM Corp. 1998 1999 All Rights Reserved
29 *
30 */
31
32 package javax.rmi.CORBA;
33
34 import java.io.Serializable;
35 import java.rmi.Remote;
36 import java.rmi.RemoteException;
37 import javax.rmi.CORBA.Tie;
38 import javax.rmi.CORBA.ValueHandler;
39 import org.omg.CORBA.ORB;
40 import org.omg.CORBA.portable.InputStream;
41 import org.omg.CORBA.portable.OutputStream;
42 import org.omg.CORBA.SystemException;
43
44 /**
45 * Supports delegation for method implementations in {@link Util}. The
46 * delegate is a singleton instance of a class that implements this
47 * interface and provides a replacement implementation for all the
48 * methods of <code>javax.rmi.CORBA.Util</code>.
49 *
50 * Delegation is enabled by providing the delegate's class name as the
51 * value of the
52 * <code>javax.rmi.CORBA.UtilClass</code>
53 * system property.
54 *
55 * @see Util
56 */
57 public interface UtilDelegate {
58
59 /**
60 * Delegation call for {@link Util#mapSystemException}.
61 */
62 RemoteException mapSystemException(SystemException ex);
63
64 /**
65 * Delegation call for {@link Util#writeAny}.
66 */
67 void writeAny(OutputStream out, Object obj);
68
69 /**
70 * Delegation call for {@link Util#readAny}.
71 */
72 java.lang.Object readAny(InputStream in);
73
74 /**
75 * Delegation call for {@link Util#writeRemoteObject}.
76 */
77 void writeRemoteObject(OutputStream out, Object obj);
78
79 /**
80 * Delegation call for {@link Util#writeAbstractObject}.
81 */
82 void writeAbstractObject(OutputStream out, Object obj);
83
84 /**
85 * Delegation call for {@link Util#registerTarget}.
86 */
87 void registerTarget(Tie tie, Remote target);
88
89 /**
90 * Delegation call for {@link Util#unexportObject}.
91 */
92 void unexportObject(Remote target) throws java.rmi.NoSuchObjectException;
93
94 /**
95 * Delegation call for {@link Util#getTie}.
96 */
97 Tie getTie(Remote target);
98
99 /**
100 * Delegation call for {@link Util#createValueHandler}.
101 */
102 ValueHandler createValueHandler();
103
104 /**
105 * Delegation call for {@link Util#getCodebase}.
106 */
107 String getCodebase(Class clz);
108
109 /**
110 * Delegation call for {@link Util#loadClass}.
111 */
112 Class loadClass(String className, String remoteCodebase, ClassLoader loader)
113 throws ClassNotFoundException;
114
115 /**
116 * Delegation call for {@link Util#isLocal}.
117 */
118 boolean isLocal(Stub stub) throws RemoteException;
119
120 /**
121 * Delegation call for {@link Util#wrapException}.
122 */
123 RemoteException wrapException(Throwable obj);
124
125 /**
126 * Delegation call for {@link Util#copyObject}.
127 */
128 Object copyObject(Object obj, ORB orb) throws RemoteException;
129
130 /**
131 * Delegation call for {@link Util#copyObjects}.
132 */
133 Object[] copyObjects(Object[] obj, ORB orb) throws RemoteException;
134
135 }

mercurial