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 .
21 #include <cppuhelper/implbase.hxx>
22 #include <cppuhelper/weakref.hxx>
23 #include <comphelper/uno3.hxx>
24 #include <com/sun/star/container/XChild.hpp>
25 #include <com/sun/star/util/XCloneable.hpp>
26 #include <com/sun/star/util/XModifyBroadcaster.hpp>
27 #include <com/sun/star/util/XModifyListener.hpp>
28 #include <com/sun/star/lang/XServiceInfo.hpp>
30 #include <OPropertySet.hxx>
31 #include <MutexContainer.hxx>
38 typedef ::cppu::WeakImplHelper
<
39 css::container::XChild
,
40 css::util::XCloneable
,
41 css::util::XModifyBroadcaster
,
42 css::util::XModifyListener
,
43 css::lang::XServiceInfo
>
47 class DataPoint final
:
48 public MutexContainer
,
49 public impl::DataPoint_Base
,
50 public ::property::OPropertySet
53 explicit DataPoint( const css::uno::Reference
< css::beans::XPropertySet
> & rParentProperties
);
54 virtual ~DataPoint() override
;
56 /// merge XInterface implementations
58 /// XServiceInfo declarations
59 virtual OUString SAL_CALL
getImplementationName() override
;
60 virtual sal_Bool SAL_CALL
supportsService( const OUString
& ServiceName
) override
;
61 virtual css::uno::Sequence
< OUString
> SAL_CALL
getSupportedServiceNames() override
;
64 explicit DataPoint( const DataPoint
& rOther
);
66 // ____ OPropertySet ____
67 virtual css::uno::Any
GetDefaultValue( sal_Int32 nHandle
) const override
;
68 virtual ::cppu::IPropertyArrayHelper
& SAL_CALL
getInfoHelper() override
;
69 virtual void SAL_CALL setFastPropertyValue_NoBroadcast
71 const css::uno::Any
& rValue
) override
;
73 // ____ XPropertySet ____
74 virtual css::uno::Reference
< css::beans::XPropertySetInfo
> SAL_CALL
75 getPropertySetInfo() override
;
77 // ____ XCloneable ____
78 // Note: m_xParentProperties are not cloned!
79 virtual css::uno::Reference
< css::util::XCloneable
> SAL_CALL
createClone() override
;
82 virtual css::uno::Reference
< css::uno::XInterface
> SAL_CALL
getParent() override
;
83 virtual void SAL_CALL
setParent(
84 const css::uno::Reference
< css::uno::XInterface
>& Parent
) override
;
86 // ____ XModifyBroadcaster ____
87 virtual void SAL_CALL
addModifyListener(
88 const css::uno::Reference
< css::util::XModifyListener
>& aListener
) override
;
89 virtual void SAL_CALL
removeModifyListener(
90 const css::uno::Reference
< css::util::XModifyListener
>& aListener
) override
;
92 // ____ XModifyListener ____
93 virtual void SAL_CALL
modified(
94 const css::lang::EventObject
& aEvent
) override
;
96 // ____ XEventListener (base of XModifyListener) ____
97 virtual void SAL_CALL
disposing(
98 const css::lang::EventObject
& Source
) override
;
100 // ____ OPropertySet ____
101 virtual void firePropertyChangeEvent() override
;
102 using OPropertySet::disposing
;
104 css::uno::WeakReference
< css::beans::XPropertySet
> m_xParentProperties
;
106 css::uno::Reference
< css::util::XModifyListener
> m_xModifyEventForwarder
;
107 bool m_bNoParentPropAllowed
;
112 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */