User: vg      
Date: 05/03/23 01:41:08

Modified:
 /dba/connectivity/source/drivers/hsqldb/
  HStorageMap.cxx

Log:
 INTEGRATION: CWS dba26 (1.4.14); FILE MERGED
 2005/03/15 15:05:02 fs 1.4.14.1: #i44582# (patch provided by OJ) refined 
storage handling

File Changes:

Directory: /dba/connectivity/source/drivers/hsqldb/
===================================================

File [changed]: HStorageMap.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/connectivity/source/drivers/hsqldb/HStorageMap.cxx?r1=1.4&r2=1.5
Delta lines:  +15 -7
--------------------
--- HStorageMap.cxx     16 Feb 2005 15:51:25 -0000      1.4
+++ HStorageMap.cxx     23 Mar 2005 09:41:05 -0000      1.5
@@ -69,6 +69,9 @@
 #ifndef _COM_SUN_STAR_EMBED_XTRANSACTEDOBJECT_HPP_
 #include <com/sun/star/embed/XTransactedObject.hpp>
 #endif
+#ifndef _COM_SUN_STAR_EMBED_ELEMENTMODES_HPP_
+#include <com/sun/star/embed/ElementModes.hpp>
+#endif
 #ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
 #include <com/sun/star/lang/DisposedException.hpp>
 #endif
@@ -309,6 +312,9 @@
                                                {
                             try
                                                    {
+/*                                                             if ( _nMode == 
ElementModes::READ )
+                                                                       _nMode 
|= ElementModes::SEEKABLE;
+*/
                                                            pHelper.reset(new 
StreamHelper(aStoragePair.first.first->openStreamElement(sName,_nMode)));
                             }
                             catch(Exception& )
@@ -321,13 +327,7 @@
                                                catch(Exception& e)
                                                {
                                                        OSL_ENSURE(0,"Exception 
catched!");
-                                                       if (JNI_FALSE != 
env->ExceptionCheck())
-                                                               
env->ExceptionClear();
-                                                       ::rtl::OString cstr( 
::rtl::OUStringToOString(e.Message, RTL_TEXTENCODING_JAVA_UTF8 ) );
-                                                       OSL_TRACE( __FILE__": 
forwarding Exception: %s", cstr.getStr() );
-                                                       ThrowException( env,
-                                                                               
        "java/io/IOException",
-                                                                               
        cstr.getStr());
+                            StorageContainer::throwJavaException(e,env);
                                                }
                                        }
                                }
@@ -360,6 +360,14 @@
                        return pRet;
                }
                // 
-----------------------------------------------------------------------------
+        void StorageContainer::throwJavaException(const Exception& 
_aException,JNIEnv * env)
+        {
+            if (JNI_FALSE != env->ExceptionCheck())
+                           env->ExceptionClear();
+                   ::rtl::OString cstr( 
::rtl::OUStringToOString(_aException.Message, RTL_TEXTENCODING_JAVA_UTF8 ) );
+                   OSL_TRACE( __FILE__": forwarding Exception: %s", 
cstr.getStr() );
+            env->ThrowNew(env->FindClass("java/io/IOException"), 
cstr.getStr());
+        }
        
//........................................................................
        }       // namespace hsqldb
        
//........................................................................




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to