Date: Thursday, February 16, 2006 @ 11:55:59
  Author: gilles
    Path: /cvsroot/carob/carob

Modified: include/Connection.hpp (1.58 -> 1.59) src/Connection.cpp (1.65
          -> 1.66)

Added missing ControllerException to signature of receiveResultSet() and 
methods that call it
Call to receiveResultSet() in statementExecuteQuery() instead of re-writing the 
function...


------------------------+
 include/Connection.hpp |   10 ++++++----
 src/Connection.cpp     |   21 ++++++---------------
 2 files changed, 12 insertions(+), 19 deletions(-)


Index: carob/include/Connection.hpp
diff -u carob/include/Connection.hpp:1.58 carob/include/Connection.hpp:1.59
--- carob/include/Connection.hpp:1.58   Wed Feb 15 12:34:46 2006
+++ carob/include/Connection.hpp        Thu Feb 16 11:55:59 2006
@@ -309,8 +309,9 @@
    * @param sqlTemplate sql template of the PreparedStatement
    */
   DriverResultSet*  preparedStatementGetMetaData(const std::wstring 
&sqlTemplate)
-                          throw (SocketIOException, BackendException, 
ProtocolException, 
-                            NotImplementedException, UnexpectedException);
+                          throw (SocketIOException, BackendException,
+                          ProtocolException, ControllerException,
+                          NotImplementedException, UnexpectedException);
     
 protected:
   /**
@@ -498,8 +499,9 @@
    * @throws CarobException received from the controller
    */
   DriverResultSet*    receiveResultSet() throw (SocketIOException,
-                          BackendException, ProtocolException, 
-                          NotImplementedException, UnexpectedException);
+                          BackendException, ControllerException,
+                          ProtocolException, NotImplementedException,
+                          UnexpectedException);
   /**
    * Check if the given commit has been successfully performed.
    *
Index: carob/src/Connection.cpp
diff -u carob/src/Connection.cpp:1.65 carob/src/Connection.cpp:1.66
--- carob/src/Connection.cpp:1.65       Wed Feb 15 11:03:42 2006
+++ carob/src/Connection.cpp    Thu Feb 16 11:55:59 2006
@@ -561,8 +561,8 @@
 }
 
 DriverResultSet* Connection::preparedStatementGetMetaData(const wstring 
&sqlTemplate)
-    throw (SocketIOException, BackendException, ProtocolException, 
NotImplementedException,
-    UnexpectedException)
+    throw (SocketIOException, BackendException, ControllerException, 
+    ProtocolException, NotImplementedException, UnexpectedException)
 {
   checkIfConnected();
   wstring fctName(L"Connection::PreparedStatementGetMetaData");
@@ -613,17 +613,8 @@
       logDebug(fctName, L"Executing read request "
           + static_cast<wstring>(request));
 
-    TypeTag tag(*driverSocketPtr);
-    switch(tag)
-    {
-      case TT_RESULTSET:
-          retVal = new DriverResultSet(this);
-        break;
-      //case TT_NULL_RESULTSET: nothing to do, just return NULL
-      case TT_EXCEPTION:
-        receiveException();
-        break;
-    }
+    retVal = receiveResultSet();
+
   FO_CATCH_NTIMES
   return retVal;
 }
@@ -851,8 +842,8 @@
 }
 
 DriverResultSet* Connection::receiveResultSet()
-    throw (SocketIOException, BackendException, ProtocolException, 
-    NotImplementedException, UnexpectedException)
+    throw (SocketIOException, BackendException, ControllerException,
+    ProtocolException, NotImplementedException, UnexpectedException)
 {
   TypeTag tag(*driverSocketPtr);
 

_______________________________________________
Carob-commits mailing list
[email protected]
https://forge.continuent.org/mailman/listinfo/carob-commits

Reply via email to