KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > rmijdbc > RJParameterMetaDataServer


1
2 /**
3  * RmiJdbc client/server JDBC Driver
4  * (C) ObjectWeb 1999-2003
5  *
6  * @version 3.0
7  * @author Pierre-Yves Gibello (pierreyves.gibello@experlog.com)
8  */

9
10 package org.objectweb.rmijdbc;
11
12 import java.sql.*;
13 import java.rmi.RemoteException JavaDoc;
14 import java.rmi.server.UnicastRemoteObject JavaDoc;
15 import java.rmi.server.Unreferenced JavaDoc;
16
17 public class RJParameterMetaDataServer
18 extends UnicastRemoteObject JavaDoc
19 implements RJParameterMetaDataInterface, Unreferenced JavaDoc {
20
21   ParameterMetaData jdbcParameterMetaData_;
22
23   public RJParameterMetaDataServer(ParameterMetaData s) throws RemoteException JavaDoc {
24     super(RJJdbcServer.rmiJdbcListenerPort,
25      RJJdbcServer.rmiClientSocketFactory, RJJdbcServer.rmiServerSocketFactory);
26     jdbcParameterMetaData_ = s;
27   }
28
29   public void unreferenced() { Runtime.getRuntime().gc(); }
30
31   public String JavaDoc getParameterClassName(int param)
32   throws RemoteException JavaDoc, SQLException {
33     return jdbcParameterMetaData_.getParameterClassName(param);
34   }
35
36   public int getParameterCount() throws RemoteException JavaDoc, SQLException {
37     return jdbcParameterMetaData_.getParameterCount();
38   }
39
40   public int getParameterMode(int param) throws RemoteException JavaDoc, SQLException {
41     return jdbcParameterMetaData_.getParameterMode(param);
42   }
43
44   public int getParameterType(int param) throws RemoteException JavaDoc, SQLException {
45     return jdbcParameterMetaData_.getParameterType(param);
46   }
47
48   public String JavaDoc getParameterTypeName(int param)
49   throws RemoteException JavaDoc, SQLException {
50     return jdbcParameterMetaData_.getParameterTypeName(param);
51   }
52
53   public int getPrecision(int param) throws RemoteException JavaDoc, SQLException {
54     return jdbcParameterMetaData_.getPrecision(param);
55   }
56
57   public int getScale(int param) throws RemoteException JavaDoc, SQLException {
58     return jdbcParameterMetaData_.getScale(param);
59   }
60
61   public int isNullable(int param) throws RemoteException JavaDoc, SQLException {
62     return jdbcParameterMetaData_.isNullable(param);
63   }
64
65   public boolean isSigned(int param) throws RemoteException JavaDoc, SQLException {
66     return jdbcParameterMetaData_.isSigned(param);
67   }
68
69 };
70
71
Popular Tags