KEYCollector.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /*
3  * This file is part of the libetonyek 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 KEYCOLLECTOR_H_INCLUDED
11 #define KEYCOLLECTOR_H_INCLUDED
12 
13 #include <string>
14 
15 #include <boost/optional.hpp>
16 
17 #include "libetonyek_utils.h"
18 #include "KEYPath_fwd.h"
19 #include "KEYTypes_fwd.h"
20 
21 namespace libetonyek
22 {
23 
24 class KEYDefaults;
25 class KEYPropertyMap;
26 struct KEYSize;
27 
29 {
30 public:
31  virtual ~KEYCollector() = 0;
32 
33  // collector functions
34 
35  virtual void collectCellStyle(const boost::optional<ID_t> &id,
36  const boost::optional<KEYPropertyMap> &props,
37  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
38  bool ref, bool anonymous) = 0;
39  virtual void collectCharacterStyle(const boost::optional<ID_t> &id,
40  const boost::optional<KEYPropertyMap> &props,
41  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
42  bool ref, bool anonymous) = 0;
43  virtual void collectConnectionStyle(const boost::optional<ID_t> &id,
44  const boost::optional<KEYPropertyMap> &props,
45  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
46  bool ref, bool anonymous) = 0;
47  virtual void collectGraphicStyle(const boost::optional<ID_t> &id,
48  const boost::optional<KEYPropertyMap> &props,
49  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
50  bool ref, bool anonymous) = 0;
51  virtual void collectLayoutStyle(const boost::optional<ID_t> &id,
52  const boost::optional<KEYPropertyMap> &props,
53  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
54  bool ref, bool anonymous) = 0;
55  virtual void collectListStyle(const boost::optional<ID_t> &id,
56  const boost::optional<KEYPropertyMap> &props,
57  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
58  bool ref, bool anonymous) = 0;
59  virtual void collectParagraphStyle(const boost::optional<ID_t> &id,
60  const boost::optional<KEYPropertyMap> &props,
61  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
62  bool ref, bool anonymous) = 0;
63  virtual void collectPlaceholderStyle(const boost::optional<ID_t> &id,
64  const boost::optional<KEYPropertyMap> &props,
65  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
66  bool ref, bool anonymous) = 0;
67  virtual void collectSlideStyle(const boost::optional<ID_t> &id,
68  const boost::optional<KEYPropertyMap> &props,
69  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
70  bool ref, bool anonymous) = 0;
71  virtual void collectTabularStyle(const boost::optional<ID_t> &id,
72  const boost::optional<KEYPropertyMap> &props,
73  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
74  bool ref, bool anonymous) = 0;
75  virtual void collectVectorStyle(const boost::optional<ID_t> &id,
76  const boost::optional<KEYPropertyMap> &props,
77  const boost::optional<std::string> &ident, const boost::optional<std::string> &parentIdent,
78  bool ref, bool anonymous) = 0;
79 
80  virtual void collectGeometry(boost::optional<ID_t> &id,
81  boost::optional<KEYSize> &naturalSize, boost::optional<KEYPosition> &position,
82  boost::optional<double> &angle,
83  boost::optional<double> &shearXAngle, boost::optional<double> &shearYAngle,
84  boost::optional<bool> &horizontalFlip, boost::optional<bool> &verticalFlip,
85  boost::optional<bool> &aspectRatioLocked, boost::optional<bool> &sizesLocked) = 0;
86 
87  virtual void collectBezier(const boost::optional<ID_t> &id, const KEYPathPtr_t &path, bool ref) = 0;
88  virtual void collectGroup(const boost::optional<ID_t> &id, const KEYGroupPtr_t &group) = 0;
89  virtual void collectImage(const boost::optional<ID_t> &id, const KEYImagePtr_t &image) = 0;
90  virtual void collectLine(const boost::optional<ID_t> &id, const KEYLinePtr_t &line) = 0;
91  virtual void collectShape(const boost::optional<ID_t> &id) = 0;
92 
93  virtual void collectBezierPath(const boost::optional<ID_t> &id) = 0;
94  virtual void collectPolygonPath(const boost::optional<ID_t> &id, const KEYSize &size, unsigned edges) = 0;
95  virtual void collectRoundedRectanglePath(const boost::optional<ID_t> &id, const KEYSize &size, double radius) = 0;
96  virtual void collectArrowPath(const boost::optional<ID_t> &id, const KEYSize &size, double headWidth, double stemRelYPos, bool doubleSided) = 0;
97  virtual void collectStarPath(const boost::optional<ID_t> &id, const KEYSize &size, unsigned points, double innerRadius) = 0;
98  virtual void collectConnectionPath(const boost::optional<ID_t> &id, const KEYSize &size, double middleX, double middleY) = 0;
99  virtual void collectCalloutPath(const boost::optional<ID_t> &id, const KEYSize &size, double radius, double tailSize, double tailX, double tailY, bool quoteBubble) = 0;
100 
101  virtual void collectData(const boost::optional<ID_t> &id, const WPXInputStreamPtr_t &stream, const boost::optional<std::string> &displayName, const boost::optional<unsigned> &type, bool ref) = 0;
102  virtual void collectUnfiltered(const boost::optional<ID_t> &id, const boost::optional<KEYSize> &size, bool ref) = 0;
103  virtual void collectFiltered(const boost::optional<ID_t> &id, const boost::optional<KEYSize> &size) = 0;
104  virtual void collectLeveled(const boost::optional<ID_t> &id, const boost::optional<KEYSize> &size) = 0;
105  virtual void collectFilteredImage(const boost::optional<ID_t> &id, bool ref) = 0;
106  virtual void collectMovieMedia(const boost::optional<ID_t> &id) = 0;
107  virtual void collectMedia(const boost::optional<ID_t> &id) = 0;
108 
109  virtual void collectPresentation(const boost::optional<KEYSize> &size) = 0;
110 
111  virtual void collectLayer(const boost::optional<ID_t> &id, bool ref) = 0;
112  virtual void collectPage(const boost::optional<ID_t> &id) = 0;
113  virtual void collectStylesheet(const boost::optional<ID_t> &id, const boost::optional<ID_t> &parent) = 0;
114 
115  virtual void collectText(const boost::optional<ID_t> &style, const std::string &text) = 0;
116  virtual void collectTab() = 0;
117  virtual void collectLineBreak() = 0;
118 
119  virtual void collectTextPlaceholder(const boost::optional<ID_t> &id, bool title, bool ref) = 0;
120 
121  virtual void startPage() = 0;
122  virtual void endPage() = 0;
123  virtual void startLayer() = 0;
124  virtual void endLayer() = 0;
125  virtual void startGroup() = 0;
126  virtual void endGroup() = 0;
127 
128  virtual void startParagraph(const boost::optional<ID_t> &style) = 0;
129  virtual void endParagraph() = 0;
130 
139  virtual void startText() = 0;
140 
143  virtual void endText() = 0;
144 
145  // helper functions
146 
147  virtual void startSlides() = 0;
148  virtual void endSlides() = 0;
149  virtual void startThemes() = 0;
150  virtual void endThemes() = 0;
151 
152  virtual void startLevel() = 0;
153  virtual void endLevel() = 0;
154 };
155 
156 } // namespace libetonyek
157 
158 #endif // KEYCOLLECTOR_H_INCLUDED
159 
160 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
Definition: KEY2Token.h:220
virtual void endThemes()=0
Definition: KEY2Token.h:1076
virtual void startThemes()=0
virtual void collectCharacterStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectTabularStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual ~KEYCollector()=0
Definition: KEYCollector.cpp:15
virtual void endPage()=0
Definition: KEY1Token.h:85
virtual void collectFilteredImage(const boost::optional< ID_t > &id, bool ref)=0
virtual void collectStylesheet(const boost::optional< ID_t > &id, const boost::optional< ID_t > &parent)=0
virtual void collectTab()=0
Definition: KEY2Token.h:366
virtual void collectListStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectBezier(const boost::optional< ID_t > &id, const KEYPathPtr_t &path, bool ref)=0
virtual void collectImage(const boost::optional< ID_t > &id, const KEYImagePtr_t &image)=0
virtual void collectParagraphStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
Definition: KEY2Token.h:1112
Definition: KEY2Token.h:1078
virtual void collectCellStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectMedia(const boost::optional< ID_t > &id)=0
Definition: KEY2Token.h:853
virtual void collectRoundedRectanglePath(const boost::optional< ID_t > &id, const KEYSize &size, double radius)=0
virtual void endLevel()=0
virtual void startParagraph(const boost::optional< ID_t > &style)=0
boost::shared_ptr< KEYPath > KEYPathPtr_t
Definition: KEYPath_fwd.h:17
Definition: KEY2Token.h:991
virtual void collectArrowPath(const boost::optional< ID_t > &id, const KEYSize &size, double headWidth, double stemRelYPos, bool doubleSided)=0
Definition: KEY2Token.h:1077
Definition: KEY2Token.h:795
virtual void collectConnectionStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectUnfiltered(const boost::optional< ID_t > &id, const boost::optional< KEYSize > &size, bool ref)=0
Definition: KEY2Token.h:909
virtual void collectGraphicStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectData(const boost::optional< ID_t > &id, const WPXInputStreamPtr_t &stream, const boost::optional< std::string > &displayName, const boost::optional< unsigned > &type, bool ref)=0
virtual void collectLeveled(const boost::optional< ID_t > &id, const boost::optional< KEYSize > &size)=0
Definition: KEY1Token.h:51
virtual void collectCalloutPath(const boost::optional< ID_t > &id, const KEYSize &size, double radius, double tailSize, double tailX, double tailY, bool quoteBubble)=0
virtual void collectFiltered(const boost::optional< ID_t > &id, const boost::optional< KEYSize > &size)=0
virtual void collectVectorStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
boost::shared_ptr< WPXInputStream > WPXInputStreamPtr_t
Definition: libetonyek_utils.h:88
virtual void collectStarPath(const boost::optional< ID_t > &id, const KEYSize &size, unsigned points, double innerRadius)=0
Definition: KEYTypes.h:27
virtual void collectLineBreak()=0
virtual void collectPlaceholderStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectBezierPath(const boost::optional< ID_t > &id)=0
virtual void collectTextPlaceholder(const boost::optional< ID_t > &id, bool title, bool ref)=0
Definition: KEY1Token.h:49
virtual void endParagraph()=0
Definition: KEY1Token.h:92
boost::shared_ptr< KEYImage > KEYImagePtr_t
Definition: KEYTypes_fwd.h:43
virtual void collectMovieMedia(const boost::optional< ID_t > &id)=0
virtual void startGroup()=0
virtual void collectShape(const boost::optional< ID_t > &id)=0
virtual void startPage()=0
Definition: KEY1Token.h:72
boost::shared_ptr< KEYLine > KEYLinePtr_t
Definition: KEYTypes_fwd.h:29
virtual void startSlides()=0
virtual void collectPolygonPath(const boost::optional< ID_t > &id, const KEYSize &size, unsigned edges)=0
virtual void collectLayer(const boost::optional< ID_t > &id, bool ref)=0
virtual void endGroup()=0
Definition: KEY2Token.h:325
virtual void endLayer()=0
virtual void collectPresentation(const boost::optional< KEYSize > &size)=0
virtual void collectConnectionPath(const boost::optional< ID_t > &id, const KEYSize &size, double middleX, double middleY)=0
Definition: KEY1Token.h:149
Definition: KEYCollector.h:28
virtual void endText()=0
End of a text block.
virtual void startText()=0
Start of a block that can contain text.
Definition: KEY2Token.h:1102
virtual void collectGeometry(boost::optional< ID_t > &id, boost::optional< KEYSize > &naturalSize, boost::optional< KEYPosition > &position, boost::optional< double > &angle, boost::optional< double > &shearXAngle, boost::optional< double > &shearYAngle, boost::optional< bool > &horizontalFlip, boost::optional< bool > &verticalFlip, boost::optional< bool > &aspectRatioLocked, boost::optional< bool > &sizesLocked)=0
virtual void startLayer()=0
virtual void collectGroup(const boost::optional< ID_t > &id, const KEYGroupPtr_t &group)=0
virtual void collectText(const boost::optional< ID_t > &style, const std::string &text)=0
virtual void collectLayoutStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void startLevel()=0
Definition: KEY1Token.h:167
virtual void collectSlideStyle(const boost::optional< ID_t > &id, const boost::optional< KEYPropertyMap > &props, const boost::optional< std::string > &ident, const boost::optional< std::string > &parentIdent, bool ref, bool anonymous)=0
virtual void collectPage(const boost::optional< ID_t > &id)=0
Definition: KEY2Token.h:996
virtual void collectLine(const boost::optional< ID_t > &id, const KEYLinePtr_t &line)=0
Definition: KEY1Token.h:75
Definition: KEY2Token.h:357
boost::shared_ptr< KEYGroup > KEYGroupPtr_t
Definition: KEYTypes_fwd.h:56
virtual void endSlides()=0

Generated for libetonyek by doxygen 1.8.5