• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

pp_TableAttrProp.h

Go to the documentation of this file.
00001 /* -*- mode: C++; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: t -*- */
00002 /* AbiWord
00003  * Copyright (C) 1998 AbiSource, Inc.
00004  *
00005  * This program is free software; you can redistribute it and/or
00006  * modify it under the terms of the GNU General Public License
00007  * as published by the Free Software Foundation; either version 2
00008  * of the License, or (at your option) any later version.
00009  *
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU General Public License
00016  * along with this program; if not, write to the Free Software
00017  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
00018  * 02110-1301 USA.
00019  */
00020 
00021 
00022 #ifndef PP_TABLEATTRPROP_H
00023 #define PP_TABLEATTRPROP_H
00024 
00025 #include "ut_types.h"
00026 #include "ut_vector.h"
00027 #include "pt_Types.h"
00028 #include "pp_AttrProp.h"
00029 
00030 
00031 // pp_TableAttrProp implements an unbounded table of PP_AttrProp
00032 // objects.  Each PP_AttrProp represents the complete Attribute/
00033 // Property state of one or more pieces (subsequences) of the
00034 // document.
00035 
00036 class ABI_EXPORT pp_TableAttrProp
00037 {
00038 public:
00039     pp_TableAttrProp();
00040     ~pp_TableAttrProp();
00041 
00042     bool                    addAP(PP_AttrProp * pAP,
00043                                   UT_sint32 * pSubscript);
00044     bool                    createAP(UT_sint32 * pSubscript);
00045 
00046     bool                    createAP(const PP_PropertyVector & attributes,
00047                                      const PP_PropertyVector & properties,
00048                                      UT_sint32 * pSubscript);
00049 
00050     bool                    createAP(const PP_PropertyVector & pVector,
00051                                      UT_sint32 * pSubscript);
00052 
00053     bool                    findMatch(const PP_AttrProp * pMatch,
00054                                       UT_sint32 * pSubscript) const;
00055 
00056     const PP_AttrProp *     getAP(UT_sint32 subscript) const;
00057 
00058 protected:
00059     UT_GenericVector<PP_AttrProp *> m_vecTable;
00060     UT_GenericVector<PP_AttrProp *> m_vecTableSorted;
00061 };
00062 
00063 #endif /* PP_TABLEATTRPROP_H */

Generated on Sun Feb 14 2021 for AbiWord by  doxygen 1.7.1