1*96de5490SAndrew Rist /**************************************************************
2cdf0e10cSrcweir *
3*96de5490SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
4*96de5490SAndrew Rist * or more contributor license agreements. See the NOTICE file
5*96de5490SAndrew Rist * distributed with this work for additional information
6*96de5490SAndrew Rist * regarding copyright ownership. The ASF licenses this file
7*96de5490SAndrew Rist * to you under the Apache License, Version 2.0 (the
8*96de5490SAndrew Rist * "License"); you may not use this file except in compliance
9*96de5490SAndrew Rist * with the License. You may obtain a copy of the License at
10cdf0e10cSrcweir *
11*96de5490SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0
12cdf0e10cSrcweir *
13*96de5490SAndrew Rist * Unless required by applicable law or agreed to in writing,
14*96de5490SAndrew Rist * software distributed under the License is distributed on an
15*96de5490SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*96de5490SAndrew Rist * KIND, either express or implied. See the License for the
17*96de5490SAndrew Rist * specific language governing permissions and limitations
18*96de5490SAndrew Rist * under the License.
19cdf0e10cSrcweir *
20*96de5490SAndrew Rist *************************************************************/
21*96de5490SAndrew Rist
22*96de5490SAndrew Rist
23cdf0e10cSrcweir
24cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove
25cdf0e10cSrcweir #include "precompiled_dbaccess.hxx"
26cdf0e10cSrcweir
27cdf0e10cSrcweir #include "dbastrings.hrc"
28cdf0e10cSrcweir #include "module_dba.hxx"
29cdf0e10cSrcweir
30cdf0e10cSrcweir /** === begin UNO includes === **/
31cdf0e10cSrcweir #include <com/sun/star/lang/XServiceInfo.hpp>
32cdf0e10cSrcweir #include <com/sun/star/beans/PropertyAttribute.hpp>
33cdf0e10cSrcweir #include <com/sun/star/sdb/CommandType.hpp>
34cdf0e10cSrcweir #include <com/sun/star/sdbc/XConnection.hpp>
35cdf0e10cSrcweir #include <com/sun/star/sdbc/XResultSet.hpp>
36cdf0e10cSrcweir #include <com/sun/star/sdb/XDataAccessDescriptorFactory.hpp>
37cdf0e10cSrcweir /** === end UNO includes === **/
38cdf0e10cSrcweir
39cdf0e10cSrcweir #include <comphelper/broadcasthelper.hxx>
40cdf0e10cSrcweir #include <comphelper/componentcontext.hxx>
41cdf0e10cSrcweir #include <comphelper/proparrhlp.hxx>
42cdf0e10cSrcweir #include <comphelper/propertycontainer.hxx>
43cdf0e10cSrcweir #include <comphelper/uno3.hxx>
44cdf0e10cSrcweir #include <cppuhelper/implbase1.hxx>
45cdf0e10cSrcweir #include <cppuhelper/implbase2.hxx>
46cdf0e10cSrcweir
47cdf0e10cSrcweir //........................................................................
48cdf0e10cSrcweir namespace dbaccess
49cdf0e10cSrcweir {
50cdf0e10cSrcweir //........................................................................
51cdf0e10cSrcweir
52cdf0e10cSrcweir /** === begin UNO using === **/
53cdf0e10cSrcweir using ::com::sun::star::uno::Reference;
54cdf0e10cSrcweir using ::com::sun::star::uno::XInterface;
55cdf0e10cSrcweir using ::com::sun::star::uno::UNO_QUERY;
56cdf0e10cSrcweir using ::com::sun::star::uno::UNO_QUERY_THROW;
57cdf0e10cSrcweir using ::com::sun::star::uno::UNO_SET_THROW;
58cdf0e10cSrcweir using ::com::sun::star::uno::Exception;
59cdf0e10cSrcweir using ::com::sun::star::uno::RuntimeException;
60cdf0e10cSrcweir using ::com::sun::star::uno::Any;
61cdf0e10cSrcweir using ::com::sun::star::uno::makeAny;
62cdf0e10cSrcweir using ::com::sun::star::uno::Sequence;
63cdf0e10cSrcweir using ::com::sun::star::lang::XServiceInfo;
64cdf0e10cSrcweir using ::com::sun::star::lang::XMultiServiceFactory;
65cdf0e10cSrcweir using ::com::sun::star::beans::XPropertySetInfo;
66cdf0e10cSrcweir using ::com::sun::star::beans::Property;
67cdf0e10cSrcweir using ::com::sun::star::sdbc::XConnection;
68cdf0e10cSrcweir using ::com::sun::star::sdbc::XResultSet;
69cdf0e10cSrcweir using ::com::sun::star::sdb::XDataAccessDescriptorFactory;
70cdf0e10cSrcweir using ::com::sun::star::beans::XPropertySet;
71cdf0e10cSrcweir using ::com::sun::star::uno::XComponentContext;
72cdf0e10cSrcweir using ::com::sun::star::beans::PropertyValue;
73cdf0e10cSrcweir /** === end UNO using === **/
74cdf0e10cSrcweir
75cdf0e10cSrcweir namespace PropertyAttribute = ::com::sun::star::beans::PropertyAttribute;
76cdf0e10cSrcweir namespace CommandType = ::com::sun::star::sdb::CommandType;
77cdf0e10cSrcweir
78cdf0e10cSrcweir //====================================================================
79cdf0e10cSrcweir //= DataAccessDescriptor
80cdf0e10cSrcweir //====================================================================
81cdf0e10cSrcweir typedef ::comphelper::OMutexAndBroadcastHelper DataAccessDescriptor_MutexBase;
82cdf0e10cSrcweir
83cdf0e10cSrcweir typedef ::cppu::WeakImplHelper1 < XServiceInfo
84cdf0e10cSrcweir > DataAccessDescriptor_TypeBase;
85cdf0e10cSrcweir
86cdf0e10cSrcweir typedef ::comphelper::OPropertyContainer DataAccessDescriptor_PropertyBase;
87cdf0e10cSrcweir
88cdf0e10cSrcweir class DataAccessDescriptor :public DataAccessDescriptor_MutexBase
89cdf0e10cSrcweir ,public DataAccessDescriptor_TypeBase
90cdf0e10cSrcweir ,public DataAccessDescriptor_PropertyBase
91cdf0e10cSrcweir ,public ::comphelper::OPropertyArrayUsageHelper< DataAccessDescriptor >
92cdf0e10cSrcweir {
93cdf0e10cSrcweir public:
94cdf0e10cSrcweir DataAccessDescriptor( const ::comphelper::ComponentContext& _rContext );
95cdf0e10cSrcweir
96cdf0e10cSrcweir // UNO
97cdf0e10cSrcweir DECLARE_XINTERFACE()
98cdf0e10cSrcweir DECLARE_XTYPEPROVIDER()
99cdf0e10cSrcweir
100cdf0e10cSrcweir // XServiceInfo
101cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName( ) throw (RuntimeException);
102cdf0e10cSrcweir virtual ::sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (RuntimeException);
103cdf0e10cSrcweir virtual Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames( ) throw (RuntimeException);
104cdf0e10cSrcweir
105cdf0e10cSrcweir protected:
106cdf0e10cSrcweir ~DataAccessDescriptor();
107cdf0e10cSrcweir
108cdf0e10cSrcweir protected:
109cdf0e10cSrcweir // XPropertySet
110cdf0e10cSrcweir virtual Reference< XPropertySetInfo > SAL_CALL getPropertySetInfo() throw(RuntimeException);
111cdf0e10cSrcweir virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper();
112cdf0e10cSrcweir
113cdf0e10cSrcweir // OPropertyArrayUsageHelper
114cdf0e10cSrcweir virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const;
115cdf0e10cSrcweir
116cdf0e10cSrcweir private:
117cdf0e10cSrcweir ::comphelper::ComponentContext m_aContext;
118cdf0e10cSrcweir
119cdf0e10cSrcweir // </properties>
120cdf0e10cSrcweir ::rtl::OUString m_sDataSourceName;
121cdf0e10cSrcweir ::rtl::OUString m_sDatabaseLocation;
122cdf0e10cSrcweir ::rtl::OUString m_sConnectionResource;
123cdf0e10cSrcweir Sequence< PropertyValue > m_aConnectionInfo;
124cdf0e10cSrcweir Reference< XConnection > m_xActiveConnection;
125cdf0e10cSrcweir ::rtl::OUString m_sCommand;
126cdf0e10cSrcweir sal_Int32 m_nCommandType;
127cdf0e10cSrcweir ::rtl::OUString m_sFilter;
128cdf0e10cSrcweir ::rtl::OUString m_sOrder;
129cdf0e10cSrcweir ::rtl::OUString m_sHavingClause;
130cdf0e10cSrcweir ::rtl::OUString m_sGroupBy;
131cdf0e10cSrcweir sal_Bool m_bEscapeProcessing;
132cdf0e10cSrcweir Reference< XResultSet > m_xResultSet;
133cdf0e10cSrcweir Sequence< Any > m_aSelection;
134cdf0e10cSrcweir sal_Bool m_bBookmarkSelection;
135cdf0e10cSrcweir ::rtl::OUString m_sColumnName;
136cdf0e10cSrcweir Reference< XPropertySet > m_xColumn;
137cdf0e10cSrcweir // </properties>
138cdf0e10cSrcweir };
139cdf0e10cSrcweir
140cdf0e10cSrcweir #define REGISTER_PROPERTY( propname, member ) \
141cdf0e10cSrcweir registerProperty( PROPERTY_##propname, PROPERTY_ID_##propname, PropertyAttribute::BOUND, &member, ::getCppuType( &member ) )
142cdf0e10cSrcweir
143cdf0e10cSrcweir //--------------------------------------------------------------------
DataAccessDescriptor(const::comphelper::ComponentContext & _rContext)144cdf0e10cSrcweir DataAccessDescriptor::DataAccessDescriptor( const ::comphelper::ComponentContext& _rContext )
145cdf0e10cSrcweir :DataAccessDescriptor_MutexBase()
146cdf0e10cSrcweir ,DataAccessDescriptor_TypeBase()
147cdf0e10cSrcweir ,DataAccessDescriptor_PropertyBase( m_aBHelper )
148cdf0e10cSrcweir ,m_aContext( _rContext )
149cdf0e10cSrcweir ,m_sDataSourceName()
150cdf0e10cSrcweir ,m_sDatabaseLocation()
151cdf0e10cSrcweir ,m_sConnectionResource()
152cdf0e10cSrcweir ,m_aConnectionInfo()
153cdf0e10cSrcweir ,m_xActiveConnection()
154cdf0e10cSrcweir ,m_sCommand()
155cdf0e10cSrcweir ,m_nCommandType( CommandType::COMMAND )
156cdf0e10cSrcweir ,m_sFilter()
157cdf0e10cSrcweir ,m_sOrder()
158cdf0e10cSrcweir ,m_sHavingClause()
159cdf0e10cSrcweir ,m_sGroupBy()
160cdf0e10cSrcweir ,m_bEscapeProcessing( sal_True )
161cdf0e10cSrcweir ,m_xResultSet()
162cdf0e10cSrcweir ,m_aSelection()
163cdf0e10cSrcweir ,m_bBookmarkSelection( sal_True )
164cdf0e10cSrcweir ,m_sColumnName()
165cdf0e10cSrcweir ,m_xColumn()
166cdf0e10cSrcweir {
167cdf0e10cSrcweir REGISTER_PROPERTY( DATASOURCENAME, m_sDataSourceName );
168cdf0e10cSrcweir REGISTER_PROPERTY( DATABASE_LOCATION, m_sDatabaseLocation );
169cdf0e10cSrcweir REGISTER_PROPERTY( CONNECTION_RESOURCE, m_sConnectionResource );
170cdf0e10cSrcweir REGISTER_PROPERTY( CONNECTION_INFO, m_aConnectionInfo );
171cdf0e10cSrcweir REGISTER_PROPERTY( ACTIVE_CONNECTION, m_xActiveConnection );
172cdf0e10cSrcweir REGISTER_PROPERTY( COMMAND, m_sCommand );
173cdf0e10cSrcweir REGISTER_PROPERTY( COMMAND_TYPE, m_nCommandType );
174cdf0e10cSrcweir REGISTER_PROPERTY( FILTER, m_sFilter );
175cdf0e10cSrcweir REGISTER_PROPERTY( ORDER, m_sOrder );
176cdf0e10cSrcweir REGISTER_PROPERTY( HAVING_CLAUSE, m_sHavingClause );
177cdf0e10cSrcweir REGISTER_PROPERTY( GROUP_BY, m_sGroupBy );
178cdf0e10cSrcweir REGISTER_PROPERTY( ESCAPE_PROCESSING, m_bEscapeProcessing );
179cdf0e10cSrcweir REGISTER_PROPERTY( RESULT_SET, m_xResultSet );
180cdf0e10cSrcweir REGISTER_PROPERTY( SELECTION, m_aSelection );
181cdf0e10cSrcweir REGISTER_PROPERTY( BOOKMARK_SELECTION, m_bBookmarkSelection );
182cdf0e10cSrcweir REGISTER_PROPERTY( COLUMN_NAME, m_sColumnName );
183cdf0e10cSrcweir REGISTER_PROPERTY( COLUMN, m_xColumn );
184cdf0e10cSrcweir }
185cdf0e10cSrcweir
186cdf0e10cSrcweir //--------------------------------------------------------------------
~DataAccessDescriptor()187cdf0e10cSrcweir DataAccessDescriptor::~DataAccessDescriptor()
188cdf0e10cSrcweir {
189cdf0e10cSrcweir }
190cdf0e10cSrcweir
191cdf0e10cSrcweir //--------------------------------------------------------------------
192cdf0e10cSrcweir IMPLEMENT_FORWARD_XINTERFACE2( DataAccessDescriptor, DataAccessDescriptor_TypeBase, DataAccessDescriptor_PropertyBase );
193cdf0e10cSrcweir
194cdf0e10cSrcweir //--------------------------------------------------------------------
195cdf0e10cSrcweir IMPLEMENT_FORWARD_XTYPEPROVIDER2( DataAccessDescriptor, DataAccessDescriptor_TypeBase, DataAccessDescriptor_PropertyBase );
196cdf0e10cSrcweir
197cdf0e10cSrcweir //--------------------------------------------------------------------
getImplementationName()198cdf0e10cSrcweir ::rtl::OUString SAL_CALL DataAccessDescriptor::getImplementationName() throw (RuntimeException)
199cdf0e10cSrcweir {
200cdf0e10cSrcweir return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dba.DataAccessDescriptor" ) );
201cdf0e10cSrcweir }
202cdf0e10cSrcweir
203cdf0e10cSrcweir //--------------------------------------------------------------------
supportsService(const::rtl::OUString & rServiceName)204cdf0e10cSrcweir ::sal_Bool SAL_CALL DataAccessDescriptor::supportsService( const ::rtl::OUString& rServiceName ) throw (RuntimeException)
205cdf0e10cSrcweir {
206cdf0e10cSrcweir Sequence< ::rtl::OUString > aServices( getSupportedServiceNames() );
207cdf0e10cSrcweir const ::rtl::OUString* pStart = aServices.getConstArray();
208cdf0e10cSrcweir const ::rtl::OUString* pEnd = aServices.getConstArray() + aServices.getLength();
209cdf0e10cSrcweir return ::std::find( pStart, pEnd, rServiceName ) != pEnd;
210cdf0e10cSrcweir }
211cdf0e10cSrcweir
212cdf0e10cSrcweir //--------------------------------------------------------------------
getSupportedServiceNames()213cdf0e10cSrcweir Sequence< ::rtl::OUString > SAL_CALL DataAccessDescriptor::getSupportedServiceNames( ) throw (RuntimeException)
214cdf0e10cSrcweir {
215cdf0e10cSrcweir Sequence< ::rtl::OUString > aServices(1);
216cdf0e10cSrcweir aServices[0] = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.DataAccessDescriptor" ) );
217cdf0e10cSrcweir return aServices;
218cdf0e10cSrcweir }
219cdf0e10cSrcweir
220cdf0e10cSrcweir //-------------------------------------------------------------------------
getPropertySetInfo()221cdf0e10cSrcweir Reference< XPropertySetInfo > SAL_CALL DataAccessDescriptor::getPropertySetInfo() throw(RuntimeException)
222cdf0e10cSrcweir {
223cdf0e10cSrcweir Reference< XPropertySetInfo > xInfo( createPropertySetInfo( getInfoHelper() ) );
224cdf0e10cSrcweir return xInfo;
225cdf0e10cSrcweir }
226cdf0e10cSrcweir
227cdf0e10cSrcweir //-------------------------------------------------------------------------
getInfoHelper()228cdf0e10cSrcweir ::cppu::IPropertyArrayHelper& DataAccessDescriptor::getInfoHelper()
229cdf0e10cSrcweir {
230cdf0e10cSrcweir return *getArrayHelper();
231cdf0e10cSrcweir }
232cdf0e10cSrcweir
233cdf0e10cSrcweir //------------------------------------------------------------------------------
createArrayHelper() const234cdf0e10cSrcweir ::cppu::IPropertyArrayHelper* DataAccessDescriptor::createArrayHelper( ) const
235cdf0e10cSrcweir {
236cdf0e10cSrcweir Sequence< Property > aProps;
237cdf0e10cSrcweir describeProperties( aProps );
238cdf0e10cSrcweir return new ::cppu::OPropertyArrayHelper( aProps );
239cdf0e10cSrcweir }
240cdf0e10cSrcweir
241cdf0e10cSrcweir //====================================================================
242cdf0e10cSrcweir //= DataAccessDescriptorFactory
243cdf0e10cSrcweir //====================================================================
244cdf0e10cSrcweir typedef ::cppu::WeakImplHelper2 < XServiceInfo
245cdf0e10cSrcweir , XDataAccessDescriptorFactory
246cdf0e10cSrcweir > DataAccessDescriptorFactory_Base;
247cdf0e10cSrcweir class DataAccessDescriptorFactory : public DataAccessDescriptorFactory_Base
248cdf0e10cSrcweir {
249cdf0e10cSrcweir public:
250cdf0e10cSrcweir // XServiceInfo
251cdf0e10cSrcweir virtual ::rtl::OUString SAL_CALL getImplementationName( ) throw (RuntimeException);
252cdf0e10cSrcweir virtual ::sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName ) throw (RuntimeException);
253cdf0e10cSrcweir virtual Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames( ) throw (RuntimeException);
254cdf0e10cSrcweir
255cdf0e10cSrcweir // XServiceInfo - static versions
256cdf0e10cSrcweir static Sequence< ::rtl::OUString > getSupportedServiceNames_static(void) throw( RuntimeException );
257cdf0e10cSrcweir static ::rtl::OUString getImplementationName_static(void) throw( RuntimeException );
258cdf0e10cSrcweir static Reference< XInterface > Create(const Reference< XComponentContext >& _rxContext);
259cdf0e10cSrcweir static ::rtl::OUString getSingletonName_static();
260cdf0e10cSrcweir
261cdf0e10cSrcweir // XDataAccessDescriptorFactory
262cdf0e10cSrcweir virtual Reference< XPropertySet > SAL_CALL createDataAccessDescriptor( ) throw (RuntimeException);
263cdf0e10cSrcweir
264cdf0e10cSrcweir protected:
265cdf0e10cSrcweir DataAccessDescriptorFactory( const Reference< XComponentContext >& _rxContext );
266cdf0e10cSrcweir ~DataAccessDescriptorFactory();
267cdf0e10cSrcweir
268cdf0e10cSrcweir private:
269cdf0e10cSrcweir ::comphelper::ComponentContext m_aContext;
270cdf0e10cSrcweir };
271cdf0e10cSrcweir
272cdf0e10cSrcweir //--------------------------------------------------------------------
DataAccessDescriptorFactory(const Reference<XComponentContext> & _rxContext)273cdf0e10cSrcweir DataAccessDescriptorFactory::DataAccessDescriptorFactory( const Reference< XComponentContext >& _rxContext )
274cdf0e10cSrcweir :m_aContext( _rxContext )
275cdf0e10cSrcweir {
276cdf0e10cSrcweir }
277cdf0e10cSrcweir
278cdf0e10cSrcweir //--------------------------------------------------------------------
~DataAccessDescriptorFactory()279cdf0e10cSrcweir DataAccessDescriptorFactory::~DataAccessDescriptorFactory()
280cdf0e10cSrcweir {
281cdf0e10cSrcweir }
282cdf0e10cSrcweir
283cdf0e10cSrcweir //--------------------------------------------------------------------
getSingletonName_static()284cdf0e10cSrcweir ::rtl::OUString DataAccessDescriptorFactory::getSingletonName_static()
285cdf0e10cSrcweir {
286cdf0e10cSrcweir return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.DataAccessDescriptorFactory" ) );
287cdf0e10cSrcweir }
288cdf0e10cSrcweir
289cdf0e10cSrcweir //--------------------------------------------------------------------
getSupportedServiceNames_static()290cdf0e10cSrcweir Sequence< ::rtl::OUString > DataAccessDescriptorFactory::getSupportedServiceNames_static() throw( RuntimeException )
291cdf0e10cSrcweir {
292cdf0e10cSrcweir Sequence< ::rtl::OUString > aServices(1);
293cdf0e10cSrcweir aServices[0] = getSingletonName_static();
294cdf0e10cSrcweir return aServices;
295cdf0e10cSrcweir }
296cdf0e10cSrcweir
297cdf0e10cSrcweir //--------------------------------------------------------------------
getImplementationName_static()298cdf0e10cSrcweir ::rtl::OUString DataAccessDescriptorFactory::getImplementationName_static() throw( RuntimeException )
299cdf0e10cSrcweir {
300cdf0e10cSrcweir return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dba.DataAccessDescriptorFactory" ) );
301cdf0e10cSrcweir }
302cdf0e10cSrcweir
303cdf0e10cSrcweir //--------------------------------------------------------------------
Create(const Reference<XComponentContext> & _rxContext)304cdf0e10cSrcweir Reference< XInterface > DataAccessDescriptorFactory::Create( const Reference< XComponentContext >& _rxContext )
305cdf0e10cSrcweir {
306cdf0e10cSrcweir return *( new DataAccessDescriptorFactory( _rxContext ) );
307cdf0e10cSrcweir }
308cdf0e10cSrcweir
309cdf0e10cSrcweir //--------------------------------------------------------------------
getImplementationName()310cdf0e10cSrcweir ::rtl::OUString SAL_CALL DataAccessDescriptorFactory::getImplementationName() throw (RuntimeException)
311cdf0e10cSrcweir {
312cdf0e10cSrcweir return getImplementationName_static();
313cdf0e10cSrcweir }
314cdf0e10cSrcweir
315cdf0e10cSrcweir //--------------------------------------------------------------------
supportsService(const::rtl::OUString & rServiceName)316cdf0e10cSrcweir ::sal_Bool SAL_CALL DataAccessDescriptorFactory::supportsService( const ::rtl::OUString& rServiceName ) throw (RuntimeException)
317cdf0e10cSrcweir {
318cdf0e10cSrcweir Sequence< ::rtl::OUString > aServices( getSupportedServiceNames_static() );
319cdf0e10cSrcweir const ::rtl::OUString* pStart = aServices.getConstArray();
320cdf0e10cSrcweir const ::rtl::OUString* pEnd = aServices.getConstArray() + aServices.getLength();
321cdf0e10cSrcweir return ::std::find( pStart, pEnd, rServiceName ) != pEnd;
322cdf0e10cSrcweir }
323cdf0e10cSrcweir
324cdf0e10cSrcweir //--------------------------------------------------------------------
getSupportedServiceNames()325cdf0e10cSrcweir Sequence< ::rtl::OUString > SAL_CALL DataAccessDescriptorFactory::getSupportedServiceNames( ) throw (RuntimeException)
326cdf0e10cSrcweir {
327cdf0e10cSrcweir return getSupportedServiceNames_static();
328cdf0e10cSrcweir }
329cdf0e10cSrcweir
330cdf0e10cSrcweir //--------------------------------------------------------------------
createDataAccessDescriptor()331cdf0e10cSrcweir Reference< XPropertySet > SAL_CALL DataAccessDescriptorFactory::createDataAccessDescriptor( ) throw (RuntimeException)
332cdf0e10cSrcweir {
333cdf0e10cSrcweir return new DataAccessDescriptor( m_aContext );
334cdf0e10cSrcweir }
335cdf0e10cSrcweir
336cdf0e10cSrcweir //........................................................................
337cdf0e10cSrcweir } // namespace dbaccess
338cdf0e10cSrcweir //........................................................................
339cdf0e10cSrcweir
340cdf0e10cSrcweir //--------------------------------------------------------------------------
createRegistryInfo_DataAccessDescriptorFactory()341cdf0e10cSrcweir extern "C" void SAL_CALL createRegistryInfo_DataAccessDescriptorFactory()
342cdf0e10cSrcweir {
343cdf0e10cSrcweir static ::dba::OSingletonRegistration< ::dbaccess::DataAccessDescriptorFactory > aAutoRegistration;
344cdf0e10cSrcweir }
345