LCOV - code coverage report
Current view: top level - xmloff/source/chart - XMLLabelSeparatorContext.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 22 0.0 %
Date: 2012-08-25 Functions: 0 11 0.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 16 0.0 %

           Branch data     Line data    Source code
       1                 :            : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2                 :            : /*************************************************************************
       3                 :            :  *
       4                 :            :  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       5                 :            :  *
       6                 :            :  * Copyright 2000, 2010 Oracle and/or its affiliates.
       7                 :            :  *
       8                 :            :  * OpenOffice.org - a multi-platform office productivity suite
       9                 :            :  *
      10                 :            :  * This file is part of OpenOffice.org.
      11                 :            :  *
      12                 :            :  * OpenOffice.org is free software: you can redistribute it and/or modify
      13                 :            :  * it under the terms of the GNU Lesser General Public License version 3
      14                 :            :  * only, as published by the Free Software Foundation.
      15                 :            :  *
      16                 :            :  * OpenOffice.org is distributed in the hope that it will be useful,
      17                 :            :  * but WITHOUT ANY WARRANTY; without even the implied warranty of
      18                 :            :  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
      19                 :            :  * GNU Lesser General Public License version 3 for more details
      20                 :            :  * (a copy is included in the LICENSE file that accompanied this code).
      21                 :            :  *
      22                 :            :  * You should have received a copy of the GNU Lesser General Public License
      23                 :            :  * version 3 along with OpenOffice.org.  If not, see
      24                 :            :  * <http://www.openoffice.org/license.html>
      25                 :            :  * for a copy of the LGPLv3 License.
      26                 :            :  *
      27                 :            :  ************************************************************************/
      28                 :            : 
      29                 :            : #include "XMLLabelSeparatorContext.hxx"
      30                 :            : 
      31                 :            : #include "SchXMLParagraphContext.hxx"
      32                 :            : #include <xmloff/xmltoken.hxx>
      33                 :            : #include <xmloff/xmltkmap.hxx>
      34                 :            : #include "xmloff/xmlnmspe.hxx"
      35                 :            : #include <xmloff/xmlimp.hxx>
      36                 :            : #include <xmloff/nmspmap.hxx>
      37                 :            : 
      38 [ #  # ][ #  # ]:          0 : TYPEINIT1( XMLLabelSeparatorContext, XMLElementPropertyContext );
      39                 :            : 
      40                 :            : using namespace ::com::sun::star;
      41                 :            : 
      42                 :          0 : XMLLabelSeparatorContext::XMLLabelSeparatorContext(
      43                 :            :     SvXMLImport& rImport, sal_uInt16 nPrfx,
      44                 :            :     const ::rtl::OUString& rLocalName,
      45                 :            :     const XMLPropertyState& rProp,
      46                 :            :     ::std::vector< XMLPropertyState > &rProps ) :
      47                 :            :         XMLElementPropertyContext(
      48                 :            :             rImport, nPrfx, rLocalName, rProp, rProps ),
      49                 :          0 :             m_aSeparator()
      50                 :            : {
      51                 :          0 : }
      52                 :            : 
      53                 :          0 : XMLLabelSeparatorContext::~XMLLabelSeparatorContext()
      54         [ #  # ]:          0 : {}
      55                 :            : 
      56                 :          0 : void XMLLabelSeparatorContext::StartElement( const uno::Reference< xml::sax::XAttributeList >& /*xAttrList*/ )
      57                 :            : {
      58                 :          0 : }
      59                 :            : 
      60                 :          0 : SvXMLImportContext* XMLLabelSeparatorContext::CreateChildContext(
      61                 :            :     sal_uInt16 nPrefix, const ::rtl::OUString& rLocalName,
      62                 :            :     const uno::Reference< xml::sax::XAttributeList > & /*xAttrList*/ )
      63                 :            : {
      64                 :          0 :     SvXMLImportContext* pContext = NULL;
      65         [ #  # ]:          0 :     if( xmloff::token::IsXMLToken( rLocalName, xmloff::token::XML_P ) )
      66                 :            :     {
      67                 :          0 :         pContext = new SchXMLParagraphContext( GetImport(),
      68         [ #  # ]:          0 :                             rLocalName, m_aSeparator );
      69                 :            :     }
      70         [ #  # ]:          0 :     if( !pContext )
      71         [ #  # ]:          0 :         pContext = new SvXMLImportContext( GetImport(), nPrefix, rLocalName );
      72                 :            : 
      73                 :          0 :     return pContext;
      74                 :            : }
      75                 :            : 
      76                 :          0 : void XMLLabelSeparatorContext::EndElement()
      77                 :            : {
      78         [ #  # ]:          0 :     if( !m_aSeparator.isEmpty() )
      79                 :            :     {
      80                 :            :         // aProp is a member of XMLElementPropertyContext
      81                 :          0 :         aProp.maValue <<= m_aSeparator;
      82                 :          0 :         SetInsert( sal_True );
      83                 :            :     }
      84                 :            : 
      85                 :          0 :     XMLElementPropertyContext::EndElement();
      86                 :          0 : }
      87                 :            : 
      88                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10