Version 5.2.6.1, tag libreoffice-5.2.6.1
[LibreOffice.git] / writerperfect / source / draw / FreehandImportFilter.hxx
blob4d974715c766c998219f36c49eced8663c842f6b
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
6 */
8 #ifndef INCLUDED_WRITERPERFECT_SOURCE_DRAW_FREEHANDIMPORTFILTER_HXX
9 #define INCLUDED_WRITERPERFECT_SOURCE_DRAW_FREEHANDIMPORTFILTER_HXX
11 #include "ImportFilter.hxx"
13 #include "DocumentHandlerForOdg.hxx"
15 /* This component will be instantiated for both import or export. Whether it calls
16 * setSourceDocument or setTargetDocument determines which Impl function the filter
17 * member calls */
18 class FreehandImportFilter : public writerperfect::ImportFilter<OdgGenerator>
20 public:
21 explicit FreehandImportFilter(const css::uno::Reference< css::uno::XComponentContext > &rxContext)
22 : writerperfect::ImportFilter<OdgGenerator>(rxContext)
26 // XServiceInfo
27 virtual OUString SAL_CALL getImplementationName()
28 throw (css::uno::RuntimeException, std::exception) override;
29 virtual sal_Bool SAL_CALL supportsService(const OUString &ServiceName)
30 throw (css::uno::RuntimeException, std::exception) override;
31 virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames()
32 throw (css::uno::RuntimeException, std::exception) override;
34 private:
35 virtual bool doDetectFormat(librevenge::RVNGInputStream &rInput, OUString &rTypeName) override;
36 virtual bool doImportDocument(librevenge::RVNGInputStream &rInput, OdgGenerator &rGenerator, utl::MediaDescriptor &) override;
39 #endif
41 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */