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 _DBA_CORE_DATASETTINGS_HXX_
21 #define _DBA_CORE_DATASETTINGS_HXX_
23 #include <com/sun/star/uno/Sequence.hxx>
24 #include <com/sun/star/beans/Property.hpp>
25 #include <com/sun/star/awt/FontDescriptor.hpp>
26 #include <com/sun/star/lang/IllegalArgumentException.hpp>
27 #include <rtl/ustring.hxx>
28 #include <comphelper/propertystatecontainer.hxx>
33 //==========================================================================
34 //= ODataSettings_Base - a base class which implements the property member
35 //= for an object implementing the sdb::DataSettings
37 //= the properties have to to be registered when used
38 //==========================================================================
39 class ODataSettings_Base
44 OUString m_sHavingClause
;
47 sal_Bool m_bApplyFilter
; // no BitField ! the base class needs a pointer to this member !
48 ::com::sun::star::awt::FontDescriptor m_aFont
;
49 ::com::sun::star::uno::Any m_aRowHeight
;
50 ::com::sun::star::uno::Any m_aTextColor
;
51 ::com::sun::star::uno::Any m_aTextLineColor
;
52 sal_Int16 m_nFontEmphasis
;
53 sal_Int16 m_nFontRelief
;
58 ODataSettings_Base(const ODataSettings_Base
& _rSource
);
59 ~ODataSettings_Base();
61 //==========================================================================
62 //= ODataSettings - a base class which implements the property handling
63 //= for an object implementing the sdb::DataSettings
65 //==========================================================================
67 class ODataSettings
: public ::comphelper::OPropertyStateContainer
68 , public ODataSettings_Base
72 ODataSettings(::cppu::OBroadcastHelper
& _rBHelper
,sal_Bool _bQuery
= sal_False
);
73 virtual void getPropertyDefaultByHandle( sal_Int32 _nHandle
, ::com::sun::star::uno::Any
& _rDefault
) const;
75 /** register the properties from the param given. The parameter instance must be alive as long as tis object live.
77 The database settings, can be <br>this</br>
79 void registerPropertiesFor(ODataSettings_Base
* _pItem
);
82 } // namespace dbaccess
84 #endif // _DBA_CORE_DATASETTINGS_HXX_
86 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */