Update ooo320-m1
[ooovba.git] / connectivity / source / inc / mysql / YCatalog.hxx
blob3a9180265799c93194c7ba25b09f1a3bde770ef5
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: YCatalog.hxx,v $
10 * $Revision: 1.3 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef CONNECTIVITY_MYSQL_CATALOG_HXX
31 #define CONNECTIVITY_MYSQL_CATALOG_HXX
33 #include "connectivity/sdbcx/VCatalog.hxx"
34 #include "connectivity/StdTypeDefs.hxx"
36 namespace connectivity
38 namespace mysql
40 // please don't name the class the same name as in an other namespaces
41 // some compilers have problems with this task as I noticed on windows
42 class OAdabasConnection;
43 class OMySQLCatalog : public connectivity::sdbcx::OCatalog
45 ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection > m_xConnection;
47 /** calls XDatabaseMetaData::getTables.
48 @param _sKindOfObject
49 The type of tables to be fetched.
50 @param _rNames
51 The container for the names to be filled. <OUT/>
53 void refreshObjects(const ::com::sun::star::uno::Sequence< ::rtl::OUString >& _sKindOfObject,TStringVector& _rNames);
55 public:
56 // implementation of the pure virtual methods
57 virtual void refreshTables();
58 virtual void refreshViews() ;
59 virtual void refreshGroups();
60 virtual void refreshUsers() ;
62 public:
63 OMySQLCatalog(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _xConnection);
65 inline sdbcx::OCollection* getPrivateTables() const { return m_pTables;}
66 inline sdbcx::OCollection* getPrivateViews() const { return m_pViews; }
67 inline ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection > getConnection() const { return m_xConnection; }
69 virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException);
70 // ::cppu::OComponentHelper
71 virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes( ) throw(::com::sun::star::uno::RuntimeException);
75 #endif // CONNECTIVITY_MYSQL_CATALOG_HXX