2 * This file is part of the LibreOffice project.
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 #ifndef INCLUDED_WRITERFILTER_INC_RTFTOK_RTFDOCUMENT_HXX
10 #define INCLUDED_WRITERFILTER_INC_RTFTOK_RTFDOCUMENT_HXX
12 #include <dmapper/resourcemodel.hxx>
13 #include <com/sun/star/uno/XComponentContext.hpp>
14 #include <com/sun/star/io/XInputStream.hpp>
15 #include <com/sun/star/lang/XComponent.hpp>
16 #include <com/sun/star/frame/XFrame.hpp>
17 #include <com/sun/star/task/XStatusIndicator.hpp>
18 #include <unotools/mediadescriptor.hxx>
20 namespace writerfilter
24 /// The RTFDocument opens and resolves the RTF document.
25 class RTFDocument
: public writerfilter::Reference
<Stream
>
28 /// Pointer to this stream.
29 using Pointer_t
= tools::SvRef
<RTFDocument
>;
31 /// Resolves this document to a stream handler.
32 void resolve(Stream
& rHandler
) override
= 0;
35 /// Interface to create an RTFDocument instance.
36 class RTFDocumentFactory
39 static RTFDocument::Pointer_t
40 createDocument(css::uno::Reference
<css::uno::XComponentContext
> const& xContext
,
41 css::uno::Reference
<css::io::XInputStream
> const& xInputStream
,
42 css::uno::Reference
<css::lang::XComponent
> const& xDstDoc
,
43 css::uno::Reference
<css::frame::XFrame
> const& xFrame
,
44 css::uno::Reference
<css::task::XStatusIndicator
> const& xStatusIndicator
,
45 const utl::MediaDescriptor
& rMediaDescriptor
);
48 } // namespace writerfilter
50 #endif // INCLUDED_WRITERFILTER_INC_RTFTOK_RTFDOCUMENT_HXX
52 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */