1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements.  See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership.  The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance
9 * with the License.  You may obtain a copy of the License at
10 *
11 *   http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing,
14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied.  See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23#ifndef com_sun_star_chart2_data_XDataReceiver_idl
24#define com_sun_star_chart2_data_XDataReceiver_idl
25
26#ifndef __com_sun_star_uno_XInterface_idl__
27#include <com/sun/star/uno/XInterface.idl>
28#endif
29#ifndef __com_sun_star_lang_IllegalArgumentException_idl__
30#include <com/sun/star/lang/IllegalArgumentException.idl>
31#endif
32
33#ifndef com_sun_star_chart2_data_XDataProvider_idl
34#include <com/sun/star/chart2/data/XDataProvider.idl>
35#endif
36
37#ifndef com_sun_star_chart2_data_XRangeHighlighter_idl
38#include <com/sun/star/chart2/data/XRangeHighlighter.idl>
39#endif
40
41#ifndef com_sun_star_beans_PropertyValue_idl
42#include <com/sun/star/beans/PropertyValue.idl>
43#endif
44
45#ifndef __com_sun_star_util_XNumberFormatsSupplier_idl__
46#include <com/sun/star/util/XNumberFormatsSupplier.idl>
47#endif
48
49module com
50{
51module sun
52{
53module star
54{
55module chart2
56{
57module data
58{
59
60interface XDataReceiver : ::com::sun::star::uno::XInterface
61{
62    /** attaches a component that provides data for the document.
63
64        <p>The previously set data provider will be released.</p>
65
66        @param xProvider
67              The new DataProvider.  If it is an empty reference, the
68              ChartDocument will have no data.
69     */
70    void attachDataProvider( [in] XDataProvider xProvider );
71
72    void setArguments( [in] sequence< com::sun::star::beans::PropertyValue > aArguments )
73        raises( com::sun::star::lang::IllegalArgumentException );
74
75    /** returns a list of all range strings for which data has been
76        requested by the most recently attached data provider, and
77        which is still used.
78
79        <p>This list may be used by the data provider to swap charts
80        out of memory, but still get informed by changes of ranges
81        while the chart is not loaded.</p>
82        @return a list of used range strings.
83     */
84    sequence< string > getUsedRangeRepresentations();
85
86    /** Returns the data requested by the most recently attached data
87        provider, that is still used.
88     */
89    XDataSource getUsedData();
90
91    /** attaches an <type>XNumberFormatsSupplier</type> to this
92		<type>XDataReceiver</type>.
93
94		<p>The given number formats will be used for display purposes.</p>
95	 */
96    void attachNumberFormatsSupplier( [in] com::sun::star::util::XNumberFormatsSupplier xSupplier );
97
98    /** Returns a component at which a view representing the data of
99        the attached data provider may listen for highlighting the
100        data ranges used by the currently selected objects in the data
101        receiver component.
102
103        <p>This is typically used by a spreadsheet to hightlight the
104        ranges used by the currently selected object in a chart.</p>
105
106        <p>The range hightlighter is optional, i.e., this method may
107        return an empty object.</p>
108     */
109    XRangeHighlighter getRangeHighlighter();
110};
111
112} ; // data
113} ; // chart2
114} ; // com
115} ; // sun
116} ; // star
117
118#endif
119