LCOV - code coverage report
Current view: top level - writerfilter/source/ooxml - OOXMLFastDocumentHandler.hxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 1 1 100.0 %
Date: 2015-06-13 12:38:46 Functions: 2 2 100.0 %
Legend: Lines: hit not hit

          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 INCLUDED_WRITERFILTER_SOURCE_OOXML_OOXMLFASTDOCUMENTHANDLER_HXX
      21             : #define INCLUDED_WRITERFILTER_SOURCE_OOXML_OOXMLFASTDOCUMENTHANDLER_HXX
      22             : 
      23             : #include <sal/config.h>
      24             : #include <com/sun/star/uno/XComponentContext.hpp>
      25             : #include <cppuhelper/implbase.hxx>
      26             : #include <com/sun/star/xml/sax/XFastDocumentHandler.hpp>
      27             : #include <dmapper/resourcemodel.hxx>
      28             : #include <ooxml/OOXMLDocument.hxx>
      29             : #include "OOXMLParserState.hxx"
      30             : 
      31             : namespace writerfilter {
      32             : namespace ooxml
      33             : {
      34             : 
      35             : class OOXMLFastContextHandler;
      36             : 
      37             : class OOXMLFastDocumentHandler : public cppu::WeakImplHelper<css::xml::sax::XFastDocumentHandler>
      38             : {
      39             : public:
      40             :     OOXMLFastDocumentHandler(
      41             :         css::uno::Reference< css::uno::XComponentContext > const & context,
      42             :         Stream* pStream,
      43             :         OOXMLDocumentImpl* pDocument,
      44             :         sal_Int32 nXNoteId );
      45       49908 :     virtual ~OOXMLFastDocumentHandler() {}
      46             : 
      47             :     // css::xml::sax::XFastDocumentHandler:
      48             :     virtual void SAL_CALL startDocument()
      49             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      50             :     virtual void SAL_CALL endDocument()
      51             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      52             :     virtual void SAL_CALL setDocumentLocator
      53             :     (const css::uno::Reference< css::xml::sax::XLocator > & xLocator)
      54             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      55             : 
      56             :     // css::xml::sax::XFastContextHandler:
      57             :     virtual void SAL_CALL startFastElement
      58             :     (::sal_Int32 Element,
      59             :      const css::uno::Reference< css::xml::sax::XFastAttributeList > & Attribs)
      60             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      61             :     virtual void SAL_CALL startUnknownElement
      62             :     (const OUString & Namespace,
      63             :      const OUString & Name,
      64             :      const css::uno::Reference< css::xml::sax::XFastAttributeList > & Attribs)
      65             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      66             :     virtual void SAL_CALL endFastElement(::sal_Int32 Element)
      67             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      68             :     virtual void SAL_CALL endUnknownElement
      69             :     (const OUString & Namespace,
      70             :      const OUString & Name)
      71             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      72             :     virtual css::uno::Reference< css::xml::sax::XFastContextHandler > SAL_CALL
      73             :     createFastChildContext
      74             :     (::sal_Int32 Element,
      75             :      const css::uno::Reference< css::xml::sax::XFastAttributeList > & Attribs)
      76             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      77             :     virtual css::uno::Reference< css::xml::sax::XFastContextHandler > SAL_CALL
      78             :     createUnknownChildContext
      79             :     (const OUString & Namespace,
      80             :      const OUString & Name,
      81             :      const css::uno::Reference< css::xml::sax::XFastAttributeList > & Attribs)
      82             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      83             :     virtual void SAL_CALL characters(const OUString & aChars)
      84             :         throw (css::uno::RuntimeException, css::xml::sax::SAXException, std::exception) SAL_OVERRIDE;
      85             : 
      86             :     void setIsSubstream( bool bSubstream );
      87             : 
      88             : private:
      89             :     OOXMLFastDocumentHandler(OOXMLFastDocumentHandler &) SAL_DELETED_FUNCTION;
      90             :     void operator =(OOXMLFastDocumentHandler &) SAL_DELETED_FUNCTION;
      91             : 
      92             :     css::uno::Reference< css::uno::XComponentContext > m_xContext;
      93             : 
      94             :     Stream * mpStream;
      95             : #ifdef DEBUG_WRITERFILTER
      96             :     Stream::Pointer_t mpTmpStream;
      97             : #endif
      98             :     OOXMLDocumentImpl* mpDocument;
      99             :     sal_Int32 mnXNoteId;
     100             :     mutable std::shared_ptr<OOXMLFastContextHandler> mpContextHandler;
     101             :     std::shared_ptr<OOXMLFastContextHandler> getContextHandler() const;
     102             : };
     103             : }}
     104             : 
     105             : #endif // INCLUDED_WRITERFILTER_SOURCE_OOXML_OOXMLFASTDOCUMENTHANDLER_HXX
     106             : 
     107             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11