1 package org.enhydra.spi.conf; 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 ConfFilePRODelegate implements PortableRemoteObjectDelegate { 16 17 22 public void exportObject(Remote obj) throws RemoteException { 23 24 } 25 26 27 32 public void unexportObject(Remote obj) throws NoSuchObjectException { 33 34 } 35 36 42 public void connect(Remote target,Remote source) throws RemoteException { 43 44 } 45 46 47 54 public Object narrow(Object obj, Class newClass ) throws ClassCastException { 55 if (newClass.isAssignableFrom(obj.getClass())) { 56 return obj; 57 } else { 58 throw new ClassCastException ("Can't cast "+obj.getClass().getName()+" in "+newClass.getName()); 59 } 60 } 61 62 68 public Remote toStub(Remote obj) throws NoSuchObjectException { 69 return obj; 70 } 71 } 72 | Popular Tags |