You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@avalon.apache.org by ha...@apache.org on 2003/01/19 23:10:53 UTC
cvs commit: jakarta-avalon-excalibur/altrmi/src/test/org/apache/excalibur/altrmi/test DummyInvocationHandler.java
hammant 2003/01/19 14:10:53
Modified: altrmi/src/java/org/apache/excalibur/altrmi/client
ClientInvocationHandler.java
altrmi/src/java/org/apache/excalibur/altrmi/client/impl
AbstractClientInvocationHandler.java
altrmi/src/java/org/apache/excalibur/altrmi/client/impl/callback/socket
CallbackEnabledSocketCustomStreamInvocationHandler.java
altrmi/src/java/org/apache/excalibur/altrmi/client/impl/multiple
AbstractMultipleInvocationHandler.java
altrmi/src/test/org/apache/excalibur/altrmi/test
DummyInvocationHandler.java
Removed: altrmi/src/java/org/apache/excalibur/altrmi/client
CallbackEnabledClientInvocationHandler.java
Log:
CallBackEnabledInvocationHandler put into parent interface
Revision Changes Path
1.5 +23 -3 jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/ClientInvocationHandler.java
Index: ClientInvocationHandler.java
===================================================================
RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/ClientInvocationHandler.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- ClientInvocationHandler.java 19 Jan 2003 11:09:59 -0000 1.4
+++ ClientInvocationHandler.java 19 Jan 2003 22:10:52 -0000 1.5
@@ -7,9 +7,9 @@
*/
package org.apache.excalibur.altrmi.client;
-import java.io.IOException;
import org.apache.excalibur.altrmi.common.InvocationHandler;
import org.apache.excalibur.altrmi.common.ConnectionException;
+import org.apache.excalibur.altrmi.common.CallbackException;
/**
* Interface ClientInvocationHandler
@@ -94,5 +94,25 @@
* @return Object new object that replaces the input argument.
*/
- public Object resolveArgument(String methodSignature,Class inputArgumentClass, Object inputArgumentInstance);
+ Object resolveArgument(String methodSignature,Class inputArgumentClass, Object inputArgumentInstance);
+
+ boolean isCallBackEnabled();
+
+ /**
+ * For CallBackEnabled only
+ *
+ * @param exposedObject
+ * @param exposedInterface
+ * @return
+ * @throws CallbackException
+ */
+ boolean exposeObject( Object exposedObject, Class exposedInterface ) throws CallbackException;
+
+ /**
+ * For CallBackEnabled only
+ * @param exposedObject
+ * @return
+ */
+ String getPublishedName( Object exposedObject );
+
}
1.13 +18 -1 jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/AbstractClientInvocationHandler.java
Index: AbstractClientInvocationHandler.java
===================================================================
RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/AbstractClientInvocationHandler.java,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- AbstractClientInvocationHandler.java 19 Jan 2003 11:09:59 -0000 1.12
+++ AbstractClientInvocationHandler.java 19 Jan 2003 22:10:52 -0000 1.13
@@ -19,6 +19,7 @@
import org.apache.excalibur.altrmi.common.FacadeRefHolder;
import org.apache.excalibur.altrmi.common.PingRequest;
import org.apache.excalibur.altrmi.common.ConnectionException;
+import org.apache.excalibur.altrmi.common.CallbackException;
/**
* Class AbstractClientInvocationHandler
@@ -141,4 +142,20 @@
{
return obj;
}
+
+ public boolean isCallBackEnabled()
+ {
+ return false;
+ }
+
+ public boolean exposeObject(Object exposedObject, Class exposedInterface) throws CallbackException
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public String getPublishedName(Object exposedObject)
+ {
+ throw new UnsupportedOperationException();
+ }
+
}
1.14 +7 -5 jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/callback/socket/CallbackEnabledSocketCustomStreamInvocationHandler.java
Index: CallbackEnabledSocketCustomStreamInvocationHandler.java
===================================================================
RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/callback/socket/CallbackEnabledSocketCustomStreamInvocationHandler.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- CallbackEnabledSocketCustomStreamInvocationHandler.java 5 Jan 2003 23:24:09 -0000 1.13
+++ CallbackEnabledSocketCustomStreamInvocationHandler.java 19 Jan 2003 22:10:52 -0000 1.14
@@ -7,11 +7,10 @@
*/
package org.apache.excalibur.altrmi.client.impl.callback.socket;
-import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
-import org.apache.excalibur.altrmi.client.CallbackEnabledClientInvocationHandler;
+import org.apache.excalibur.altrmi.client.ClientInvocationHandler;
import org.apache.excalibur.altrmi.client.impl.callback.stream.CallbackEnabledClientCustomStreamReadWriter;
import org.apache.excalibur.altrmi.client.impl.socket.AbstractSocketStreamInvocationHandler;
import org.apache.excalibur.altrmi.client.impl.ClientStreamReadWriter;
@@ -26,7 +25,7 @@
* @version $Revision$
*/
public final class CallbackEnabledSocketCustomStreamInvocationHandler
- extends AbstractSocketStreamInvocationHandler implements CallbackEnabledClientInvocationHandler
+ extends AbstractSocketStreamInvocationHandler implements ClientInvocationHandler
{
private CallbackEnabledClientCustomStreamReadWriter m_callbackEnabledClientCustomStreamReadWriter;
@@ -121,7 +120,10 @@
return inputArgumentInstance;
}
-
+ public boolean isCallBackEnabled()
+ {
+ return true;
+ }
}
1.10 +17 -1 jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/multiple/AbstractMultipleInvocationHandler.java
Index: AbstractMultipleInvocationHandler.java
===================================================================
RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/multiple/AbstractMultipleInvocationHandler.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- AbstractMultipleInvocationHandler.java 19 Jan 2003 11:10:00 -0000 1.9
+++ AbstractMultipleInvocationHandler.java 19 Jan 2003 22:10:52 -0000 1.10
@@ -12,6 +12,7 @@
import org.apache.excalibur.altrmi.client.ConnectionListener;
import org.apache.excalibur.altrmi.client.ConnectionPinger;
import org.apache.excalibur.altrmi.common.ConnectionException;
+import org.apache.excalibur.altrmi.common.CallbackException;
/**
* Class AbstractMultipleInvocationHandler
@@ -123,6 +124,21 @@
public Object resolveArgument(String methodSignature ,Class objClass , Object obj)
{
return obj;
+ }
+
+ public boolean isCallBackEnabled()
+ {
+ return false;
+ }
+
+ public boolean exposeObject(Object exposedObject, Class exposedInterface) throws CallbackException
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ public String getPublishedName(Object exposedObject)
+ {
+ throw new UnsupportedOperationException();
}
}
1.2 +16 -0 jakarta-avalon-excalibur/altrmi/src/test/org/apache/excalibur/altrmi/test/DummyInvocationHandler.java
Index: DummyInvocationHandler.java
===================================================================
RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/test/org/apache/excalibur/altrmi/test/DummyInvocationHandler.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- DummyInvocationHandler.java 19 Jan 2003 11:10:01 -0000 1.1
+++ DummyInvocationHandler.java 19 Jan 2003 22:10:53 -0000 1.2
@@ -10,6 +10,7 @@
import org.apache.excalibur.altrmi.common.Reply;
import org.apache.excalibur.altrmi.common.Request;
import org.apache.excalibur.altrmi.common.ConnectionException;
+import org.apache.excalibur.altrmi.common.CallbackException;
import org.apache.excalibur.altrmi.client.ClientInvocationHandler;
import org.apache.excalibur.altrmi.client.ConnectionListener;
import org.apache.excalibur.altrmi.client.ConnectionPinger;
@@ -81,6 +82,21 @@
public ConnectionListener getConnectionListener()
{
return m_connectionListener;
+ }
+
+ public boolean isCallBackEnabled()
+ {
+ return false;
+ }
+
+ public boolean exposeObject(Object exposedObject, Class exposedInterface) throws CallbackException
+ {
+ throw new java.lang.UnsupportedOperationException();
+ }
+
+ public String getPublishedName(Object exposedObject)
+ {
+ throw new java.lang.UnsupportedOperationException();
}
}
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>