LibreOffice Module ucb (master) 1
FileAccess.cxx
Go to the documentation of this file.
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
26
27#include <tools/urlobj.hxx>
28#include <ucbhelper/content.hxx>
30#include <tools/stream.hxx>
31
32#include <com/sun/star/beans/Property.hpp>
33#include <com/sun/star/container/XChild.hpp>
34#include <com/sun/star/io/XActiveDataSink.hpp>
35#include <com/sun/star/io/XActiveDataStreamer.hpp>
36#include <com/sun/star/lang/WrappedTargetRuntimeException.hpp>
37#include <com/sun/star/lang/XServiceInfo.hpp>
38#include <com/sun/star/sdbc/XResultSet.hpp>
39#include <com/sun/star/ucb/ContentCreationException.hpp>
40#include <com/sun/star/ucb/CommandFailedException.hpp>
41#include <com/sun/star/ucb/ContentInfo.hpp>
42#include <com/sun/star/ucb/ContentInfoAttribute.hpp>
43#include <com/sun/star/ucb/InsertCommandArgument.hpp>
44#include <com/sun/star/ucb/InteractiveIOException.hpp>
45#include <com/sun/star/ucb/NameClash.hpp>
46#include <com/sun/star/ucb/OpenCommandArgument2.hpp>
47#include <com/sun/star/ucb/OpenMode.hpp>
48#include <com/sun/star/ucb/XCommandEnvironment.hpp>
49#include <com/sun/star/ucb/XContent.hpp>
50#include <com/sun/star/ucb/XContentAccess.hpp>
51#include <com/sun/star/ucb/XSimpleFileAccess3.hpp>
52#include <com/sun/star/util/theMacroExpander.hpp>
53
54#include <vector>
55
56constexpr OUStringLiteral SERVICE_NAME = u"com.sun.star.ucb.SimpleFileAccess";
57
58using namespace ::com::sun::star::uno;
59using namespace ::com::sun::star::lang;
60using namespace ::com::sun::star::io;
61using namespace ::com::sun::star::ucb;
62using namespace ::com::sun::star::sdbc;
63using namespace ::com::sun::star::task;
64using namespace ::com::sun::star::util;
65using namespace ::com::sun::star::beans;
66using namespace ::com::sun::star::registry;
67using namespace ::com::sun::star::container;
68
69using ::std::vector;
70
71namespace
72{
73
74// Implementation XSimpleFileAccess
75typedef cppu::WeakImplHelper<XSimpleFileAccess3, css::lang::XServiceInfo>
76 FileAccessHelper;
77class OCommandEnvironment;
78
79class OFileAccess : public FileAccessHelper
80{
81 Reference< XComponentContext > m_xContext;
83
87 void transferImpl( const OUString& rSource, std::u16string_view rDest, bool bMoveData );
89 bool createNewFile( const OUString & rParentURL,
90 const OUString & rTitle,
91 const Reference< XInputStream >& data );
92
93public:
94 explicit OFileAccess( const Reference< XComponentContext > & xContext )
95 : m_xContext( xContext) {}
96 // Methods
97 virtual void SAL_CALL copy( const OUString& SourceURL, const OUString& DestURL ) override;
98 virtual void SAL_CALL move( const OUString& SourceURL, const OUString& DestURL ) override;
99 virtual void SAL_CALL kill( const OUString& FileURL ) override;
100 virtual sal_Bool SAL_CALL isFolder( const OUString& FileURL ) override;
101 virtual sal_Bool SAL_CALL isReadOnly( const OUString& FileURL ) override;
102 virtual void SAL_CALL setReadOnly( const OUString& FileURL, sal_Bool bReadOnly ) override;
103 virtual void SAL_CALL createFolder( const OUString& NewFolderURL ) override;
104 virtual sal_Int32 SAL_CALL getSize( const OUString& FileURL ) override;
105 virtual OUString SAL_CALL getContentType( const OUString& FileURL ) override;
106 virtual css::util::DateTime SAL_CALL getDateTimeModified( const OUString& FileURL ) override;
107 virtual css::uno::Sequence< OUString > SAL_CALL getFolderContents( const OUString& FolderURL, sal_Bool bIncludeFolders ) override;
108 virtual sal_Bool SAL_CALL exists( const OUString& FileURL ) override;
109 virtual css::uno::Reference< css::io::XInputStream > SAL_CALL openFileRead( const OUString& FileURL ) override;
110 virtual css::uno::Reference< css::io::XOutputStream > SAL_CALL openFileWrite( const OUString& FileURL ) override;
111 virtual css::uno::Reference< css::io::XStream > SAL_CALL openFileReadWrite( const OUString& FileURL ) override;
112 virtual void SAL_CALL setInteractionHandler( const css::uno::Reference< css::task::XInteractionHandler >& Handler ) override;
113 virtual void SAL_CALL writeFile( const OUString& FileURL, const css::uno::Reference< css::io::XInputStream >& data ) override;
114 virtual sal_Bool SAL_CALL isHidden( const OUString& FileURL ) override;
115 virtual void SAL_CALL setHidden( const OUString& FileURL, sal_Bool bHidden ) override;
116
117 OUString SAL_CALL getImplementationName() override
118 { return "com.sun.star.comp.ucb.SimpleFileAccess"; }
119
120 sal_Bool SAL_CALL supportsService(OUString const & ServiceName) override
121 { return cppu::supportsService(this, ServiceName); }
122
123 css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames() override
124 { return { SERVICE_NAME }; }
125};
126
127// Implementation XActiveDataSink
128
129class OActiveDataSink : public cppu::WeakImplHelper< XActiveDataSink >
130{
131 Reference< XInputStream > mxStream;
132
133public:
134
135 // Methods
136 virtual void SAL_CALL setInputStream( const Reference< XInputStream >& aStream ) override;
137 virtual Reference< XInputStream > SAL_CALL getInputStream( ) override;
138};
139
140// Implementation XActiveDataStreamer
141
142class OActiveDataStreamer : public cppu::WeakImplHelper< XActiveDataStreamer >
143{
144 Reference< XStream > mxStream;
145
146public:
147
148 // Methods
149 virtual void SAL_CALL setStream( const Reference< XStream >& aStream ) override;
150 virtual Reference< XStream > SAL_CALL getStream() override;
151};
152
153// Implementation XCommandEnvironment
154
155class OCommandEnvironment : public cppu::WeakImplHelper< XCommandEnvironment >
156{
157 Reference< XInteractionHandler > mxInteraction;
158
159public:
160 void setHandler( const Reference< XInteractionHandler >& xInteraction_ )
161 {
162 mxInteraction = xInteraction_;
163 }
164
165 // Methods
166 virtual Reference< XInteractionHandler > SAL_CALL getInteractionHandler() override;
167 virtual Reference< XProgressHandler > SAL_CALL getProgressHandler() override;
168};
169
170void OActiveDataSink::setInputStream( const Reference< XInputStream >& aStream )
171{
172 mxStream = aStream;
173}
174
175Reference< XInputStream > OActiveDataSink::getInputStream()
176{
177 return mxStream;
178}
179
180void OActiveDataStreamer::setStream( const Reference< XStream >& aStream )
181{
182 mxStream = aStream;
183}
184
185Reference< XStream > OActiveDataStreamer::getStream()
186{
187 return mxStream;
188}
189
190Reference< XInteractionHandler > OCommandEnvironment::getInteractionHandler()
191{
192 return mxInteraction;
193}
194
195Reference< XProgressHandler > OCommandEnvironment::getProgressHandler()
196{
197 Reference< XProgressHandler > xRet;
198 return xRet;
199}
200
201void OFileAccess::transferImpl( const OUString& rSource,
202 std::u16string_view rDest,
203 bool bMoveData )
204{
205 // SfxContentHelper::Transfer_Impl
206 INetURLObject aSourceObj( rSource, INetProtocol::File );
207 INetURLObject aDestObj( rDest, INetProtocol::File );
208 OUString aName = aDestObj.getName(
210 OUString aDestURL;
211 OUString aSourceURL = aSourceObj.GetMainURL( INetURLObject::DecodeMechanism::NONE );
212 if ( aDestObj.removeSegment() )
213 {
214 // hierarchical URL.
215
216 aDestObj.setFinalSlash();
218 }
219 else
220 {
221 // non-hierarchical URL
222
223 // #i29648#
224
225
226 if ( aDestObj.GetProtocol() == INetProtocol::VndSunStarExpand )
227 {
228 // Hack: Expand destination URL using Macro Expander and try again
229 // with the hopefully hierarchical expanded URL...
230
231 try
232 {
233 Reference< XMacroExpander > xExpander = theMacroExpander::get(m_xContext);
234
235 aDestURL = xExpander->expandMacros(
237 }
238 catch ( Exception const & )
239 {
240 css::uno::Any anyEx = cppu::getCaughtException();
241 throw css::lang::WrappedTargetRuntimeException(
242 "OFileAccess::transferrImpl - Unable to obtain destination folder URL!",
243 getXWeak(), anyEx );
244 }
245
246 transferImpl( rSource, aDestURL, bMoveData );
247 return;
248 }
249
250 throw RuntimeException(
251 "OFileAccess::transferrImpl - Unable to obtain destination folder URL!",
252 getXWeak() );
253
254 }
255
256 ucbhelper::Content aDestPath( aDestURL, mxEnvironment, comphelper::getProcessComponentContext() );
257 ucbhelper::Content aSrc ( aSourceURL, mxEnvironment, comphelper::getProcessComponentContext() );
258
259 try
260 {
261 aDestPath.transferContent(aSrc,
262 bMoveData
265 aName,
266 css::ucb::NameClash::OVERWRITE);
267 }
268 catch ( css::ucb::CommandFailedException const & )
269 {
270 // Interaction Handler already handled the error that has occurred...
271 }
272}
273
274void OFileAccess::copy( const OUString& SourceURL, const OUString& DestURL )
275{
276 transferImpl( SourceURL, DestURL, false );
277}
278
279void OFileAccess::move( const OUString& SourceURL, const OUString& DestURL )
280{
281 transferImpl( SourceURL, DestURL, true );
282}
283
284void OFileAccess::kill( const OUString& FileURL )
285{
286 // SfxContentHelper::Kill
287 INetURLObject aDeleteObj( FileURL, INetProtocol::File );
289 try
290 {
291 aCnt.executeCommand( "delete", Any( true ) );
292 }
293 catch ( css::ucb::CommandFailedException const & )
294 {
295 // Interaction Handler already handled the error that has occurred...
296 }
297}
298
299sal_Bool OFileAccess::isFolder( const OUString& FileURL )
300{
301 bool bRet = false;
302 try
303 {
304 INetURLObject aURLObj( FileURL, INetProtocol::File );
306 bRet = aCnt.isFolder();
307 }
308 catch (const Exception &) {}
309 return bRet;
310}
311
312sal_Bool OFileAccess::isReadOnly( const OUString& FileURL )
313{
314 INetURLObject aURLObj( FileURL, INetProtocol::File );
316 Any aRetAny = aCnt.getPropertyValue("IsReadOnly");
317 bool bRet = false;
318 aRetAny >>= bRet;
319 return bRet;
320}
321
322void OFileAccess::setReadOnly( const OUString& FileURL, sal_Bool bReadOnly )
323{
324 INetURLObject aURLObj( FileURL, INetProtocol::File );
326 aCnt.setPropertyValue("IsReadOnly", Any(bReadOnly) );
327}
328
329void OFileAccess::createFolder( const OUString& NewFolderURL )
330{
331 // Does the folder already exist?
332 if( NewFolderURL.isEmpty() || isFolder( NewFolderURL ) )
333 return;
334
335 // SfxContentHelper::MakeFolder
336 INetURLObject aURL( NewFolderURL, INetProtocol::File );
338 if ( !aTitle.isEmpty() )
339 {
340 aURL.removeSegment();
341
342 // Does the base folder exist? Otherwise create it first
343 OUString aBaseFolderURLStr = aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE );
344 if( !isFolder( aBaseFolderURLStr ) )
345 {
346 createFolder( aBaseFolderURLStr );
347 }
348 }
349
351
352 const Sequence< ContentInfo > aInfo = aCnt.queryCreatableContentsInfo();
353
354 for ( const ContentInfo & rCurr : aInfo )
355 {
356 // Simply look for the first KIND_FOLDER...
357 if ( rCurr.Attributes & ContentInfoAttribute::KIND_FOLDER )
358 {
359 // Make sure the only required bootstrap property is "Title",
360 const Sequence< Property > & rProps = rCurr.Properties;
361 if ( rProps.getLength() != 1 )
362 continue;
363
364 if ( rProps[ 0 ].Name != "Title" )
365 continue;
366
368 try
369 {
370 if ( !aCnt.insertNewContent( rCurr.Type, { "Title" }, { Any(aTitle) }, aNew ) )
371 continue;
372
373 // Success. We're done.
374 return;
375 }
376 catch ( css::ucb::CommandFailedException const & )
377 {
378 // Interaction Handler already handled the error that has occurred...
379 continue;
380 }
381 }
382 }
383}
384
385sal_Int32 OFileAccess::getSize( const OUString& FileURL )
386{
387 // SfxContentHelper::GetSize
388 sal_Int32 nSize = 0;
389 sal_Int64 nTemp = 0;
390 INetURLObject aObj( FileURL, INetProtocol::File );
392 aCnt.getPropertyValue( "Size" ) >>= nTemp;
393 nSize = static_cast<sal_Int32>(nTemp);
394 return nSize;
395}
396
397OUString OFileAccess::getContentType( const OUString& FileURL )
398{
399 INetURLObject aObj( FileURL, INetProtocol::File );
401
402 Reference< XContent > xContent = aCnt.get();
403 OUString aTypeStr = xContent->getContentType();
404 return aTypeStr;
405}
406
407css::util::DateTime OFileAccess::getDateTimeModified( const OUString& FileURL )
408{
409 INetURLObject aFileObj( FileURL, INetProtocol::File );
410 css::util::DateTime aDateTime;
411
412 Reference< XCommandEnvironment > aCmdEnv;
414 aYoung.getPropertyValue("DateModified") >>= aDateTime;
415 return aDateTime;
416}
417
418Sequence< OUString > OFileAccess::getFolderContents( const OUString& FolderURL, sal_Bool bIncludeFolders )
419{
420 // SfxContentHelper::GetFolderContents
421
422 std::vector<OUString> aFiles;
423 INetURLObject aFolderObj( FolderURL, INetProtocol::File );
424
426 Reference< XResultSet > xResultSet;
427
429
430 try
431 {
432 xResultSet = aCnt.createCursor( {}, eInclude );
433 }
434 catch ( css::ucb::CommandFailedException const & )
435 {
436 // Interaction Handler already handled the error that has occurred...
437 }
438
439 if ( xResultSet.is() )
440 {
441 Reference< css::ucb::XContentAccess > xContentAccess( xResultSet, UNO_QUERY );
442
443 while ( xResultSet->next() )
444 {
445 OUString aId = xContentAccess->queryContentIdentifierString();
446 INetURLObject aURL( aId, INetProtocol::File );
447 aFiles.push_back( aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ) );
448 }
449 }
450
451 return comphelper::containerToSequence(aFiles);
452}
453
454sal_Bool OFileAccess::exists( const OUString& FileURL )
455{
456 bool bRet = false;
457 try
458 {
459 bRet = isFolder( FileURL );
460 if( !bRet )
461 {
462 Reference< XInputStream > xStream = openFileRead( FileURL );
463 bRet = xStream.is();
464 if( bRet )
465 xStream->closeInput();
466 }
467 }
468 catch (const Exception &) {}
469 return bRet;
470}
471
472Reference< XInputStream > OFileAccess::openFileRead( const OUString& FileURL )
473{
474 Reference< XInputStream > xRet;
475 INetURLObject aObj( FileURL, INetProtocol::File );
477
478 Reference<XActiveDataSink> xSink = new OActiveDataSink;
479
480 try
481 {
482 bool bRet = aCnt.openStream( xSink );
483 if( bRet )
484 xRet = xSink->getInputStream();
485 }
486 catch ( css::ucb::CommandFailedException const & )
487 {
488 // Interaction Handler already handled the error that has occurred...
489 }
490
491 return xRet;
492}
493
494Reference< XOutputStream > OFileAccess::openFileWrite( const OUString& FileURL )
495{
496 Reference< XOutputStream > xRet;
497 Reference< XStream > xStream = OFileAccess::openFileReadWrite( FileURL );
498 if( xStream.is() )
499 xRet = xStream->getOutputStream();
500 return xRet;
501}
502
503Reference< XStream > OFileAccess::openFileReadWrite( const OUString& FileURL )
504{
505 Reference<XActiveDataStreamer> xSink = new OActiveDataStreamer;
506
507 OpenCommandArgument2 aArg;
508 aArg.Mode = OpenMode::DOCUMENT;
509 aArg.Priority = 0; // unused
510 aArg.Sink = xSink;
511 aArg.Properties = Sequence< Property >( 0 ); // unused
512
513 Any aCmdArg;
514 aCmdArg <<= aArg;
515
516 INetURLObject aFileObj( FileURL, INetProtocol::File );
518
519 // Be silent...
520 Reference< XInteractionHandler > xIH;
521 if ( mxEnvironment.is() )
522 {
523 xIH = mxEnvironment->getInteractionHandler();
524 mxEnvironment->setHandler( nullptr );
525 }
526
527 try
528 {
529 aCnt.executeCommand( "open", aCmdArg );
530 }
531 catch ( InteractiveIOException const & e )
532 {
533 if ( xIH.is() && mxEnvironment.is() )
534 mxEnvironment->setHandler( xIH );
535
536 if ( e.Code == IOErrorCode_NOT_EXISTING )
537 {
538 // Create file...
539 SvMemoryStream aStream(0,0);
540 rtl::Reference<::utl::OInputStreamWrapper> pInput = new ::utl::OInputStreamWrapper( aStream );
541 InsertCommandArgument aInsertArg;
542 aInsertArg.Data = pInput;
543 aInsertArg.ReplaceExisting = false;
544
545 aCmdArg <<= aInsertArg;
546 aCnt.executeCommand( "insert", aCmdArg );
547
548 // Retry...
549 return openFileReadWrite( FileURL );
550 }
551
552 throw;
553 }
554
555 if ( xIH.is() && mxEnvironment.is() )
556 mxEnvironment->setHandler( xIH );
557
558 Reference< XStream > xRet = xSink->getStream();
559 return xRet;
560}
561
562void OFileAccess::setInteractionHandler( const Reference< XInteractionHandler >& Handler )
563{
564 if( !mxEnvironment.is() )
565 {
566 mxEnvironment = new OCommandEnvironment;
567 }
568 mxEnvironment->setHandler( Handler );
569}
570
571bool OFileAccess::createNewFile( const OUString & rParentURL,
572 const OUString & rTitle,
573 const Reference< XInputStream >& data )
574{
575 ucbhelper::Content aParentCnt( rParentURL, mxEnvironment, comphelper::getProcessComponentContext() );
576
577 const Sequence< ContentInfo > aInfo = aParentCnt.queryCreatableContentsInfo();
578
579 for ( const ContentInfo & rCurr : aInfo )
580 {
581 if ( ( rCurr.Attributes
582 & ContentInfoAttribute::KIND_DOCUMENT ) &&
583 ( rCurr.Attributes
584 & ContentInfoAttribute::INSERT_WITH_INPUTSTREAM ) )
585 {
586 // Make sure the only required bootstrap property is
587 // "Title",
588 const Sequence< Property > & rProps = rCurr.Properties;
589 if ( rProps.getLength() != 1 )
590 continue;
591
592 if ( rProps[ 0 ].Name != "Title" )
593 continue;
594
595 try
596 {
598 if ( aParentCnt.insertNewContent(
599 rCurr.Type, { "Title" }, { Any(rTitle) }, data, aNew ) )
600 return true; // success.
601 else
602 continue;
603 }
604 catch ( CommandFailedException const & )
605 {
606 // Interaction Handler already handled the
607 // error that has occurred...
608 continue;
609 }
610 }
611 }
612
613 return false;
614}
615
616void SAL_CALL OFileAccess::writeFile( const OUString& FileURL,
617 const Reference< XInputStream >& data )
618{
619 INetURLObject aURL( FileURL, INetProtocol::File );
620 try
621 {
623 aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ), mxEnvironment,
625
626 try
627 {
628 aCnt.writeStream( data, true /* bReplaceExisting */ );
629 }
630 catch ( CommandFailedException const & )
631 {
632 // Interaction Handler already handled the error that has occurred...
633 }
634 }
635 catch ( ContentCreationException const & e )
636 {
637 // Most probably file does not exist. Try to create.
638 if ( e.eError == ContentCreationError_CONTENT_CREATION_FAILED )
639 {
640 INetURLObject aParentURLObj( aURL );
641 if ( aParentURLObj.removeSegment() )
642 {
643 OUString aParentURL
645
646 // ensure all parent folders exist.
647 createFolder( aParentURL );
648
649 // create the new file...
650 OUString aTitle
652 true,
654 if ( createNewFile( aParentURL, aTitle, data ) )
655 {
656 // success
657 return;
658 }
659 }
660 }
661
662 throw;
663 }
664}
665
666sal_Bool OFileAccess::isHidden( const OUString& FileURL )
667{
668 INetURLObject aURLObj( FileURL, INetProtocol::File );
670 Any aRetAny = aCnt.getPropertyValue("IsHidden");
671 bool bRet = false;
672 aRetAny >>= bRet;
673 return bRet;
674}
675
676void OFileAccess::setHidden( const OUString& FileURL, sal_Bool bHidden )
677{
678 INetURLObject aURLObj( FileURL, INetProtocol::File );
680 aCnt.setPropertyValue("IsHidden", Any(bHidden) );
681}
682
683
684extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface*
685ucb_OFileAccess_get_implementation(
686 css::uno::XComponentContext* context , css::uno::Sequence<css::uno::Any> const&)
687{
688 return cppu::acquire(new OFileAccess(context));
689}
690
691}; // namespace end
692
693
694/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
constexpr OUStringLiteral SERVICE_NAME
Definition: FileAccess.cxx:56
Reference< XComponentContext > m_xContext
Reference< XInputStream > xStream
OUString getName(sal_Int32 nIndex=LAST_SEGMENT, bool bIgnoreFinalSlash=true, DecodeMechanism eMechanism=DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
OUString GetMainURL(DecodeMechanism eMechanism, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
bool removeSegment(sal_Int32 nIndex=LAST_SEGMENT, bool bIgnoreFinalSlash=true)
bool setFinalSlash()
OUString GetURLPath(DecodeMechanism eMechanism=DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
INetProtocol GetProtocol() const
css::uno::Any setPropertyValue(const OUString &rPropertyName, const css::uno::Any &rValue)
void transferContent(const Content &rSourceContent, InsertOperation eOperation, const OUString &rTitle, const sal_Int32 nNameClashAction, const OUString &rMimeType=OUString(), bool bMajorVersion=false, const OUString &rCommentVersion=OUString(), OUString *pResultURL=nullptr, const OUString &rDocumentId=OUString()) const
css::uno::Any getPropertyValue(const OUString &rPropertyName)
css::uno::Any executeCommand(const OUString &rCommandName, const css::uno::Any &rCommandArgument)
bool insertNewContent(const OUString &rContentType, const css::uno::Sequence< OUString > &rPropertyNames, const css::uno::Sequence< css::uno::Any > &rPropertyValues, Content &rNewContent)
css::uno::Sequence< css::ucb::ContentInfo > queryCreatableContentsInfo()
css::uno::Reference< css::ucb::XContent > get() const
css::uno::Reference< css::io::XInputStream > openStream()
css::uno::Reference< css::sdbc::XResultSet > createCursor(const css::uno::Sequence< OUString > &rPropertyNames, ResultSetInclude eMode=INCLUDE_FOLDERS_AND_DOCUMENTS)
void writeStream(const css::uno::Reference< css::io::XInputStream > &rStream, bool bReplaceExisting)
URL aURL
float u
bool bReadOnly
OUString aName
tools::SvRef< SvBaseLink > xSink
Reference< task::XInteractionHandler > mxInteraction
@ Exception
css::uno::Sequence< DstElementType > containerToSequence(const SrcType &i_Container)
Reference< XComponentContext > getProcessComponentContext()
css::uno::Sequence< OUString > getSupportedServiceNames()
OUString getImplementationName()
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
Any SAL_CALL getCaughtException()
void copy(const fs::path &src, const fs::path &dest)
INCLUDE_FOLDERS_AND_DOCUMENTS
INCLUDE_DOCUMENTS_ONLY
OUString Name
unsigned char sal_Bool