update dev300-m58
[ooovba.git] / chart2 / source / model / template / LineChartTypeTemplate.hxx
blob1775a1ca2ee449ac5ccd54aa6bb8e232ed1a4040
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: LineChartTypeTemplate.hxx,v $
10 * $Revision: 1.13 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef CHART_LINECHARTTYPETEMPLATE_HXX
31 #define CHART_LINECHARTTYPETEMPLATE_HXX
33 #include "ChartTypeTemplate.hxx"
34 #include "OPropertySet.hxx"
35 #include "MutexContainer.hxx"
36 #include "StackMode.hxx"
37 #include <comphelper/uno3.hxx>
38 #include <com/sun/star/chart2/CurveStyle.hpp>
40 namespace chart
43 class LineChartTypeTemplate :
44 public MutexContainer,
45 public ChartTypeTemplate,
46 public ::property::OPropertySet
48 public:
49 explicit LineChartTypeTemplate(
50 ::com::sun::star::uno::Reference<
51 ::com::sun::star::uno::XComponentContext > const & xContext,
52 const ::rtl::OUString & rServiceName,
53 StackMode eStackMode,
54 bool bSymbols,
55 bool bHasLines = true,
56 sal_Int32 nDim = 2 );
57 virtual ~LineChartTypeTemplate();
59 /// XServiceInfo declarations
60 APPHELPER_XSERVICEINFO_DECL()
62 /// merge XInterface implementations
63 DECLARE_XINTERFACE()
64 /// merge XTypeProvider implementations
65 DECLARE_XTYPEPROVIDER()
67 protected:
68 // ____ OPropertySet ____
69 virtual ::com::sun::star::uno::Any GetDefaultValue( sal_Int32 nHandle ) const
70 throw(::com::sun::star::beans::UnknownPropertyException);
71 virtual ::cppu::IPropertyArrayHelper & SAL_CALL getInfoHelper();
73 // ____ XPropertySet ____
74 virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL
75 getPropertySetInfo()
76 throw (::com::sun::star::uno::RuntimeException);
78 // ____ XChartTypeTemplate ____
79 virtual sal_Bool SAL_CALL matchesTemplate(
80 const ::com::sun::star::uno::Reference<
81 ::com::sun::star::chart2::XDiagram >& xDiagram,
82 sal_Bool bAdaptProperties )
83 throw (::com::sun::star::uno::RuntimeException);
84 virtual ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartType > SAL_CALL
85 getChartTypeForNewSeries( const ::com::sun::star::uno::Sequence<
86 ::com::sun::star::uno::Reference<
87 ::com::sun::star::chart2::XChartType > >& aFormerlyUsedChartTypes )
88 throw (::com::sun::star::uno::RuntimeException);
89 virtual void SAL_CALL applyStyle(
90 const ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XDataSeries >& xSeries,
91 ::sal_Int32 nChartTypeGroupIndex,
92 ::sal_Int32 nSeriesIndex,
93 ::sal_Int32 nSeriesCount )
94 throw (::com::sun::star::uno::RuntimeException);
96 // ____ ChartTypeTemplate ____
97 virtual ::com::sun::star::uno::Reference< ::com::sun::star::chart2::XChartType >
98 getChartTypeForIndex( sal_Int32 nChartTypeIndex );
99 virtual sal_Int32 getDimension() const;
100 virtual StackMode getStackMode( sal_Int32 nChartTypeIndex ) const;
102 private:
103 StackMode m_eStackMode;
104 bool m_bHasSymbols;
105 bool m_bHasLines;
106 sal_Int32 m_nDim;
109 } // namespace chart
111 // CHART_LINECHARTTYPETEMPLATE_HXX
112 #endif