LCOV - code coverage report
Current view: top level - libreoffice/sd/source/filter/eppt - grouptable.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 15 0.0 %
Date: 2012-12-27 Functions: 0 6 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             :  * 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 EPPT_GROUP_TABLE
      21             : #define EPPT_GROUP_TABLE
      22             : 
      23             : #include <com/sun/star/container/XIndexAccess.hpp>
      24             : 
      25             : struct GroupEntry
      26             : {
      27             :     sal_uInt32                  mnCurrentPos;
      28             :     sal_uInt32                  mnCount;
      29             :     ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >           mXIndexAccess;
      30             : 
      31           0 :     GroupEntry( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & rIndex )
      32           0 :     {
      33           0 :         mXIndexAccess = rIndex;
      34           0 :         mnCount =mXIndexAccess->getCount();
      35           0 :         mnCurrentPos = 0;
      36           0 :     };
      37             : 
      38           0 :     GroupEntry( sal_uInt32 nCount )
      39           0 :     {
      40           0 :         mnCount = nCount;
      41           0 :         mnCurrentPos = 0;
      42           0 :     };
      43             : 
      44           0 :     ~GroupEntry(){};
      45             : };
      46             : 
      47             : class GroupTable
      48             : {
      49             :     protected:
      50             : 
      51             :         sal_uInt32              mnIndex;
      52             :         sal_uInt32              mnCurrentGroupEntry;
      53             :         sal_uInt32              mnMaxGroupEntry;
      54             :         sal_uInt32              mnGroupsClosed;
      55             :         GroupEntry**            mpGroupEntry;
      56             : 
      57             :         void                    ImplResizeGroupTable( sal_uInt32 nEntrys );
      58             : 
      59             :     public:
      60             : 
      61           0 :         sal_uInt32              GetCurrentGroupIndex() const { return mnIndex; };
      62           0 :         sal_Int32               GetCurrentGroupLevel() const { return mnCurrentGroupEntry - 1; };
      63             :         ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > &
      64           0 :                                 GetCurrentGroupAccess() const { return mpGroupEntry[  mnCurrentGroupEntry - 1 ]->mXIndexAccess; };
      65             :         sal_uInt32              GetGroupsClosed();
      66             :         void                    ResetGroupTable( sal_uInt32 nCount );
      67             :         void                    ClearGroupTable();
      68             :         sal_Bool                EnterGroup( ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & rIndex );
      69             :         sal_Bool                GetNextGroupEntry();
      70             :                                 GroupTable();
      71             :                                 ~GroupTable();
      72             : };
      73             : 
      74             : #endif
      75             : 
      76             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10