1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef INCLUDED_CONNECTIVITY_SDBCX_VVIEW_HXX
21 #define INCLUDED_CONNECTIVITY_SDBCX_VVIEW_HXX
23 #include <osl/diagnose.h>
24 #include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
25 #include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
26 #include <comphelper/proparrhlp.hxx>
27 #include <cppuhelper/compbase1.hxx>
28 #include <connectivity/CommonTools.hxx>
29 #include <cppuhelper/interfacecontainer.h>
30 #include <com/sun/star/container/XNamed.hpp>
31 #include <connectivity/sdbcx/VDescriptor.hxx>
32 #include <connectivity/dbtoolsdllapi.hxx>
33 #include <comphelper/IdPropArrayHelper.hxx>
34 #include <cppuhelper/implbase2.hxx>
36 namespace connectivity
41 typedef ::cppu::WeakImplHelper2
< ::com::sun::star::lang::XServiceInfo
,
42 ::com::sun::star::container::XNamed
> OView_BASE
;
46 class OOO_DLLPUBLIC_DBTOOLS OView
:
47 public ::comphelper::OMutexAndBroadcastHelper
,
49 public ::comphelper::OIdPropertyArrayUsageHelper
<OView
>,
53 OUString m_CatalogName
;
54 OUString m_SchemaName
;
56 sal_Int32 m_CheckOption
;
57 // need for the getName method
58 ::com::sun::star::uno::Reference
< ::com::sun::star::sdbc::XDatabaseMetaData
> m_xMetaData
;
60 // OPropertyArrayUsageHelper
61 virtual ::cppu::IPropertyArrayHelper
* createArrayHelper( sal_Int32 _nId
) const SAL_OVERRIDE
;
63 virtual ::cppu::IPropertyArrayHelper
& SAL_CALL
getInfoHelper() SAL_OVERRIDE
;
66 DECLARE_SERVICE_INFO();
68 OView(bool _bCase
,const ::com::sun::star::uno::Reference
< ::com::sun::star::sdbc::XDatabaseMetaData
>& _xMetaData
);
70 const OUString
& _rName
,
71 const ::com::sun::star::uno::Reference
< ::com::sun::star::sdbc::XDatabaseMetaData
>& _xMetaData
,
72 sal_Int32 _nCheckOption
= 0,
73 const OUString
& _rCommand
= OUString(),
74 const OUString
& _rSchemaName
= OUString(),
75 const OUString
& _rCatalogName
= OUString());
79 virtual void construct() SAL_OVERRIDE
;
82 virtual ::com::sun::star::uno::Any SAL_CALL
queryInterface( const ::com::sun::star::uno::Type
& rType
) throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
83 virtual void SAL_CALL
acquire() throw() SAL_OVERRIDE
;
84 virtual void SAL_CALL
release() throw() SAL_OVERRIDE
;
86 virtual ::com::sun::star::uno::Sequence
< ::com::sun::star::uno::Type
> SAL_CALL
getTypes( ) throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
88 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::beans::XPropertySetInfo
> SAL_CALL
getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
90 virtual OUString SAL_CALL
getName( ) throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
91 virtual void SAL_CALL
setName( const OUString
& ) throw(::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
96 #endif // INCLUDED_CONNECTIVITY_SDBCX_VVIEW_HXX
98 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */