Version 6.4.0.0.beta1, tag libreoffice-6.4.0.0.beta1
[LibreOffice.git] / chart2 / source / tools / RegressionEquation.hxx
blob605dd115ade67cf527987003794838304b5936d2
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 .
19 #ifndef INCLUDED_CHART2_SOURCE_TOOLS_REGRESSIONEQUATION_HXX
20 #define INCLUDED_CHART2_SOURCE_TOOLS_REGRESSIONEQUATION_HXX
22 #include <com/sun/star/lang/XServiceInfo.hpp>
23 #include <com/sun/star/util/XCloneable.hpp>
24 #include <com/sun/star/util/XModifyBroadcaster.hpp>
25 #include <com/sun/star/util/XModifyListener.hpp>
26 #include <com/sun/star/chart2/XTitle.hpp>
28 #include <MutexContainer.hxx>
29 #include <OPropertySet.hxx>
31 #include <cppuhelper/implbase.hxx>
32 #include <comphelper/uno3.hxx>
34 namespace chart
37 namespace impl
39 typedef ::cppu::WeakImplHelper<
40 css::lang::XServiceInfo,
41 css::util::XCloneable,
42 css::util::XModifyBroadcaster,
43 css::util::XModifyListener,
44 css::chart2::XTitle >
45 RegressionEquation_Base;
48 class RegressionEquation final :
49 public MutexContainer,
50 public impl::RegressionEquation_Base,
51 public ::property::OPropertySet
53 public:
54 explicit RegressionEquation();
55 virtual ~RegressionEquation() override;
57 virtual OUString SAL_CALL
58 getImplementationName()
59 override;
60 virtual sal_Bool SAL_CALL
61 supportsService( const OUString& ServiceName )
62 override;
63 virtual css::uno::Sequence< OUString > SAL_CALL
64 getSupportedServiceNames()
65 override;
67 /// merge XInterface implementations
68 DECLARE_XINTERFACE()
70 private:
71 explicit RegressionEquation( const RegressionEquation & rOther );
73 // ____ OPropertySet ____
74 virtual css::uno::Any GetDefaultValue( sal_Int32 nHandle ) const override;
76 virtual ::cppu::IPropertyArrayHelper & SAL_CALL getInfoHelper() override;
78 // ____ XPropertySet ____
79 virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL
80 getPropertySetInfo() override;
82 // ____ XCloneable ____
83 virtual css::uno::Reference< css::util::XCloneable > SAL_CALL createClone() override;
85 // ____ XModifyBroadcaster ____
86 virtual void SAL_CALL addModifyListener(
87 const css::uno::Reference< css::util::XModifyListener >& aListener ) override;
88 virtual void SAL_CALL removeModifyListener(
89 const css::uno::Reference< css::util::XModifyListener >& aListener ) override;
91 // ____ XModifyListener ____
92 virtual void SAL_CALL modified(
93 const css::lang::EventObject& aEvent ) override;
95 // ____ XEventListener (base of XModifyListener) ____
96 virtual void SAL_CALL disposing(
97 const css::lang::EventObject& Source ) override;
99 // ____ XTitle ____
100 virtual css::uno::Sequence<
101 css::uno::Reference< css::chart2::XFormattedString > > SAL_CALL getText() override;
102 virtual void SAL_CALL setText( const css::uno::Sequence<
103 css::uno::Reference<
104 css::chart2::XFormattedString > >& Strings ) override;
106 using ::cppu::OPropertySetHelper::disposing;
108 // ____ OPropertySet ____
109 virtual void firePropertyChangeEvent() override;
111 void fireModifyEvent();
113 css::uno::Sequence< css::uno::Reference< css::chart2::XFormattedString > > m_aStrings;
115 css::uno::Reference< css::util::XModifyListener > m_xModifyEventForwarder;
118 } // namespace chart
120 // INCLUDED_CHART2_SOURCE_TOOLS_REGRESSIONEQUATION_HXX
121 #endif
123 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */