FONTAINE  1.0
FXHTMLR.h
Go to the documentation of this file.
1 //
2 // The Fontaine Font Analysis Project
3 //
4 // Copyright (c) 2009 by Edward H. Trager
5 // All Rights Reserved
6 //
7 // Released under the GNU GPL version 2.0 or later.
8 //
9 
10 
11 //
12 // FXHTMLR.h -- Basic XHTML Report
13 //
14 
15 #ifndef FXHTMLR_INCLUDED
16 #define FXHTMLR_INCLUDED
17 
18 #include <string>
19 #include <sstream>
20 #include "MLR.h"
21 
23 public:
24  std::string commonName;
25  std::string nativeName;
26  std::string supportLevel;
27  std::string percentCoverage;
28 
29  void clear(void){
30 
31  commonName.clear();
32  nativeName.clear();
33  supportLevel.clear();
34  percentCoverage.clear();
35 
36  };
37 
38 };
39 
40 class FXHTMLR : public MLR {
41 
42 protected:
43 
44  std::string _startTag;
45  std::string _keyValuePairTag;
46  std::string _startListTag;
47  std::string _listItemTag;
48 
50 
51  std::ostringstream _introSection;
52  std::ostringstream _iconSection;
53  std::ostringstream _expandedSection;
54 
55 public:
56 
57  FXHTMLR();
58 
59  void startRoot(void);
60  void endRoot(void);
61 
62  void startList(const std::string &key);
63  void addKeyValuePairToList(const std::string &key,const std::string &value);
64  void endList(const std::string &key);
65 
66  void start(const std::string &key);
67  void addKeyValuePair(const std::string &key,const std::string &value);
68  void end(const std::string &key);
69 
70  void startList(const char *key);
71  void addKeyValuePairToList(const char *key,const char *value);
72  void endList(const char *key);
73 
74  void start(const char *key);
75  void addKeyValuePair(const char *key,const char *value);
76  void end(const char *key);
77 
78  void setStartTag(const std::string &s);
79  void setKeyValuePairTag(const std::string &s);
80  void setStartListTag(const std::string &s);
81  void setListItemTag(const std::string &s);
82  // const char * versions:
83  void setStartTag(const char *s);
84  void setKeyValuePairTag(const char *s);
85  void setStartListTag(const char *s);
86  void setListItemTag(const char *s);
87 
88 };
89 
90 #endif
91