1 30 31 32 package org.hsqldb.util; 33 34 import java.io.Serializable ; 35 import java.util.Vector ; 36 37 42 class DataAccessPoint implements Serializable { 43 44 Traceable tracer; 45 TransferHelper helper; 46 String databaseToConvert; 47 48 public DataAccessPoint() { 49 50 tracer = null; 51 helper = HelperFactory.getHelper(""); 52 databaseToConvert = ""; 53 } 54 55 public DataAccessPoint(Traceable t) { 56 57 tracer = t; 58 helper = HelperFactory.getHelper(""); 59 60 helper.set(null, t, "\'"); 61 62 databaseToConvert = ""; 63 } 64 65 boolean isConnected() { 66 return false; 67 } 68 69 boolean getAutoCommit() throws DataAccessPointException { 70 return false; 71 } 72 73 void commit() throws DataAccessPointException {} 74 75 void rollback() throws DataAccessPointException {} 76 77 void setAutoCommit(boolean flag) throws DataAccessPointException {} 78 79 boolean execute(String statement) throws DataAccessPointException { 80 return false; 81 } 82 83 TransferResultSet getData(String statement) 84 throws DataAccessPointException { 85 return null; 86 } 87 88 void putData(String statement, TransferResultSet r, 89 int iMaxRows) throws DataAccessPointException {} 90 91 Vector getSchemas() throws DataAccessPointException { 92 return new Vector (); 93 } 94 95 Vector getCatalog() throws DataAccessPointException { 96 return new Vector (); 97 } 98 99 void setCatalog(String sCatalog) throws DataAccessPointException {} 100 101 Vector getTables(String sCatalog, 102 String [] sSchemas) throws DataAccessPointException { 103 return new Vector (); 104 } 105 106 void getTableStructure(TransferTable SQLCommands, 107 DataAccessPoint Dest) 108 throws DataAccessPointException { 109 throw new DataAccessPointException("Nothing to Parse"); 110 } 111 112 void close() throws DataAccessPointException {} 113 114 void beginDataTransfer() throws DataAccessPointException { 115 116 try { 117 helper.beginDataTransfer(); 118 } catch (Exception e) { 119 throw new DataAccessPointException(e.getMessage()); 120 } 121 } 122 123 void endDataTransfer() throws DataAccessPointException { 124 125 try { 126 helper.endDataTransfer(); 127 } catch (Exception e) { 128 throw new DataAccessPointException(e.getMessage()); 129 } 130 } 131 132 135 public TransferHelper getHelper() { 136 return helper; 137 } 138 } 139 | Popular Tags |