xref: /aoo41x/main/sc/inc/linkuno.hxx (revision cdf0e10c)
1*cdf0e10cSrcweir /*************************************************************************
2*cdf0e10cSrcweir  *
3*cdf0e10cSrcweir  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4*cdf0e10cSrcweir  *
5*cdf0e10cSrcweir  * Copyright 2000, 2010 Oracle and/or its affiliates.
6*cdf0e10cSrcweir  *
7*cdf0e10cSrcweir  * OpenOffice.org - a multi-platform office productivity suite
8*cdf0e10cSrcweir  *
9*cdf0e10cSrcweir  * This file is part of OpenOffice.org.
10*cdf0e10cSrcweir  *
11*cdf0e10cSrcweir  * OpenOffice.org is free software: you can redistribute it and/or modify
12*cdf0e10cSrcweir  * it under the terms of the GNU Lesser General Public License version 3
13*cdf0e10cSrcweir  * only, as published by the Free Software Foundation.
14*cdf0e10cSrcweir  *
15*cdf0e10cSrcweir  * OpenOffice.org is distributed in the hope that it will be useful,
16*cdf0e10cSrcweir  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17*cdf0e10cSrcweir  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18*cdf0e10cSrcweir  * GNU Lesser General Public License version 3 for more details
19*cdf0e10cSrcweir  * (a copy is included in the LICENSE file that accompanied this code).
20*cdf0e10cSrcweir  *
21*cdf0e10cSrcweir  * You should have received a copy of the GNU Lesser General Public License
22*cdf0e10cSrcweir  * version 3 along with OpenOffice.org.  If not, see
23*cdf0e10cSrcweir  * <http://www.openoffice.org/license.html>
24*cdf0e10cSrcweir  * for a copy of the LGPLv3 License.
25*cdf0e10cSrcweir  *
26*cdf0e10cSrcweir  ************************************************************************/
27*cdf0e10cSrcweir 
28*cdf0e10cSrcweir #ifndef SC_LINKUNO_HXX
29*cdf0e10cSrcweir #define SC_LINKUNO_HXX
30*cdf0e10cSrcweir 
31*cdf0e10cSrcweir #include <svl/lstner.hxx>
32*cdf0e10cSrcweir #include <svl/itemprop.hxx>
33*cdf0e10cSrcweir #include <com/sun/star/sheet/XDDELink.hpp>
34*cdf0e10cSrcweir #include <com/sun/star/sheet/XDDELinkResults.hpp>
35*cdf0e10cSrcweir #include <com/sun/star/sheet/XDDELinks.hpp>
36*cdf0e10cSrcweir #include <com/sun/star/sheet/XExternalDocLink.hpp>
37*cdf0e10cSrcweir #include <com/sun/star/sheet/XExternalDocLinks.hpp>
38*cdf0e10cSrcweir #include <com/sun/star/sheet/XExternalSheetCache.hpp>
39*cdf0e10cSrcweir #include <com/sun/star/sheet/XAreaLink.hpp>
40*cdf0e10cSrcweir #include <com/sun/star/sheet/XAreaLinks.hpp>
41*cdf0e10cSrcweir #include <com/sun/star/util/XRefreshable.hpp>
42*cdf0e10cSrcweir #include <com/sun/star/lang/XServiceInfo.hpp>
43*cdf0e10cSrcweir #include <com/sun/star/beans/XPropertySet.hpp>
44*cdf0e10cSrcweir #include <com/sun/star/container/XEnumerationAccess.hpp>
45*cdf0e10cSrcweir #include <com/sun/star/container/XNameAccess.hpp>
46*cdf0e10cSrcweir #include <com/sun/star/container/XIndexAccess.hpp>
47*cdf0e10cSrcweir #include <com/sun/star/container/XNamed.hpp>
48*cdf0e10cSrcweir #include <cppuhelper/implbase1.hxx>
49*cdf0e10cSrcweir #include <cppuhelper/implbase3.hxx>
50*cdf0e10cSrcweir #include <cppuhelper/implbase4.hxx>
51*cdf0e10cSrcweir #include <cppuhelper/implbase5.hxx>
52*cdf0e10cSrcweir 
53*cdf0e10cSrcweir #include "externalrefmgr.hxx"
54*cdf0e10cSrcweir 
55*cdf0e10cSrcweir #include <hash_map>
56*cdf0e10cSrcweir #include <vector>
57*cdf0e10cSrcweir 
58*cdf0e10cSrcweir class ScAreaLink;
59*cdf0e10cSrcweir class ScDocShell;
60*cdf0e10cSrcweir class ScTableLink;
61*cdf0e10cSrcweir 
62*cdf0e10cSrcweir typedef ::com::sun::star::uno::Reference<
63*cdf0e10cSrcweir 			::com::sun::star::util::XRefreshListener >* XRefreshListenerPtr;
64*cdf0e10cSrcweir SV_DECL_PTRARR_DEL( XRefreshListenerArr_Impl, XRefreshListenerPtr, 4, 4 )
65*cdf0e10cSrcweir 
66*cdf0e10cSrcweir 
67*cdf0e10cSrcweir 
68*cdf0e10cSrcweir class ScSheetLinkObj : public cppu::WeakImplHelper4<
69*cdf0e10cSrcweir 							com::sun::star::container::XNamed,
70*cdf0e10cSrcweir 							com::sun::star::util::XRefreshable,
71*cdf0e10cSrcweir 							com::sun::star::beans::XPropertySet,
72*cdf0e10cSrcweir 							com::sun::star::lang::XServiceInfo >,
73*cdf0e10cSrcweir 						public SfxListener
74*cdf0e10cSrcweir {
75*cdf0e10cSrcweir private:
76*cdf0e10cSrcweir 	SfxItemPropertySet		aPropSet;
77*cdf0e10cSrcweir 	ScDocShell*				pDocShell;
78*cdf0e10cSrcweir 	String					aFileName;
79*cdf0e10cSrcweir 	XRefreshListenerArr_Impl aRefreshListeners;
80*cdf0e10cSrcweir 
81*cdf0e10cSrcweir 	ScTableLink*			GetLink_Impl() const;
82*cdf0e10cSrcweir 	void					Refreshed_Impl();
83*cdf0e10cSrcweir 	void					ModifyRefreshDelay_Impl( sal_Int32 nRefresh );
84*cdf0e10cSrcweir 
85*cdf0e10cSrcweir public:
86*cdf0e10cSrcweir 							ScSheetLinkObj(ScDocShell* pDocSh, const String& rName);
87*cdf0e10cSrcweir 	virtual					~ScSheetLinkObj();
88*cdf0e10cSrcweir 
89*cdf0e10cSrcweir 	virtual void			Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
90*cdf0e10cSrcweir 
91*cdf0e10cSrcweir 							// XNamed
92*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getName() throw(::com::sun::star::uno::RuntimeException);
93*cdf0e10cSrcweir 	virtual void SAL_CALL	setName( const ::rtl::OUString& aName )
94*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
95*cdf0e10cSrcweir 
96*cdf0e10cSrcweir 							// XRefreshable
97*cdf0e10cSrcweir 	virtual void SAL_CALL	refresh() throw(::com::sun::star::uno::RuntimeException);
98*cdf0e10cSrcweir 	virtual void SAL_CALL	addRefreshListener( const ::com::sun::star::uno::Reference<
99*cdf0e10cSrcweir 									::com::sun::star::util::XRefreshListener >& l )
100*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
101*cdf0e10cSrcweir 	virtual void SAL_CALL	removeRefreshListener( const ::com::sun::star::uno::Reference<
102*cdf0e10cSrcweir 									::com::sun::star::util::XRefreshListener >& l )
103*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
104*cdf0e10cSrcweir 
105*cdf0e10cSrcweir 							// XPropertySet
106*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo >
107*cdf0e10cSrcweir 							SAL_CALL getPropertySetInfo(  )
108*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
109*cdf0e10cSrcweir 	virtual void SAL_CALL	setPropertyValue( const ::rtl::OUString& aPropertyName,
110*cdf0e10cSrcweir 									const ::com::sun::star::uno::Any& aValue )
111*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
112*cdf0e10cSrcweir 									::com::sun::star::beans::PropertyVetoException,
113*cdf0e10cSrcweir 									::com::sun::star::lang::IllegalArgumentException,
114*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
115*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
116*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue(
117*cdf0e10cSrcweir 									const ::rtl::OUString& PropertyName )
118*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
119*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
120*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
121*cdf0e10cSrcweir 	virtual void SAL_CALL	addPropertyChangeListener( const ::rtl::OUString& aPropertyName,
122*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
123*cdf0e10cSrcweir 										::com::sun::star::beans::XPropertyChangeListener >& xListener )
124*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
125*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
126*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
127*cdf0e10cSrcweir 	virtual void SAL_CALL	removePropertyChangeListener( const ::rtl::OUString& aPropertyName,
128*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
129*cdf0e10cSrcweir 										::com::sun::star::beans::XPropertyChangeListener >& aListener )
130*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
131*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
132*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
133*cdf0e10cSrcweir 	virtual void SAL_CALL	addVetoableChangeListener( const ::rtl::OUString& PropertyName,
134*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
135*cdf0e10cSrcweir 										::com::sun::star::beans::XVetoableChangeListener >& aListener )
136*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
137*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
138*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
139*cdf0e10cSrcweir 	virtual void SAL_CALL	removeVetoableChangeListener( const ::rtl::OUString& PropertyName,
140*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
141*cdf0e10cSrcweir 										::com::sun::star::beans::XVetoableChangeListener >& aListener )
142*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
143*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
144*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
145*cdf0e10cSrcweir 
146*cdf0e10cSrcweir 							// aus get/setPropertyValue gerufen:
147*cdf0e10cSrcweir 	::rtl::OUString			getFileName(void) const;
148*cdf0e10cSrcweir 	void					setFileName(const ::rtl::OUString& FileName);
149*cdf0e10cSrcweir 	::rtl::OUString			getFilter(void) const;
150*cdf0e10cSrcweir 	void					setFilter(const ::rtl::OUString& Filter);
151*cdf0e10cSrcweir 	::rtl::OUString			getFilterOptions(void) const;
152*cdf0e10cSrcweir 	void					setFilterOptions(const ::rtl::OUString& FilterOptions);
153*cdf0e10cSrcweir 	sal_Int32				getRefreshDelay(void) const;
154*cdf0e10cSrcweir 	void					setRefreshDelay(sal_Int32 nRefreshDelay);
155*cdf0e10cSrcweir 
156*cdf0e10cSrcweir 							// XServiceInfo
157*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getImplementationName()
158*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
159*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
160*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
161*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames()
162*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
163*cdf0e10cSrcweir };
164*cdf0e10cSrcweir 
165*cdf0e10cSrcweir 
166*cdf0e10cSrcweir class ScSheetLinksObj : public cppu::WeakImplHelper4<
167*cdf0e10cSrcweir 							com::sun::star::container::XNameAccess,
168*cdf0e10cSrcweir 							com::sun::star::container::XEnumerationAccess,
169*cdf0e10cSrcweir 							com::sun::star::container::XIndexAccess,
170*cdf0e10cSrcweir 							com::sun::star::lang::XServiceInfo >,
171*cdf0e10cSrcweir 						public SfxListener
172*cdf0e10cSrcweir {
173*cdf0e10cSrcweir private:
174*cdf0e10cSrcweir 	ScDocShell*				pDocShell;
175*cdf0e10cSrcweir 
176*cdf0e10cSrcweir 	ScSheetLinkObj*			GetObjectByIndex_Impl(sal_Int32 nIndex);
177*cdf0e10cSrcweir 	ScSheetLinkObj*			GetObjectByName_Impl(const ::rtl::OUString& aName);
178*cdf0e10cSrcweir 
179*cdf0e10cSrcweir public:
180*cdf0e10cSrcweir 							ScSheetLinksObj(ScDocShell* pDocSh);
181*cdf0e10cSrcweir 	virtual					~ScSheetLinksObj();
182*cdf0e10cSrcweir 
183*cdf0e10cSrcweir 	virtual void			Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
184*cdf0e10cSrcweir 
185*cdf0e10cSrcweir 							// XNameAccess
186*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getByName( const ::rtl::OUString& aName )
187*cdf0e10cSrcweir 								throw(::com::sun::star::container::NoSuchElementException,
188*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
189*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
190*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames()
191*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
192*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName )
193*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
194*cdf0e10cSrcweir 
195*cdf0e10cSrcweir 							// XIndexAccess
196*cdf0e10cSrcweir 	virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException);
197*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 Index )
198*cdf0e10cSrcweir 								throw(::com::sun::star::lang::IndexOutOfBoundsException,
199*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
200*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
201*cdf0e10cSrcweir 
202*cdf0e10cSrcweir 							// XEnumerationAccess
203*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL
204*cdf0e10cSrcweir 							createEnumeration() throw(::com::sun::star::uno::RuntimeException);
205*cdf0e10cSrcweir 
206*cdf0e10cSrcweir 							// XElementAccess
207*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
208*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
209*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException);
210*cdf0e10cSrcweir 
211*cdf0e10cSrcweir 							// XServiceInfo
212*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getImplementationName()
213*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
214*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
215*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
216*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames()
217*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
218*cdf0e10cSrcweir };
219*cdf0e10cSrcweir 
220*cdf0e10cSrcweir 
221*cdf0e10cSrcweir class ScAreaLinkObj : public cppu::WeakImplHelper4<
222*cdf0e10cSrcweir 							com::sun::star::sheet::XAreaLink,
223*cdf0e10cSrcweir 							com::sun::star::util::XRefreshable,
224*cdf0e10cSrcweir 							com::sun::star::beans::XPropertySet,
225*cdf0e10cSrcweir 							com::sun::star::lang::XServiceInfo >,
226*cdf0e10cSrcweir 						public SfxListener
227*cdf0e10cSrcweir {
228*cdf0e10cSrcweir private:
229*cdf0e10cSrcweir 	SfxItemPropertySet		aPropSet;
230*cdf0e10cSrcweir 	ScDocShell*				pDocShell;
231*cdf0e10cSrcweir 	sal_uInt16					nPos;
232*cdf0e10cSrcweir 	XRefreshListenerArr_Impl aRefreshListeners;
233*cdf0e10cSrcweir 
234*cdf0e10cSrcweir 	void	Modify_Impl( const ::rtl::OUString* pNewFile, const ::rtl::OUString* pNewFilter,
235*cdf0e10cSrcweir 						 const ::rtl::OUString* pNewOptions, const ::rtl::OUString* pNewSource,
236*cdf0e10cSrcweir 						 const com::sun::star::table::CellRangeAddress* pNewDest );
237*cdf0e10cSrcweir 	void	ModifyRefreshDelay_Impl( sal_Int32 nRefresh );
238*cdf0e10cSrcweir 	void	Refreshed_Impl();
239*cdf0e10cSrcweir 
240*cdf0e10cSrcweir public:
241*cdf0e10cSrcweir 							ScAreaLinkObj(ScDocShell* pDocSh, sal_uInt16 nP);
242*cdf0e10cSrcweir 	virtual					~ScAreaLinkObj();
243*cdf0e10cSrcweir 
244*cdf0e10cSrcweir 	virtual void			Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
245*cdf0e10cSrcweir 
246*cdf0e10cSrcweir 							// XRefreshable
247*cdf0e10cSrcweir 	virtual void SAL_CALL	refresh() throw(::com::sun::star::uno::RuntimeException);
248*cdf0e10cSrcweir 	virtual void SAL_CALL	addRefreshListener( const ::com::sun::star::uno::Reference<
249*cdf0e10cSrcweir 									::com::sun::star::util::XRefreshListener >& l )
250*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
251*cdf0e10cSrcweir 	virtual void SAL_CALL	removeRefreshListener( const ::com::sun::star::uno::Reference<
252*cdf0e10cSrcweir 									::com::sun::star::util::XRefreshListener >& l )
253*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
254*cdf0e10cSrcweir 
255*cdf0e10cSrcweir 							// XPropertySet
256*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo >
257*cdf0e10cSrcweir 							SAL_CALL getPropertySetInfo(  )
258*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
259*cdf0e10cSrcweir 	virtual void SAL_CALL	setPropertyValue( const ::rtl::OUString& aPropertyName,
260*cdf0e10cSrcweir 									const ::com::sun::star::uno::Any& aValue )
261*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
262*cdf0e10cSrcweir 									::com::sun::star::beans::PropertyVetoException,
263*cdf0e10cSrcweir 									::com::sun::star::lang::IllegalArgumentException,
264*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
265*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
266*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue(
267*cdf0e10cSrcweir 									const ::rtl::OUString& PropertyName )
268*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
269*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
270*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
271*cdf0e10cSrcweir 	virtual void SAL_CALL	addPropertyChangeListener( const ::rtl::OUString& aPropertyName,
272*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
273*cdf0e10cSrcweir 										::com::sun::star::beans::XPropertyChangeListener >& xListener )
274*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
275*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
276*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
277*cdf0e10cSrcweir 	virtual void SAL_CALL	removePropertyChangeListener( const ::rtl::OUString& aPropertyName,
278*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
279*cdf0e10cSrcweir 										::com::sun::star::beans::XPropertyChangeListener >& aListener )
280*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
281*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
282*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
283*cdf0e10cSrcweir 	virtual void SAL_CALL	addVetoableChangeListener( const ::rtl::OUString& PropertyName,
284*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
285*cdf0e10cSrcweir 										::com::sun::star::beans::XVetoableChangeListener >& aListener )
286*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
287*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
288*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
289*cdf0e10cSrcweir 	virtual void SAL_CALL	removeVetoableChangeListener( const ::rtl::OUString& PropertyName,
290*cdf0e10cSrcweir 									const ::com::sun::star::uno::Reference<
291*cdf0e10cSrcweir 										::com::sun::star::beans::XVetoableChangeListener >& aListener )
292*cdf0e10cSrcweir 								throw(::com::sun::star::beans::UnknownPropertyException,
293*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
294*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
295*cdf0e10cSrcweir 
296*cdf0e10cSrcweir 							// aus get/setPropertyValue gerufen:
297*cdf0e10cSrcweir 	::rtl::OUString			getFileName(void) const;
298*cdf0e10cSrcweir 	void					setFileName(const ::rtl::OUString& FileName);
299*cdf0e10cSrcweir 	::rtl::OUString			getFilter(void) const;
300*cdf0e10cSrcweir 	void					setFilter(const ::rtl::OUString& Filter);
301*cdf0e10cSrcweir 	::rtl::OUString			getFilterOptions(void) const;
302*cdf0e10cSrcweir 	void					setFilterOptions(const ::rtl::OUString& FilterOptions);
303*cdf0e10cSrcweir 	sal_Int32				getRefreshDelay(void) const;
304*cdf0e10cSrcweir 	void					setRefreshDelay(sal_Int32 nRefreshDelay);
305*cdf0e10cSrcweir 
306*cdf0e10cSrcweir 							// XAreaLink
307*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getSourceArea() throw(::com::sun::star::uno::RuntimeException);
308*cdf0e10cSrcweir 	virtual void SAL_CALL 	setSourceArea( const ::rtl::OUString& aSourceArea )
309*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
310*cdf0e10cSrcweir 	virtual ::com::sun::star::table::CellRangeAddress SAL_CALL getDestArea()
311*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
312*cdf0e10cSrcweir 	virtual void SAL_CALL setDestArea( const ::com::sun::star::table::CellRangeAddress& aDestArea )
313*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
314*cdf0e10cSrcweir 
315*cdf0e10cSrcweir 							// XServiceInfo
316*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getImplementationName()
317*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
318*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
319*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
320*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames()
321*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
322*cdf0e10cSrcweir };
323*cdf0e10cSrcweir 
324*cdf0e10cSrcweir 
325*cdf0e10cSrcweir class ScAreaLinksObj : public cppu::WeakImplHelper3<
326*cdf0e10cSrcweir 							com::sun::star::sheet::XAreaLinks,
327*cdf0e10cSrcweir 							com::sun::star::container::XEnumerationAccess,
328*cdf0e10cSrcweir 							com::sun::star::lang::XServiceInfo >,
329*cdf0e10cSrcweir 						public SfxListener
330*cdf0e10cSrcweir {
331*cdf0e10cSrcweir private:
332*cdf0e10cSrcweir 	ScDocShell*				pDocShell;
333*cdf0e10cSrcweir 
334*cdf0e10cSrcweir 	ScAreaLinkObj*			GetObjectByIndex_Impl(sal_Int32 nIndex);
335*cdf0e10cSrcweir 
336*cdf0e10cSrcweir public:
337*cdf0e10cSrcweir 							ScAreaLinksObj(ScDocShell* pDocSh);
338*cdf0e10cSrcweir 	virtual					~ScAreaLinksObj();
339*cdf0e10cSrcweir 
340*cdf0e10cSrcweir 	virtual void			Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
341*cdf0e10cSrcweir 
342*cdf0e10cSrcweir 							// XAreaLinks
343*cdf0e10cSrcweir 	virtual void SAL_CALL	insertAtPosition( const ::com::sun::star::table::CellAddress& aDestPos,
344*cdf0e10cSrcweir 												const ::rtl::OUString& aFileName,
345*cdf0e10cSrcweir 												const ::rtl::OUString& aSourceArea,
346*cdf0e10cSrcweir 												const ::rtl::OUString& aFilter,
347*cdf0e10cSrcweir 												const ::rtl::OUString& aFilterOptions )
348*cdf0e10cSrcweir 											throw(::com::sun::star::uno::RuntimeException);
349*cdf0e10cSrcweir 	virtual void SAL_CALL	removeByIndex( sal_Int32 nIndex )
350*cdf0e10cSrcweir 											throw(::com::sun::star::uno::RuntimeException);
351*cdf0e10cSrcweir 
352*cdf0e10cSrcweir 							// XIndexAccess
353*cdf0e10cSrcweir 	virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException);
354*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 Index )
355*cdf0e10cSrcweir 								throw(::com::sun::star::lang::IndexOutOfBoundsException,
356*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
357*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
358*cdf0e10cSrcweir 
359*cdf0e10cSrcweir 							// XEnumerationAccess
360*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL
361*cdf0e10cSrcweir 							createEnumeration() throw(::com::sun::star::uno::RuntimeException);
362*cdf0e10cSrcweir 
363*cdf0e10cSrcweir 							// XElementAccess
364*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
365*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
366*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException);
367*cdf0e10cSrcweir 
368*cdf0e10cSrcweir 							// XServiceInfo
369*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getImplementationName()
370*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
371*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
372*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
373*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames()
374*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
375*cdf0e10cSrcweir };
376*cdf0e10cSrcweir 
377*cdf0e10cSrcweir 
378*cdf0e10cSrcweir //!	order of XNamed and DDELink changed to avoid "duplicate comdat" symbols
379*cdf0e10cSrcweir 
380*cdf0e10cSrcweir class ScDDELinkObj : public cppu::WeakImplHelper5<
381*cdf0e10cSrcweir 							com::sun::star::sheet::XDDELink,
382*cdf0e10cSrcweir 							com::sun::star::container::XNamed,
383*cdf0e10cSrcweir 							com::sun::star::util::XRefreshable,
384*cdf0e10cSrcweir                             com::sun::star::sheet::XDDELinkResults,
385*cdf0e10cSrcweir 							com::sun::star::lang::XServiceInfo >,
386*cdf0e10cSrcweir 						public SfxListener
387*cdf0e10cSrcweir {
388*cdf0e10cSrcweir private:
389*cdf0e10cSrcweir 	ScDocShell*				pDocShell;
390*cdf0e10cSrcweir 	String					aAppl;
391*cdf0e10cSrcweir 	String					aTopic;
392*cdf0e10cSrcweir 	String					aItem;
393*cdf0e10cSrcweir 	XRefreshListenerArr_Impl aRefreshListeners;
394*cdf0e10cSrcweir 
395*cdf0e10cSrcweir 	void					Refreshed_Impl();
396*cdf0e10cSrcweir 
397*cdf0e10cSrcweir public:
398*cdf0e10cSrcweir 							ScDDELinkObj(ScDocShell* pDocSh, const String& rA,
399*cdf0e10cSrcweir 											const String& rT, const String& rI);
400*cdf0e10cSrcweir 	virtual					~ScDDELinkObj();
401*cdf0e10cSrcweir 
402*cdf0e10cSrcweir 	virtual void			Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
403*cdf0e10cSrcweir 
404*cdf0e10cSrcweir 							// XNamed
405*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getName() throw(::com::sun::star::uno::RuntimeException);
406*cdf0e10cSrcweir 	virtual void SAL_CALL	setName( const ::rtl::OUString& aName )
407*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
408*cdf0e10cSrcweir 
409*cdf0e10cSrcweir 							// XDDELink
410*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getApplication() throw(::com::sun::star::uno::RuntimeException);
411*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getTopic() throw(::com::sun::star::uno::RuntimeException);
412*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getItem() throw(::com::sun::star::uno::RuntimeException);
413*cdf0e10cSrcweir 
414*cdf0e10cSrcweir 							// XRefreshable
415*cdf0e10cSrcweir 	virtual void SAL_CALL	refresh() throw(::com::sun::star::uno::RuntimeException);
416*cdf0e10cSrcweir 	virtual void SAL_CALL	addRefreshListener( const ::com::sun::star::uno::Reference<
417*cdf0e10cSrcweir 									::com::sun::star::util::XRefreshListener >& l )
418*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
419*cdf0e10cSrcweir 	virtual void SAL_CALL	removeRefreshListener( const ::com::sun::star::uno::Reference<
420*cdf0e10cSrcweir 									::com::sun::star::util::XRefreshListener >& l )
421*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
422*cdf0e10cSrcweir 
423*cdf0e10cSrcweir                             // XDDELinkResults
424*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > >
425*cdf0e10cSrcweir         SAL_CALL getResults(  )
426*cdf0e10cSrcweir         throw (::com::sun::star::uno::RuntimeException);
427*cdf0e10cSrcweir     virtual void SAL_CALL setResults(
428*cdf0e10cSrcweir         const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > >& aResults )
429*cdf0e10cSrcweir         throw (::com::sun::star::uno::RuntimeException);
430*cdf0e10cSrcweir 
431*cdf0e10cSrcweir 							// XServiceInfo
432*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getImplementationName()
433*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
434*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
435*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
436*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames()
437*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
438*cdf0e10cSrcweir };
439*cdf0e10cSrcweir 
440*cdf0e10cSrcweir 
441*cdf0e10cSrcweir class ScDDELinksObj : public cppu::WeakImplHelper4<
442*cdf0e10cSrcweir 							com::sun::star::container::XEnumerationAccess,
443*cdf0e10cSrcweir 							com::sun::star::container::XIndexAccess,
444*cdf0e10cSrcweir                             com::sun::star::sheet::XDDELinks,
445*cdf0e10cSrcweir 							com::sun::star::lang::XServiceInfo >,
446*cdf0e10cSrcweir 						public SfxListener
447*cdf0e10cSrcweir {
448*cdf0e10cSrcweir private:
449*cdf0e10cSrcweir 	ScDocShell*				pDocShell;
450*cdf0e10cSrcweir 
451*cdf0e10cSrcweir 	ScDDELinkObj*			GetObjectByIndex_Impl(sal_Int32 nIndex);
452*cdf0e10cSrcweir 	ScDDELinkObj*			GetObjectByName_Impl(const ::rtl::OUString& aName);
453*cdf0e10cSrcweir 
454*cdf0e10cSrcweir public:
455*cdf0e10cSrcweir 							ScDDELinksObj(ScDocShell* pDocSh);
456*cdf0e10cSrcweir 	virtual					~ScDDELinksObj();
457*cdf0e10cSrcweir 
458*cdf0e10cSrcweir 	virtual void			Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
459*cdf0e10cSrcweir 
460*cdf0e10cSrcweir 							// XNameAccess
461*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getByName( const ::rtl::OUString& aName )
462*cdf0e10cSrcweir 								throw(::com::sun::star::container::NoSuchElementException,
463*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
464*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
465*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames()
466*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
467*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName )
468*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
469*cdf0e10cSrcweir 
470*cdf0e10cSrcweir 							// XIndexAccess
471*cdf0e10cSrcweir 	virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException);
472*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 Index )
473*cdf0e10cSrcweir 								throw(::com::sun::star::lang::IndexOutOfBoundsException,
474*cdf0e10cSrcweir 									::com::sun::star::lang::WrappedTargetException,
475*cdf0e10cSrcweir 									::com::sun::star::uno::RuntimeException);
476*cdf0e10cSrcweir 
477*cdf0e10cSrcweir 							// XEnumerationAccess
478*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL
479*cdf0e10cSrcweir 							createEnumeration() throw(::com::sun::star::uno::RuntimeException);
480*cdf0e10cSrcweir 
481*cdf0e10cSrcweir 							// XElementAccess
482*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
483*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
484*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException);
485*cdf0e10cSrcweir 
486*cdf0e10cSrcweir                             // XDDELinks
487*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XDDELink > SAL_CALL addDDELink(
488*cdf0e10cSrcweir         const ::rtl::OUString& aApplication, const ::rtl::OUString& aTopic,
489*cdf0e10cSrcweir         const ::rtl::OUString& aItem, ::com::sun::star::sheet::DDELinkMode nMode )
490*cdf0e10cSrcweir         throw (::com::sun::star::uno::RuntimeException);
491*cdf0e10cSrcweir 
492*cdf0e10cSrcweir 							// XServiceInfo
493*cdf0e10cSrcweir 	virtual ::rtl::OUString SAL_CALL getImplementationName()
494*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
495*cdf0e10cSrcweir 	virtual sal_Bool SAL_CALL supportsService( const ::rtl::OUString& ServiceName )
496*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
497*cdf0e10cSrcweir 	virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getSupportedServiceNames()
498*cdf0e10cSrcweir 								throw(::com::sun::star::uno::RuntimeException);
499*cdf0e10cSrcweir };
500*cdf0e10cSrcweir 
501*cdf0e10cSrcweir // ============================================================================
502*cdf0e10cSrcweir 
503*cdf0e10cSrcweir class ScExternalSheetCacheObj : public cppu::WeakImplHelper1< ::com::sun::star::sheet::XExternalSheetCache >
504*cdf0e10cSrcweir {
505*cdf0e10cSrcweir public:
506*cdf0e10cSrcweir     explicit ScExternalSheetCacheObj(ScExternalRefCache::TableTypeRef pTable, size_t nIndex);
507*cdf0e10cSrcweir     ~ScExternalSheetCacheObj();
508*cdf0e10cSrcweir 
509*cdf0e10cSrcweir                             // XExternalSheetCache
510*cdf0e10cSrcweir     virtual void SAL_CALL setCellValue(
511*cdf0e10cSrcweir         sal_Int32 nCol, sal_Int32 nRow, const ::com::sun::star::uno::Any& rAny)
512*cdf0e10cSrcweir         throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
513*cdf0e10cSrcweir 
514*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Any SAL_CALL getCellValue(sal_Int32 nCol, sal_Int32 nRow)
515*cdf0e10cSrcweir         throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
516*cdf0e10cSrcweir 
517*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Sequence< sal_Int32 > SAL_CALL getAllRows()
518*cdf0e10cSrcweir         throw (::com::sun::star::uno::RuntimeException);
519*cdf0e10cSrcweir 
520*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Sequence< sal_Int32 > SAL_CALL getAllColumns(sal_Int32 nRow)
521*cdf0e10cSrcweir         throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
522*cdf0e10cSrcweir 
523*cdf0e10cSrcweir     // Attributes
524*cdf0e10cSrcweir     virtual sal_Int32 SAL_CALL getTokenIndex()
525*cdf0e10cSrcweir             throw (::com::sun::star::uno::RuntimeException);
526*cdf0e10cSrcweir 
527*cdf0e10cSrcweir private:
528*cdf0e10cSrcweir     ScExternalSheetCacheObj();
529*cdf0e10cSrcweir     ScExternalSheetCacheObj(const ScExternalSheetCacheObj&);
530*cdf0e10cSrcweir 
531*cdf0e10cSrcweir private:
532*cdf0e10cSrcweir     ScExternalRefCache::TableTypeRef mpTable;
533*cdf0e10cSrcweir     size_t mnIndex;
534*cdf0e10cSrcweir };
535*cdf0e10cSrcweir 
536*cdf0e10cSrcweir // ============================================================================
537*cdf0e10cSrcweir 
538*cdf0e10cSrcweir class ScExternalDocLinkObj : public cppu::WeakImplHelper1< ::com::sun::star::sheet::XExternalDocLink >
539*cdf0e10cSrcweir {
540*cdf0e10cSrcweir public:
541*cdf0e10cSrcweir     ScExternalDocLinkObj(ScExternalRefManager* pRefMgr, sal_uInt16 nFileId);
542*cdf0e10cSrcweir     ~ScExternalDocLinkObj();
543*cdf0e10cSrcweir 
544*cdf0e10cSrcweir                             // XExternalDocLink
545*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XExternalSheetCache >
546*cdf0e10cSrcweir         SAL_CALL addSheetCache( const ::rtl::OUString& aSheetName, sal_Bool bDynamicCache )
547*cdf0e10cSrcweir             throw (::com::sun::star::uno::RuntimeException);
548*cdf0e10cSrcweir 
549*cdf0e10cSrcweir                             // XNameAccess
550*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Any SAL_CALL getByName( const ::rtl::OUString& aName )
551*cdf0e10cSrcweir                                 throw(::com::sun::star::container::NoSuchElementException,
552*cdf0e10cSrcweir                                     ::com::sun::star::lang::WrappedTargetException,
553*cdf0e10cSrcweir                                     ::com::sun::star::uno::RuntimeException);
554*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames()
555*cdf0e10cSrcweir                                 throw(::com::sun::star::uno::RuntimeException);
556*cdf0e10cSrcweir     virtual sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName )
557*cdf0e10cSrcweir                                 throw(::com::sun::star::uno::RuntimeException);
558*cdf0e10cSrcweir 
559*cdf0e10cSrcweir                             // XIndexAccess
560*cdf0e10cSrcweir     virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException);
561*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 nIndex )
562*cdf0e10cSrcweir                                 throw(::com::sun::star::lang::IndexOutOfBoundsException,
563*cdf0e10cSrcweir                                     ::com::sun::star::lang::WrappedTargetException,
564*cdf0e10cSrcweir                                     ::com::sun::star::uno::RuntimeException);
565*cdf0e10cSrcweir 
566*cdf0e10cSrcweir                             // XEnumerationAccess
567*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL
568*cdf0e10cSrcweir                             createEnumeration() throw(::com::sun::star::uno::RuntimeException);
569*cdf0e10cSrcweir 
570*cdf0e10cSrcweir                             // XElementAccess
571*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
572*cdf0e10cSrcweir                                 throw(::com::sun::star::uno::RuntimeException);
573*cdf0e10cSrcweir     virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException);
574*cdf0e10cSrcweir 
575*cdf0e10cSrcweir     // Attributes
576*cdf0e10cSrcweir     virtual sal_Int32 SAL_CALL getTokenIndex()
577*cdf0e10cSrcweir             throw (::com::sun::star::uno::RuntimeException);
578*cdf0e10cSrcweir 
579*cdf0e10cSrcweir private:
580*cdf0e10cSrcweir     ScExternalRefManager*   mpRefMgr;
581*cdf0e10cSrcweir     sal_uInt16              mnFileId;
582*cdf0e10cSrcweir };
583*cdf0e10cSrcweir 
584*cdf0e10cSrcweir // ============================================================================
585*cdf0e10cSrcweir 
586*cdf0e10cSrcweir /** This is the UNO API equivalent of ScExternalRefManager. */
587*cdf0e10cSrcweir class ScExternalDocLinksObj : public cppu::WeakImplHelper1< ::com::sun::star::sheet::XExternalDocLinks >
588*cdf0e10cSrcweir {
589*cdf0e10cSrcweir public:
590*cdf0e10cSrcweir     ScExternalDocLinksObj(ScDocShell* pDocShell);
591*cdf0e10cSrcweir     ~ScExternalDocLinksObj();
592*cdf0e10cSrcweir 
593*cdf0e10cSrcweir                             // XExternalDocLinks
594*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Reference< ::com::sun::star::sheet::XExternalDocLink >
595*cdf0e10cSrcweir         SAL_CALL addDocLink( const ::rtl::OUString& aDocName )
596*cdf0e10cSrcweir             throw (::com::sun::star::uno::RuntimeException);
597*cdf0e10cSrcweir 
598*cdf0e10cSrcweir                             // XNameAccess
599*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Any SAL_CALL getByName( const ::rtl::OUString& aName )
600*cdf0e10cSrcweir                                 throw(::com::sun::star::container::NoSuchElementException,
601*cdf0e10cSrcweir                                     ::com::sun::star::lang::WrappedTargetException,
602*cdf0e10cSrcweir                                     ::com::sun::star::uno::RuntimeException);
603*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Sequence< ::rtl::OUString > SAL_CALL getElementNames()
604*cdf0e10cSrcweir                                 throw(::com::sun::star::uno::RuntimeException);
605*cdf0e10cSrcweir     virtual sal_Bool SAL_CALL hasByName( const ::rtl::OUString& aName )
606*cdf0e10cSrcweir                                 throw(::com::sun::star::uno::RuntimeException);
607*cdf0e10cSrcweir 
608*cdf0e10cSrcweir                             // XIndexAccess
609*cdf0e10cSrcweir     virtual sal_Int32 SAL_CALL getCount() throw(::com::sun::star::uno::RuntimeException);
610*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( sal_Int32 nIndex )
611*cdf0e10cSrcweir                                 throw(::com::sun::star::lang::IndexOutOfBoundsException,
612*cdf0e10cSrcweir                                     ::com::sun::star::lang::WrappedTargetException,
613*cdf0e10cSrcweir                                     ::com::sun::star::uno::RuntimeException);
614*cdf0e10cSrcweir 
615*cdf0e10cSrcweir                             // XEnumerationAccess
616*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XEnumeration > SAL_CALL
617*cdf0e10cSrcweir                             createEnumeration() throw(::com::sun::star::uno::RuntimeException);
618*cdf0e10cSrcweir 
619*cdf0e10cSrcweir                             // XElementAccess
620*cdf0e10cSrcweir     virtual ::com::sun::star::uno::Type SAL_CALL getElementType()
621*cdf0e10cSrcweir                                 throw(::com::sun::star::uno::RuntimeException);
622*cdf0e10cSrcweir     virtual sal_Bool SAL_CALL hasElements() throw(::com::sun::star::uno::RuntimeException);
623*cdf0e10cSrcweir 
624*cdf0e10cSrcweir private:
625*cdf0e10cSrcweir     ScExternalDocLinksObj();
626*cdf0e10cSrcweir     ScExternalDocLinksObj(const ScExternalDocLinksObj&);
627*cdf0e10cSrcweir 
628*cdf0e10cSrcweir private:
629*cdf0e10cSrcweir     ScDocShell*                         mpDocShell;
630*cdf0e10cSrcweir     ScExternalRefManager*               mpRefMgr;
631*cdf0e10cSrcweir };
632*cdf0e10cSrcweir 
633*cdf0e10cSrcweir #endif
634*cdf0e10cSrcweir 
635