Tag: cws_src680_rptchart01
User: oj      
Date: 2008-02-13 07:45:19+0000
Modified:
   dba/dbaccess/source/sdbtools/connection/connectiontools.cxx
   dba/dbaccess/source/sdbtools/connection/connectiontools.hxx

Log:
 #i85225# impl new method

File Changes:

Directory: /dba/dbaccess/source/sdbtools/connection/
====================================================

File [changed]: connectiontools.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/sdbtools/connection/connectiontools.cxx?r1=1.4&r2=1.4.32.1
Delta lines:  +26 -3
--------------------
--- connectiontools.cxx 2007-11-21 15:45:12+0000        1.4
+++ connectiontools.cxx 2008-02-13 07:45:17+0000        1.4.32.1
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: connectiontools.cxx,v $
  *
- *  $Revision: 1.4 $
+ *  $Revision: 1.4.32.1 $
  *
- *  last change: $Author: ihi $ $Date: 2007/11/21 15:45:12 $
+ *  last change: $Author: oj $ $Date: 2008/02/13 07:45:17 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -57,6 +57,9 @@
 #include <comphelper/namedvaluecollection.hxx>
 #endif
 
+#include <connectivity/dbtools.hxx>
+#include <connectivity/statementcomposer.hxx>
+
 #include <algorithm>
 
 extern "C" void SAL_CALL createRegistryInfo_ConnectionTools()
@@ -70,6 +73,8 @@
 //........................................................................
 
        /** === begin UNO using === **/
+    using namespace ::com::sun::star;
+    using namespace ::com::sun::star::uno;
     using ::com::sun::star::uno::Reference;
     using ::com::sun::star::uno::RuntimeException;
     using ::com::sun::star::sdb::tools::XTableName;
@@ -118,6 +123,24 @@
         EntryGuard aGuard( *this );
         return new DataSourceMetaData( getContext(), getConnection() );
     }
+    //--------------------------------------------------------------------
+    Reference< container::XNameAccess > SAL_CALL 
ConnectionTools::getFieldsByCommandDescriptor( ::sal_Int32 commandType, const 
::rtl::OUString& command, Reference< lang::XComponent >& keepFieldsAlive ) 
throw (sdbc::SQLException, RuntimeException)
+    {
+        EntryGuard aGuard( *this );
+        ::dbtools::SQLExceptionInfo aErrorInfo;
+        Reference< container::XNameAccess > xRet = 
::dbtools::getFieldsByCommandDescriptor(getConnection(),commandType,command,keepFieldsAlive,&aErrorInfo);
+        if ( aErrorInfo.isValid() )
+            aErrorInfo.doThrow();
+        return xRet;
+    }
+    //--------------------------------------------------------------------
+    Reference< sdb::XSingleSelectQueryComposer > SAL_CALL 
ConnectionTools::getComposer( ::sal_Int32 commandType, const ::rtl::OUString& 
command ) throw (::com::sun::star::uno::RuntimeException)
+    {
+        EntryGuard aGuard( *this );
+        dbtools::StatementComposer aComposer(getConnection(), command, 
commandType, sal_True );
+        aComposer.setDisposeComposer(sal_False);
+        return aComposer.getComposer();
+    }
 
     //--------------------------------------------------------------------
     ::rtl::OUString SAL_CALL ConnectionTools::getImplementationName() throw 
(RuntimeException)

File [changed]: connectiontools.hxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/sdbtools/connection/connectiontools.hxx?r1=1.3&r2=1.3.32.1
Delta lines:  +5 -3
-------------------
--- connectiontools.hxx 2007-11-21 15:45:31+0000        1.3
+++ connectiontools.hxx 2008-02-13 07:45:17+0000        1.3.32.1
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: connectiontools.hxx,v $
  *
- *  $Revision: 1.3 $
+ *  $Revision: 1.3.32.1 $
  *
- *  last change: $Author: ihi $ $Date: 2007/11/21 15:45:31 $
+ *  last change: $Author: oj $ $Date: 2008/02/13 07:45:17 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -99,6 +99,8 @@
         virtual ::com::sun::star::uno::Reference< 
::com::sun::star::sdb::tools::XTableName > SAL_CALL createTableName() throw 
(::com::sun::star::uno::RuntimeException);
         virtual ::com::sun::star::uno::Reference< 
::com::sun::star::sdb::tools::XObjectNames > SAL_CALL getObjectNames() throw 
(::com::sun::star::uno::RuntimeException);
         virtual ::com::sun::star::uno::Reference< 
::com::sun::star::sdb::tools::XDataSourceMetaData > SAL_CALL 
getDataSourceMetaData() throw (::com::sun::star::uno::RuntimeException);
+        virtual ::com::sun::star::uno::Reference< 
::com::sun::star::container::XNameAccess > SAL_CALL 
getFieldsByCommandDescriptor( ::sal_Int32 commandType, const ::rtl::OUString& 
command, ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent 
>& keepFieldsAlive ) throw (::com::sun::star::sdbc::SQLException, 
::com::sun::star::uno::RuntimeException);
+        virtual ::com::sun::star::uno::Reference< 
::com::sun::star::sdb::XSingleSelectQueryComposer > SAL_CALL getComposer( 
::sal_Int32 commandType, const ::rtl::OUString& command ) throw 
(::com::sun::star::uno::RuntimeException);
 
         // XServiceInfo
         virtual ::rtl::OUString SAL_CALL getImplementationName() throw 
(::com::sun::star::uno::RuntimeException);




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

Reply via email to