1 package org.enhydra.spi.webxml; 2 3 import java.rmi.NoSuchObjectException ; 5 import java.rmi.Remote ; 6 import java.rmi.RemoteException ; 7 8 import javax.rmi.CORBA.PortableRemoteObjectDelegate ; 9 10 11 15 public class WebXmlPRODelegate implements PortableRemoteObjectDelegate { 16 17 23 public void exportObject(Remote obj) throws RemoteException { 24 } 25 26 31 public void unexportObject(Remote obj) throws NoSuchObjectException { 32 } 33 34 40 public void connect(Remote target,Remote source) throws RemoteException { 41 } 42 43 51 public Object narrow(Object obj, Class newClass ) throws ClassCastException { 52 if (newClass.isAssignableFrom(obj.getClass())) { 53 return obj; 54 } else { 55 throw new ClassCastException ("Can't cast "+obj.getClass().getName()+" in "+newClass.getName()); 56 } 57 } 58 59 65 public Remote toStub(Remote obj) throws NoSuchObjectException { 66 return obj; 67 } 68 } 69 | Popular Tags |