1 2 11 12 package org.objectweb.rmijdbc; 13 14 import java.sql.*; 15 import java.rmi.RemoteException ; 16 import java.rmi.server.UnicastRemoteObject ; 17 import java.rmi.server.Unreferenced ; 18 19 24 25 public class RJRefServer 26 extends UnicastRemoteObject 27 implements RJRefInterface, Unreferenced { 28 29 java.sql.Ref jdbcRef_; 30 31 public RJRefServer(java.sql.Ref r) throws RemoteException { 32 super(RJJdbcServer.rmiJdbcListenerPort, RJJdbcServer.rmiClientSocketFactory, RJJdbcServer.rmiServerSocketFactory); 33 jdbcRef_ = r; 34 } 35 36 public void unreferenced() { Runtime.getRuntime().gc(); } 37 38 public String getBaseTypeName() throws RemoteException , SQLException { 39 return jdbcRef_.getBaseTypeName(); 40 } 41 42 public Object getObject(java.util.Map map) throws RemoteException , SQLException { 44 return jdbcRef_.getObject(map); 45 } 46 47 public Object getObject() throws RemoteException , SQLException { 48 return jdbcRef_.getObject(); 49 } 50 51 public void setObject(Object value) throws RemoteException , SQLException { 52 jdbcRef_. setObject(value); 53 } 54 }; 55 56 | Popular Tags |