OpenTREP Logo  0.07.18
C++ Open Travel Request Parsing Library
Loading...
Searching...
No Matches
OutputFormat.hpp
Go to the documentation of this file.
1#ifndef __OPENTREP_OUTPUTFORMAT_HPP
2#define __OPENTREP_OUTPUTFORMAT_HPP
3
4// //////////////////////////////////////////////////////////////////////
5// Import section
6// //////////////////////////////////////////////////////////////////////
7// STL
8#include <string>
9// OpenTrep
11
12namespace OPENTREP {
13
17 struct OutputFormat {
18 public:
19 typedef enum {
20 SHORT = 0,
25 } EN_OutputFormat;
26
30 static const std::string& getLabel (const EN_OutputFormat&);
31
36 static EN_OutputFormat getFormat (const char);
37
41 static char getFormatLabel (const EN_OutputFormat&);
42
46 static std::string getFormatLabelAsString (const EN_OutputFormat&);
47
51 static std::string describeLabels();
52
56 EN_OutputFormat getFormat() const;
57
61 char getFormatAsChar() const;
62
66 std::string getFormatAsString() const;
67
72 const std::string describe() const;
73
74 public:
78 bool operator== (const EN_OutputFormat&) const;
79
80 public:
84 OutputFormat (const EN_OutputFormat&);
88 OutputFormat (const char iFormat);
92 OutputFormat (const std::string& iFormat);
97
98 private:
102 OutputFormat();
103
104
105 private:
109 static const std::string _labels[LAST_VALUE];
113 static const char _formatLabels[LAST_VALUE];
114
115 private:
116 // //////// Attributes /////////
120 EN_OutputFormat _format;
121 };
122
123}
124#endif // __OPENTREP_OUTPUTFORMAT_HPP
Enumeration of output formats.
static std::string describeLabels()
bool operator==(const EN_OutputFormat &) const
static const std::string & getLabel(const EN_OutputFormat &)
OutputFormat(const EN_OutputFormat &)
std::string getFormatAsString() const
EN_OutputFormat getFormat() const
static char getFormatLabel(const EN_OutputFormat &)
static std::string getFormatLabelAsString(const EN_OutputFormat &)
const std::string describe() const