cfgfile 0.2.11
Loading...
Searching...
No Matches
const.hpp
Go to the documentation of this file.
1
31#ifndef CFGFILE__CONST_HPP__INCLUDED
32#define CFGFILE__CONST_HPP__INCLUDED
33
34// cfgfile include.
35#include "types.hpp"
36
37
38namespace cfgfile {
39
40//
41// const_t
42//
43
44template< typename Trait >
45struct const_t {
46 static const typename Trait::char_t c_begin_tag;
47 static const typename Trait::char_t c_end_tag;
48 static const typename Trait::char_t c_quotes;
49 static const typename Trait::char_t c_n;
50 static const typename Trait::char_t c_t;
51 static const typename Trait::char_t c_r;
52 static const typename Trait::char_t c_back_slash;
53 static const typename Trait::char_t c_space;
54 static const typename Trait::char_t c_tab;
55 static const typename Trait::char_t c_carriage_return;
56 static const typename Trait::char_t c_line_feed;
57 static const typename Trait::char_t c_vertical_bar;
58 static const typename Trait::char_t c_sharp;
59
60 static const typename Trait::string_t c_one_line_comment;
61 static const typename Trait::string_t c_start_multi_line_comment;
62 static const typename Trait::string_t c_finish_multi_line_comment;
63
64 static const typename Trait::string_t c_on;
65 static const typename Trait::string_t c_off;
66 static const typename Trait::string_t c_true;
67 static const typename Trait::string_t c_false;
68 static const typename Trait::string_t c_1;
69 static const typename Trait::string_t c_0;
70 static const typename Trait::string_t c_yes;
71 static const typename Trait::string_t c_no;
72}; // struct const_t
73
74template< typename Trait >
75const typename Trait::char_t const_t< Trait >::c_begin_tag =
76 Trait::from_ascii( '{' );
77
78template< typename Trait >
79const typename Trait::char_t const_t< Trait >::c_end_tag =
80 Trait::from_ascii( '}' );
81
82template< typename Trait >
83const typename Trait::char_t const_t< Trait >::c_quotes =
84 Trait::from_ascii( '"' );
85
86template< typename Trait >
87const typename Trait::char_t const_t< Trait >::c_n =
88 Trait::from_ascii( 'n' );
89
90template< typename Trait >
91const typename Trait::char_t const_t< Trait >::c_t =
92 Trait::from_ascii( 't' );
93
94template< typename Trait >
95const typename Trait::char_t const_t< Trait >::c_r =
96 Trait::from_ascii( 'r' );
97
98template< typename Trait >
99const typename Trait::char_t const_t< Trait >::c_back_slash =
100 Trait::from_ascii( '\\' );
101
102template< typename Trait >
103const typename Trait::char_t const_t< Trait >::c_space =
104 Trait::from_ascii( ' ' );
105
106template< typename Trait >
107const typename Trait::char_t const_t< Trait >::c_tab =
108 Trait::from_ascii( '\t' );
109
110template< typename Trait >
111const typename Trait::char_t const_t< Trait >::c_carriage_return =
112 Trait::from_ascii( '\n' );
113
114template< typename Trait >
115const typename Trait::char_t const_t< Trait >::c_line_feed =
116 Trait::from_ascii( '\r' );
117
118template< typename Trait >
119const typename Trait::char_t const_t< Trait >::c_vertical_bar =
120 Trait::from_ascii( '|' );
121
122template< typename Trait >
123const typename Trait::char_t const_t< Trait >::c_sharp =
124 Trait::from_ascii( '#' );
125
126template< typename Trait >
127const typename Trait::string_t const_t< Trait >::c_one_line_comment =
128 Trait::from_ascii( "||" );
129
130template< typename Trait >
131const typename Trait::string_t const_t< Trait >::c_start_multi_line_comment =
132 Trait::from_ascii( "|#" );
133
134template< typename Trait >
135const typename Trait::string_t const_t< Trait >::c_finish_multi_line_comment =
136 Trait::from_ascii( "#|" );
137
138template< typename Trait >
139const typename Trait::string_t const_t< Trait >::c_on =
140 Trait::from_ascii( "on" );
141
142template< typename Trait >
143const typename Trait::string_t const_t< Trait >::c_off =
144 Trait::from_ascii( "off" );
145
146template< typename Trait >
147const typename Trait::string_t const_t< Trait >::c_true =
148 Trait::from_ascii( "true" );
149
150template< typename Trait >
151const typename Trait::string_t const_t< Trait >::c_false =
152 Trait::from_ascii( "false" );
153
154template< typename Trait >
155const typename Trait::string_t const_t< Trait >::c_1 =
156 Trait::from_ascii( "1" );
157
158template< typename Trait >
159const typename Trait::string_t const_t< Trait >::c_0 =
160 Trait::from_ascii( "0" );
161
162template< typename Trait >
163const typename Trait::string_t const_t< Trait >::c_yes =
164 Trait::from_ascii( "yes" );
165
166template< typename Trait >
167const typename Trait::string_t const_t< Trait >::c_no =
168 Trait::from_ascii( "no" );
169
170} /* namespace cfgfile */
171
172#endif // CFGFILE__CONST_HPP__INCLUDED
Definition const.hpp:38
Definition const.hpp:45
static const Trait::string_t c_yes
Definition const.hpp:70
static const Trait::char_t c_sharp
Definition const.hpp:58
static const Trait::char_t c_line_feed
Definition const.hpp:56
static const Trait::char_t c_back_slash
Definition const.hpp:52
static const Trait::char_t c_r
Definition const.hpp:51
static const Trait::char_t c_tab
Definition const.hpp:54
static const Trait::string_t c_off
Definition const.hpp:65
static const Trait::char_t c_n
Definition const.hpp:49
static const Trait::string_t c_0
Definition const.hpp:69
static const Trait::string_t c_finish_multi_line_comment
Definition const.hpp:62
static const Trait::string_t c_1
Definition const.hpp:68
static const Trait::string_t c_one_line_comment
Definition const.hpp:60
static const Trait::string_t c_true
Definition const.hpp:66
static const Trait::char_t c_vertical_bar
Definition const.hpp:57
static const Trait::char_t c_quotes
Definition const.hpp:48
static const Trait::char_t c_t
Definition const.hpp:50
static const Trait::char_t c_begin_tag
Definition const.hpp:46
static const Trait::char_t c_carriage_return
Definition const.hpp:55
static const Trait::string_t c_start_multi_line_comment
Definition const.hpp:61
static const Trait::char_t c_space
Definition const.hpp:53
static const Trait::string_t c_no
Definition const.hpp:71
static const Trait::string_t c_false
Definition const.hpp:67
static const Trait::string_t c_on
Definition const.hpp:64
static const Trait::char_t c_end_tag
Definition const.hpp:47