LCOV - code coverage report
Current view: top level - sc/inc - orcusxml.hxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 0 4 0.0 %
Date: 2015-06-13 12:38:46 Functions: 0 10 0.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             : 
      10             : #ifndef INCLUDED_SC_INC_ORCUSXML_HXX
      11             : #define INCLUDED_SC_INC_ORCUSXML_HXX
      12             : 
      13             : #include "scdllapi.h"
      14             : #include "address.hxx"
      15             : #include <vcl/image.hxx>
      16             : 
      17             : #include <vector>
      18             : #include <boost/ptr_container/ptr_vector.hpp>
      19             : 
      20             : class SvTreeListEntry;
      21             : 
      22             : /**
      23             :  * Parameter used during call to ScOrcusFilters::loadXMLStructure().
      24             :  */
      25           0 : struct ScOrcusXMLTreeParam
      26             : {
      27             :     enum EntryType { ElementDefault, ElementRepeat, Attribute };
      28             : 
      29             :     /** Custom data stored with each tree item. */
      30             :     struct EntryData
      31             :     {
      32             :         size_t mnNamespaceID; /// numerical ID for xml namespace
      33             :         EntryType meType;
      34             :         ScAddress maLinkedPos; /// linked cell position (invalid if unlinked)
      35             :         bool mbRangeParent:1;
      36             :         bool mbLeafNode:1; /// Leaf if it has no child elements. Child Attributes don't count.
      37             : 
      38             :         SC_DLLPUBLIC EntryData(EntryType eType);
      39             :     };
      40             : 
      41             :     typedef boost::ptr_vector<EntryData> UserDataStoreType;
      42             : 
      43             :     Image maImgElementDefault;
      44             :     Image maImgElementRepeat;
      45             :     Image maImgAttribute;
      46             : 
      47             :     /**
      48             :      * Store all custom data instances since the tree control doesn't manage
      49             :      * the life cycle of user datas.
      50             :      */
      51             :     UserDataStoreType maUserDataStore;
      52             : 
      53             :     static SC_DLLPUBLIC EntryData* getUserData(SvTreeListEntry& rEntry);
      54             :     static SC_DLLPUBLIC const EntryData* getUserData(const SvTreeListEntry& rEntry);
      55             : };
      56             : 
      57           0 : struct ScOrcusImportXMLParam
      58             : {
      59           0 :     struct CellLink
      60             :     {
      61             :         ScAddress maPos;
      62             :         OString maPath;
      63             : 
      64             :         CellLink(const ScAddress& rPos, const OString& rPath);
      65             :     };
      66             : 
      67           0 :     struct RangeLink
      68             :     {
      69             :         ScAddress maPos;
      70             :         std::vector<OString> maFieldPaths;
      71             :     };
      72             : 
      73             :     typedef std::vector<CellLink> CellLinksType;
      74             :     typedef std::vector<RangeLink> RangeLinksType;
      75             : 
      76             :     std::vector<size_t> maNamespaces;
      77             :     CellLinksType maCellLinks;
      78             :     RangeLinksType maRangeLinks;
      79             : };
      80             : 
      81             : #endif
      82             : 
      83             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11