Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
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/.
8 : *
9 : * This file incorporates work covered by the following license notice:
10 : *
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 .
18 : */
19 :
20 : #ifndef _WRITESTREAM_HXX_
21 : #define _WRITESTREAM_HXX_
22 :
23 : #include <com/sun/star/io/XInputStream.hpp>
24 : #include <com/sun/star/io/XOutputStream.hpp>
25 : #include <com/sun/star/io/XStream.hpp>
26 : #include <com/sun/star/io/XSeekable.hpp>
27 : #include <com/sun/star/io/XTruncate.hpp>
28 : #include <com/sun/star/packages/XDataSinkEncrSupport.hpp>
29 : #include <com/sun/star/packages/NoEncryptionException.hpp>
30 : #include <com/sun/star/lang/XEventListener.hpp>
31 : #include <com/sun/star/lang/XSingleServiceFactory.hpp>
32 : #include <com/sun/star/lang/XComponent.hpp>
33 : #include <com/sun/star/embed/XEncryptionProtectedSource2.hpp>
34 : #include <com/sun/star/embed/XStorage.hpp>
35 : #include <com/sun/star/embed/XRelationshipAccess.hpp>
36 : #include <com/sun/star/embed/XExtendedStorageStream.hpp>
37 : #include <com/sun/star/embed/XTransactedObject.hpp>
38 : #include <com/sun/star/embed/XTransactionBroadcaster.hpp>
39 : #include <com/sun/star/container/XNameContainer.hpp>
40 : #include <com/sun/star/beans/StringPair.hpp>
41 : #include <com/sun/star/logging/XSimpleLogRing.hpp>
42 :
43 : #include <cppuhelper/implbase1.hxx>
44 : #include <cppuhelper/weak.hxx>
45 : #include <cppuhelper/interfacecontainer.h>
46 :
47 : #include <comphelper/sequenceashashmap.hxx>
48 :
49 : #include <list>
50 :
51 : #include "ocompinstream.hxx"
52 : #include "mutexholder.hxx"
53 :
54 : namespace com { namespace sun { namespace star { namespace uno {
55 : class XComponentContext;
56 : } } } }
57 :
58 0 : struct PreCreationStruct
59 : {
60 : SotMutexHolderRef m_rMutexRef;
61 :
62 0 : PreCreationStruct()
63 0 : : m_rMutexRef( new SotMutexHolder )
64 0 : {}
65 :
66 : };
67 :
68 : namespace cppu {
69 : class OTypeCollection;
70 : }
71 :
72 : namespace package {
73 : void StaticAddLog( const OUString& aMessage );
74 : bool PackageEncryptionDatasEqual( const ::comphelper::SequenceAsHashMap& aHash1, const ::comphelper::SequenceAsHashMap& aHash2 );
75 : }
76 :
77 0 : struct WSInternalData_Impl
78 : {
79 : SotMutexHolderRef m_rSharedMutexRef;
80 : ::cppu::OTypeCollection* m_pTypeCollection;
81 : ::cppu::OMultiTypeInterfaceContainerHelper m_aListenersContainer; // list of listeners
82 : sal_Int32 m_nStorageType;
83 :
84 : // the mutex reference MUST NOT be empty
85 0 : WSInternalData_Impl( const SotMutexHolderRef rMutexRef, sal_Int32 nStorageType )
86 : : m_rSharedMutexRef( rMutexRef )
87 : , m_pTypeCollection( NULL )
88 0 : , m_aListenersContainer( rMutexRef->GetMutex() )
89 0 : , m_nStorageType( nStorageType )
90 0 : {}
91 : };
92 :
93 : typedef ::std::list< OInputCompStream* > InputStreamsList_Impl;
94 :
95 : struct OStorage_Impl;
96 : class OWriteStream;
97 :
98 : struct OWriteStream_Impl : public PreCreationStruct
99 : {
100 : friend struct OStorage_Impl;
101 : friend class OWriteStream;
102 : friend class OInputCompStream;
103 :
104 : OWriteStream* m_pAntiImpl;
105 : OUString m_aTempURL;
106 :
107 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > m_xCacheStream;
108 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XSeekable > m_xCacheSeek;
109 :
110 : InputStreamsList_Impl m_aInputStreamsList;
111 :
112 : sal_Bool m_bHasDataToFlush; // only modified elements will be sent to the original content
113 : sal_Bool m_bFlushed; // sending the streams is coordinated by the root storage of the package
114 :
115 : ::com::sun::star::uno::Reference< ::com::sun::star::packages::XDataSinkEncrSupport > m_xPackageStream;
116 : ::com::sun::star::uno::Reference< ::com::sun::star::logging::XSimpleLogRing > m_xLogRing;
117 :
118 : ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext;
119 :
120 : OStorage_Impl* m_pParent;
121 :
122 : ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > m_aProps;
123 :
124 : sal_Bool m_bForceEncrypted;
125 :
126 : sal_Bool m_bUseCommonEncryption;
127 : sal_Bool m_bHasCachedEncryptionData;
128 : ::comphelper::SequenceAsHashMap m_aEncryptionData;
129 :
130 : sal_Bool m_bCompressedSetExplicit;
131 :
132 : ::com::sun::star::uno::Reference< ::com::sun::star::lang::XSingleServiceFactory > m_xPackage;
133 :
134 : sal_Bool m_bHasInsertedStreamOptimization;
135 :
136 : sal_Int32 m_nStorageType;
137 :
138 : // Relations info related data, stored in *.rels file in OFOPXML format
139 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > m_xOrigRelInfoStream;
140 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > m_aOrigRelInfo;
141 : sal_Bool m_bOrigRelInfoBroken;
142 :
143 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > m_aNewRelInfo;
144 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > m_xNewRelInfoStream;
145 : sal_Int16 m_nRelInfoStatus;
146 : sal_Int32 m_nRelId;
147 :
148 : private:
149 : OUString GetFilledTempFileIfNo( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xStream );
150 : OUString FillTempGetFileName();
151 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > GetTempFileAsStream();
152 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > GetTempFileAsInputStream();
153 :
154 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > GetStream_Impl( sal_Int32 nStreamMode,
155 : sal_Bool bHierarchyAccess );
156 :
157 : ::comphelper::SequenceAsHashMap GetCommonRootEncryptionData() throw ( ::com::sun::star::packages::NoEncryptionException );
158 :
159 : ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > ReadPackageStreamProperties();
160 : ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > InsertOwnProps(
161 : const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aProps,
162 : sal_Bool bUseCommonEncryption );
163 :
164 : public:
165 : OWriteStream_Impl(
166 : OStorage_Impl* pParent,
167 : const ::com::sun::star::uno::Reference< ::com::sun::star::packages::XDataSinkEncrSupport >& xPackageStream,
168 : const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XSingleServiceFactory >& xPackage,
169 : const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& xContext,
170 : sal_Bool bForceEncrypted,
171 : sal_Int32 nStorageType,
172 : sal_Bool bDefaultCompress,
173 : const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xRelInfoStream =
174 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >() );
175 :
176 : ~OWriteStream_Impl();
177 :
178 : void CleanCacheStream();
179 :
180 : void AddLog( const OUString& aMessage );
181 :
182 0 : sal_Bool UsesCommonEncryption_Impl() { return m_bUseCommonEncryption; }
183 0 : sal_Bool HasTempFile_Impl() const { return ( m_aTempURL.getLength() != 0 ); }
184 : sal_Bool IsTransacted();
185 :
186 0 : sal_Bool HasWriteOwner_Impl() const { return ( m_pAntiImpl != NULL ); }
187 :
188 : void InsertIntoPackageFolder(
189 : const OUString& aName,
190 : const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameContainer >& xParentPackageFolder );
191 :
192 0 : void SetToBeCommited() { m_bFlushed = sal_True; }
193 :
194 0 : sal_Bool HasCachedEncryptionData() { return m_bHasCachedEncryptionData; }
195 0 : ::comphelper::SequenceAsHashMap& GetCachedEncryptionData() { return m_aEncryptionData; }
196 :
197 0 : sal_Bool IsModified() { return m_bHasDataToFlush || m_bFlushed; }
198 :
199 : sal_Bool IsEncrypted();
200 : void SetDecrypted();
201 : void SetEncrypted( const ::comphelper::SequenceAsHashMap& aEncryptionData );
202 :
203 : void DisposeWrappers();
204 :
205 : void InsertStreamDirectly(
206 : const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xInStream,
207 : const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aProps );
208 :
209 : void Commit();
210 : void Revert();
211 :
212 : void Free( sal_Bool bMust ); // allows to try to disconnect from the temporary stream
213 : // in case bMust is set to sal_True the method
214 : // will throw exception in case the file is still busy
215 :
216 : void SetModified(); // can be done only by parent storage after renaming
217 :
218 : ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > GetStreamProperties();
219 :
220 : ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > GetAllRelationshipsIfAny();
221 :
222 : void CopyInternallyTo_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream >& xDestStream,
223 : const ::comphelper::SequenceAsHashMap& aEncryptionData );
224 : void CopyInternallyTo_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream >& xDestStream );
225 :
226 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > GetStream(
227 : sal_Int32 nStreamMode,
228 : const ::comphelper::SequenceAsHashMap& aEncryptionData,
229 : sal_Bool bHierarchyAccess );
230 :
231 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > GetStream(
232 : sal_Int32 nStreamMode,
233 : sal_Bool bHierarchyAccess );
234 :
235 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > GetRawInStream();
236 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > GetPlainRawInStream();
237 :
238 : void InputStreamDisposed( OInputCompStream* pStream );
239 :
240 : void CreateReadonlyCopyBasedOnData(
241 : const ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream >& xDataToCopy,
242 : const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >& aProps,
243 : sal_Bool bUseCommonEncryption,
244 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream >& xTargetStream );
245 :
246 : void GetCopyOfLastCommit( ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream >& xTargetStream );
247 : void GetCopyOfLastCommit(
248 : ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream >& xTargetStream,
249 : const ::comphelper::SequenceAsHashMap& aEncryptionData );
250 :
251 : void CommitStreamRelInfo(
252 : const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XStorage >& xRelStorage,
253 : const OUString& aOrigStreamName,
254 : const OUString& aNewStreamName );
255 :
256 : void ReadRelInfoIfNecessary();
257 :
258 0 : sal_Int32 GetNewRelId() { return m_nRelId ++; }
259 : };
260 :
261 : class OWriteStream : ::com::sun::star::lang::XTypeProvider
262 : , public ::com::sun::star::io::XInputStream
263 : , public ::com::sun::star::io::XOutputStream
264 : , public ::com::sun::star::embed::XExtendedStorageStream
265 : , public ::com::sun::star::io::XSeekable
266 : , public ::com::sun::star::io::XTruncate
267 : , public ::com::sun::star::embed::XEncryptionProtectedSource2
268 : , public ::com::sun::star::embed::XRelationshipAccess
269 : , public ::com::sun::star::embed::XTransactedObject
270 : , public ::com::sun::star::embed::XTransactionBroadcaster
271 : , public ::com::sun::star::beans::XPropertySet
272 : , public ::cppu::OWeakObject
273 : {
274 : friend struct OWriteStream_Impl;
275 :
276 : protected:
277 : ::com::sun::star::uno::Reference < ::com::sun::star::io::XInputStream > m_xInStream;
278 : ::com::sun::star::uno::Reference < ::com::sun::star::io::XOutputStream > m_xOutStream;
279 : ::com::sun::star::uno::Reference < ::com::sun::star::io::XSeekable > m_xSeekable;
280 :
281 : OWriteStream_Impl* m_pImpl;
282 : WSInternalData_Impl* m_pData;
283 :
284 : sal_Bool m_bInStreamDisconnected;
285 : sal_Bool m_bInitOnDemand;
286 : sal_Int64 m_nInitPosition;
287 :
288 : sal_Bool m_bTransacted;
289 :
290 : OWriteStream( OWriteStream_Impl* pImpl, sal_Bool bTransacted );
291 : OWriteStream( OWriteStream_Impl* pImpl, ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream > xStream, sal_Bool bTransacted );
292 :
293 : void CloseOutput_Impl();
294 :
295 : void CopyToStreamInternally_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::io::XStream >& xStream );
296 :
297 : void ModifyParentUnlockMutex_Impl( ::osl::ResettableMutexGuard& aGuard );
298 :
299 : void BroadcastTransaction( sal_Int8 nMessage );
300 :
301 : public:
302 :
303 : virtual ~OWriteStream();
304 :
305 : void CheckInitOnDemand();
306 : void DeInit();
307 :
308 : // XInterface
309 : virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type& rType )
310 : throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
311 : virtual void SAL_CALL acquire() throw() SAL_OVERRIDE;
312 : virtual void SAL_CALL release() throw() SAL_OVERRIDE;
313 :
314 : // XTypeProvider
315 : virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes()
316 : throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
317 : virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId()
318 : throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
319 :
320 : // XInputStream
321 : virtual sal_Int32 SAL_CALL readBytes( ::com::sun::star::uno::Sequence< sal_Int8 >& aData, sal_Int32 nBytesToRead )
322 : throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
323 : virtual sal_Int32 SAL_CALL readSomeBytes( ::com::sun::star::uno::Sequence< sal_Int8 >& aData, sal_Int32 nMaxBytesToRead ) throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
324 : virtual void SAL_CALL skipBytes( sal_Int32 nBytesToSkip )
325 : throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
326 : virtual sal_Int32 SAL_CALL available( )
327 : throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
328 : virtual void SAL_CALL closeInput( )
329 : throw(::com::sun::star::io::NotConnectedException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
330 :
331 : // XOutputStream
332 : virtual void SAL_CALL writeBytes( const ::com::sun::star::uno::Sequence< sal_Int8 >& aData ) throw (::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
333 : virtual void SAL_CALL flush( ) throw (::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
334 : virtual void SAL_CALL closeOutput( ) throw (::com::sun::star::io::NotConnectedException, ::com::sun::star::io::BufferSizeExceededException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
335 :
336 : //XSeekable
337 : virtual void SAL_CALL seek( sal_Int64 location ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
338 : virtual sal_Int64 SAL_CALL getPosition() throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
339 : virtual sal_Int64 SAL_CALL getLength() throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
340 :
341 : //XStream
342 : virtual ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > SAL_CALL getInputStream( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
343 : virtual ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream > SAL_CALL getOutputStream( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
344 :
345 : // XTruncate
346 : virtual void SAL_CALL truncate() throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
347 :
348 : //XComponent
349 : virtual void SAL_CALL dispose() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
350 : virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& xListener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
351 : virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener >& aListener ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
352 :
353 : //XEncryptionProtectedSource
354 : virtual void SAL_CALL setEncryptionPassword( const OUString& aPass )
355 : throw ( ::com::sun::star::uno::RuntimeException,
356 : ::com::sun::star::io::IOException, std::exception ) SAL_OVERRIDE;
357 : virtual void SAL_CALL removeEncryption()
358 : throw ( ::com::sun::star::uno::RuntimeException,
359 : ::com::sun::star::io::IOException, std::exception ) SAL_OVERRIDE;
360 :
361 : //XEncryptionProtectedSource2
362 : virtual void SAL_CALL setEncryptionData( const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::NamedValue >& aEncryptionData ) throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
363 : virtual sal_Bool SAL_CALL hasEncryptionData() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
364 :
365 : //XRelationshipAccess
366 : virtual sal_Bool SAL_CALL hasByID( const OUString& sID ) throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
367 : virtual OUString SAL_CALL getTargetByID( const OUString& sID ) throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
368 : virtual OUString SAL_CALL getTypeByID( const OUString& sID ) throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
369 : virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > SAL_CALL getRelationshipByID( const OUString& sID ) throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
370 : virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > SAL_CALL getRelationshipsByType( const OUString& sType ) throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
371 : virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > > SAL_CALL getAllRelationships( ) throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
372 : virtual void SAL_CALL insertRelationshipByID( const OUString& sID, const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair >& aEntry, sal_Bool bReplace ) throw (::com::sun::star::container::ElementExistException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
373 : virtual void SAL_CALL removeRelationshipByID( const OUString& sID ) throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
374 : virtual void SAL_CALL insertRelationships( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair > >& aEntries, sal_Bool bReplace ) throw (::com::sun::star::container::ElementExistException, ::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
375 : virtual void SAL_CALL clearRelationships( ) throw (::com::sun::star::io::IOException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
376 :
377 : //XPropertySet
378 : virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
379 : virtual void SAL_CALL setPropertyValue( const OUString& aPropertyName, const ::com::sun::star::uno::Any& aValue ) throw ( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
380 : virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue( const OUString& PropertyName ) throw ( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
381 : virtual void SAL_CALL addPropertyChangeListener( const OUString& aPropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >& xListener ) throw ( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
382 : virtual void SAL_CALL removePropertyChangeListener( const OUString& aPropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >& aListener ) throw ( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
383 : virtual void SAL_CALL addVetoableChangeListener( const OUString& PropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XVetoableChangeListener >& aListener ) throw ( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
384 : virtual void SAL_CALL removeVetoableChangeListener( const OUString& PropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XVetoableChangeListener >& aListener ) throw ( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
385 :
386 : // XTransactedObject
387 : virtual void SAL_CALL commit()
388 : throw ( ::com::sun::star::io::IOException,
389 : ::com::sun::star::embed::StorageWrappedTargetException,
390 : ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
391 : virtual void SAL_CALL revert()
392 : throw ( ::com::sun::star::io::IOException,
393 : ::com::sun::star::embed::StorageWrappedTargetException,
394 : ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
395 :
396 : // XTransactionBroadcaster
397 : virtual void SAL_CALL addTransactionListener(
398 : const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XTransactionListener >& aListener )
399 : throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
400 : virtual void SAL_CALL removeTransactionListener(
401 : const ::com::sun::star::uno::Reference< ::com::sun::star::embed::XTransactionListener >& aListener )
402 : throw ( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
403 :
404 : };
405 :
406 : #endif
407 :
408 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|