tdf#130857 qt weld: Support mail merge "Server Auth" dialog
[LibreOffice.git] / connectivity / inc / sdbcx / VIndex.hxx
blobfd9bebe73ec2a28a022250508655cc96a12f850a
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 #pragma once
22 #include <config_options.h>
23 #include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
24 #include <comphelper/IdPropArrayHelper.hxx>
25 #include <cppuhelper/basemutex.hxx>
26 #include <connectivity/CommonTools.hxx>
27 #include <sdbcx/VTypeDef.hxx>
28 #include <connectivity/sdbcx/IRefreshable.hxx>
29 #include <connectivity/sdbcx/VDescriptor.hxx>
30 #include <connectivity/dbtoolsdllapi.hxx>
31 #include <cppuhelper/implbase1.hxx>
33 namespace connectivity::sdbcx
35 class OCollection;
36 class OIndex;
37 typedef ::cppu::ImplHelper1< css::sdbcx::XDataDescriptorFactory > OIndex_BASE;
38 typedef ::comphelper::OIdPropertyArrayUsageHelper<OIndex> OIndex_PROP;
40 class UNLESS_MERGELIBS_MORE(OOO_DLLPUBLIC_DBTOOLS) OIndex :
41 public cppu::BaseMutex,
42 public ODescriptor_BASE,
43 public IRefreshableColumns,
44 public OIndex_PROP,
45 public ODescriptor,
46 public OIndex_BASE
48 protected:
49 OUString m_Catalog;
50 bool m_IsUnique;
51 bool m_IsPrimaryKeyIndex;
52 bool m_IsClustered;
54 // no Reference! see OCollection::acquire
55 std::unique_ptr<OCollection> m_pColumns;
57 using ODescriptor_BASE::rBHelper;
58 virtual void refreshColumns() override;
59 // OPropertyArrayUsageHelper
60 virtual ::cppu::IPropertyArrayHelper* createArrayHelper( sal_Int32 _nId) const override;
61 virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() override;
62 public:
63 OIndex(bool _bCase);
64 OIndex( const OUString& Name,
65 OUString Catalog,
66 bool _isUnique,
67 bool _isPrimaryKeyIndex,
68 bool _isClustered,
69 bool _bCase);
71 virtual ~OIndex( ) override;
73 DECLARE_SERVICE_INFO();
75 //XInterface
76 virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type & rType ) override;
77 virtual void SAL_CALL acquire() noexcept override;
78 virtual void SAL_CALL release() noexcept override;
79 //XTypeProvider
80 virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes( ) override;
81 // ODescriptor
82 virtual void construct() override;
83 // ::cppu::OComponentHelper
84 virtual void SAL_CALL disposing() override;
85 // XPropertySet
86 virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) override;
87 // XColumnsSupplier
88 virtual css::uno::Reference< css::container::XNameAccess > SAL_CALL getColumns( ) override;
90 // XNamed
91 virtual OUString SAL_CALL getName( ) override;
92 virtual void SAL_CALL setName( const OUString& aName ) override;
93 // XDataDescriptorFactory
94 virtual css::uno::Reference< css::beans::XPropertySet > SAL_CALL createDataDescriptor( ) override;
99 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */