TreeFrogFramework  1.18
tfnamespace.h
Go to the documentation of this file.
1 #ifndef TFNAMESPACE_H
2 #define TFNAMESPACE_H
3 
4 class TWebApplication;
5 
11 namespace Tf
12 {
16  };
17 
21  };
22 
23  enum HttpMethod {
24  Invalid = 0,
25  Get,
29  Put,
34  };
35 
37  // Informational 1xx
38  Continue = 100,
40  // Successful 2xx
41  OK = 200,
42  Created = 201,
43  Accepted = 202,
45  NoContent = 204,
46  ResetContent = 205,
48  // Redirection 3xx
51  Found = 302,
52  SeeOther = 303,
53  NotModified = 304,
54  UseProxy = 305,
56  // Client Error 4xx
57  BadRequest = 400,
58  Unauthorized = 401,
60  Forbidden = 403,
61  NotFound = 404,
66  Conflict = 409,
67  Gone = 410,
75  // Server Error 5xx
78  BadGateway = 502,
82  };
83 
84  // Common options for AJAX
85  enum AjaxOption {
86  Asynchronous = 0, // true or false, default:true
87  ContentType, // default:"application/x-www-form-urlencoded"
88  Encoding, // default:"UTF-8"
89  Method, // Tf::Get or Tf::Post, default:Post
90  Parameters, // Default:null
91  PostBody, // Specific contents for the request body on a 'post' method
92  RequestHeaders, // See Prototype API docs
93  EvalJS, // true or false, default:true
94  EvalJSON, // true or false, default:true
95  SanitizeJSON, // true or false, See Prototype API docs
96  };
97 
98  enum AjaxEvent {
99  Create = 100, // Before request is initiated
100  Uninitialized, // Immediately after request is initiated and before loading
101  Loading, // When the remote response is being loaded by the browser
102  Loaded, // When the browser has finished loading the remote response
103  Interactive, // When the user can interact with the remote response, even though it has not finished loading
104  Success, // When the XMLHttpRequest is completed, and the HTTP status code is in the 2XX range
105  Failure, // When the XMLHttpRequest is completed, and the HTTP status code is not in the 2XX range
106  Complete, // When the XMLHttpRequest is complete (fires after success or failure, if they are present)
107  };
108 
110  Required = 0, // This value is required.
111  MaxLength, // This value is too long.
112  MinLength, // This value is too short.
113  IntMax, // This value is too big.
114  IntMin, // This value is too small.
115  DoubleMax, // This value is too big.
116  DoubleMin, // This value is too small.
117  EmailAddress, // This value is not email address.
118  Url, // This value is invalid URL.
119  Date, // This value is invalid date.
120  Time, // This value is invalid time.
121  DateTime, // This value is invalid date or time.
122  Pattern, // This value is bad format.
124 
125  // Add new rules before this line
127  };
128 
129  enum EscapeFlag {
130  Compatible = 0, // Converts double-quotes and leaves single-quotes alone.
131  Quotes, // Converts both double and single quotes.
132  NoQuotes, // Leaves both double and single quotes unconverted.
133  };
134 
135  enum SortOrder {
138  };
139 
192  //
199  };
200 
201  // Reason codes why a web socket has been closed
202  enum CloseCode {
204  GoingAway = 1001,
207  Reserved = 1004,
208  NoStatusRcvd = 1005,
217  TLSHandshake = 1015,
218  };
219 
220  enum LogPriority {
227  };
228 }
229 
230 
236 namespace TSql
237 {
239  Invalid = 0,
240  Equal, // = val
241  NotEqual, // <> val
242  LessThan, // < val
243  GreaterThan, // > val
244  LessEqual, // <= val
245  GreaterEqual, // >= val
246  IsNull, // IS NULL
247  IsEmpty, // (column IS NULL OR column = '')
248  IsNotNull, // IS NOT NULL
249  IsNotEmpty, // column IS NOT NULL AND column <> ''
250  Like, // LIKE val
251  NotLike, // NOT LIKE val
252  LikeEscape, // LIKE val1 ESCAPE val2
253  NotLikeEscape, // NOT LIKE val1 ESCAPE val2
254  ILike, // ILIKE val
255  NotILike, // NOT ILIKE val
256  ILikeEscape, // ILIKE val1 ESCAPE val2
257  NotILikeEscape, // NOT ILIKE val1 ESCAPE val2
258  In, // IN (val1, ...)
259  NotIn, // NOT IN (val1, ...)
260  Between, // BETWEEN val1 AND val2
261  NotBetween, // NOT BETWEEN val1 AND val2
262  Any, // ANY (val1, ...)
263  All, // ALL (val1, ...)
264  };
265 
266  enum JoinMode {
270  };
271 }
272 
278 namespace TMongo
279 {
281  Invalid = 0,
282  Equal = TSql::Equal, // == val
288  Exists = 100, // $exists : true
289  NotExists, // $exists : false
290  All, // $all : [ val1, ... ]
291  In, // $in : [ val1, ... ]
292  NotIn, // $nin : [ val1, ... ]
293  Mod, // $mod : [ val1, val2 ]
294  Size, // $size : val
295  Type, // $type : val
296  };
297 }
298 
299 #endif // TFNAMESPACE_H
Definition: tfnamespace.h:283
Definition: tfnamespace.h:216
Definition: tfnamespace.h:110
Definition: tfnamespace.h:173
Definition: tfnamespace.h:159
Definition: tfnamespace.h:99
Definition: tfnamespace.h:126
Definition: tfnamespace.h:185
Definition: tfnamespace.h:260
Definition: tfnamespace.h:24
Definition: tfnamespace.h:211
Definition: tfnamespace.h:175
Definition: tfnamespace.h:286
Definition: tfnamespace.h:170
Potentially harmful situations.
Definition: tfnamespace.h:223
Definition: tfnamespace.h:249
Definition: tfnamespace.h:163
Definition: tfnamespace.h:141
Definition: tfnamespace.h:41
Definition: tfnamespace.h:100
Definition: tfnamespace.h:195
Definition: tfnamespace.h:151
Definition: tfnamespace.h:61
Definition: tfnamespace.h:92
Definition: tfnamespace.h:158
Definition: tfnamespace.h:198
Definition: tfnamespace.h:76
Definition: tfnamespace.h:294
Definition: tfnamespace.h:295
Definition: tfnamespace.h:78
CloseCode
Definition: tfnamespace.h:202
Definition: tfnamespace.h:188
Definition: tfnamespace.h:26
Definition: tfnamespace.h:187
Definition: tfnamespace.h:207
Definition: tfnamespace.h:54
Definition: tfnamespace.h:262
Definition: tfnamespace.h:149
Definition: tfnamespace.h:111
Definition: tfnamespace.h:122
Definition: tfnamespace.h:184
HttpStatusCode
Definition: tfnamespace.h:36
Definition: tfnamespace.h:65
Definition: tfnamespace.h:72
Definition: tfnamespace.h:292
Definition: tfnamespace.h:143
Definition: tfnamespace.h:114
Definition: tfnamespace.h:118
Definition: tfnamespace.h:156
Finer-grained informational events than the DEBUG.
Definition: tfnamespace.h:226
Definition: tfnamespace.h:102
Definition: tfnamespace.h:60
Informational events that are most useful to debug the app.
Definition: tfnamespace.h:225
Definition: tfnamespace.h:212
Definition: tfnamespace.h:115
Definition: tfnamespace.h:119
Definition: tfnamespace.h:250
Definition: tfnamespace.h:287
Definition: tfnamespace.h:189
Definition: tfnamespace.h:179
Definition: tfnamespace.h:169
The TSql namespace contains miscellaneous identifiers used throughout the SQL library.
Definition: tfnamespace.h:244
ValidationRule
Definition: tfnamespace.h:109
Definition: tfnamespace.h:268
Definition: tfnamespace.h:79
The Tf namespace contains miscellaneous identifiers used throughout the library of TreeFrog Framework...
Definition: tdebug.h:8
Definition: tfnamespace.h:74
Definition: tfnamespace.h:155
Definition: tfnamespace.h:261
Definition: tfnamespace.h:217
Definition: tfnamespace.h:27
Definition: tfnamespace.h:49
Definition: tfnamespace.h:117
Definition: tfnamespace.h:121
Definition: tfnamespace.h:95
Definition: tfnamespace.h:145
Definition: tfnamespace.h:183
AppAttribute
Definition: tfnamespace.h:140
Definition: tfnamespace.h:288
EscapeFlag
Definition: tfnamespace.h:129
Definition: tfnamespace.h:243
Definition: tfnamespace.h:204
Definition: tfnamespace.h:77
Definition: tfnamespace.h:29
Definition: tfnamespace.h:39
Definition: tfnamespace.h:269
Definition: tfnamespace.h:70
Definition: tfnamespace.h:182
Definition: tfnamespace.h:30
Definition: tfnamespace.h:91
Definition: tfnamespace.h:15
Definition: tfnamespace.h:148
LogPriority
Definition: tfnamespace.h:220
Definition: tfnamespace.h:172
Definition: tfnamespace.h:252
Definition: tfnamespace.h:58
Definition: tfnamespace.h:28
Definition: tfnamespace.h:66
Definition: tfnamespace.h:162
Definition: tfnamespace.h:160
Definition: tfnamespace.h:86
Definition: tfnamespace.h:181
Definition: tfnamespace.h:167
Definition: tfnamespace.h:174
Definition: tfnamespace.h:103
ComparisonOperator
Definition: tfnamespace.h:238
Definition: tfnamespace.h:215
Definition: tfnamespace.h:245
Definition: tfnamespace.h:57
Definition: tfnamespace.h:31
Definition: tfnamespace.h:67
Definition: tfnamespace.h:193
Definition: tfnamespace.h:267
Definition: tfnamespace.h:50
Definition: tfnamespace.h:59
Definition: tfnamespace.h:152
ComparisonOperator
Definition: tfnamespace.h:280
Definition: tfnamespace.h:164
Definition: tfnamespace.h:46
Definition: tfnamespace.h:256
AjaxEvent
Definition: tfnamespace.h:98
Definition: tfnamespace.h:282
Definition: tfnamespace.h:180
Definition: tfnamespace.h:144
HttpMethod
Definition: tfnamespace.h:23
Definition: tfnamespace.h:68
Definition: tfnamespace.h:43
Definition: tfnamespace.h:113
Definition: tfnamespace.h:157
Definition: tfnamespace.h:153
Definition: tfnamespace.h:14
Definition: tfnamespace.h:142
Definition: tfnamespace.h:105
Definition: tfnamespace.h:186
The TMongo namespace contains miscellaneous identifiers used throughout the MongoDB library...
Definition: tfnamespace.h:25
Definition: tfnamespace.h:55
AjaxOption
Definition: tfnamespace.h:85
Definition: tfnamespace.h:19
Definition: tfnamespace.h:241
Definition: tfnamespace.h:123
Definition: tfnamespace.h:53
Definition: tfnamespace.h:88
Definition: tfnamespace.h:120
Error events that might still allow the app to continue running.
Definition: tfnamespace.h:222
Definition: tfnamespace.h:247
Definition: tfnamespace.h:213
QuotedStrSplitBehavior
Definition: tfnamespace.h:13
Definition: tfnamespace.h:161
Definition: tfnamespace.h:293
Definition: tfnamespace.h:137
Definition: tfnamespace.h:104
Definition: tfnamespace.h:171
Definition: tfnamespace.h:81
Definition: tfnamespace.h:178
Definition: tfnamespace.h:64
Definition: tfnamespace.h:255
Definition: tfnamespace.h:147
Definition: tfnamespace.h:136
Definition: tfnamespace.h:80
Definition: tfnamespace.h:47
Definition: tfnamespace.h:248
Definition: tfnamespace.h:240
Definition: tfnamespace.h:154
Definition: tfnamespace.h:71
Definition: tfnamespace.h:62
Definition: tfnamespace.h:209
Definition: tfnamespace.h:69
Definition: tfnamespace.h:94
Definition: tfnamespace.h:197
Definition: tfnamespace.h:284
Definition: tfnamespace.h:246
Definition: tfnamespace.h:190
Definition: tfnamespace.h:73
Definition: tfnamespace.h:210
Informational messages that highlight the progress of the app.
Definition: tfnamespace.h:224
Definition: tfnamespace.h:206
Definition: tfnamespace.h:291
Definition: tfnamespace.h:203
Definition: tfnamespace.h:168
Definition: tfnamespace.h:205
Definition: tfnamespace.h:89
Definition: tfnamespace.h:132
Definition: tfnamespace.h:150
Definition: tfnamespace.h:130
The TWebApplication class provides an event loop for TreeFrog applications.
Definition: twebapplication.h:19
Definition: tfnamespace.h:38
CaseSensitivity
Definition: tfnamespace.h:18
Definition: tfnamespace.h:214
Definition: tfnamespace.h:285
Definition: tfnamespace.h:251
Definition: tfnamespace.h:131
Definition: tfnamespace.h:146
Definition: tfnamespace.h:191
Definition: tfnamespace.h:63
Definition: tfnamespace.h:90
Definition: tfnamespace.h:101
Definition: tfnamespace.h:257
JoinMode
Definition: tfnamespace.h:266
Definition: tfnamespace.h:106
Definition: tfnamespace.h:93
Definition: tfnamespace.h:32
SortOrder
Definition: tfnamespace.h:135
Definition: tfnamespace.h:33
Definition: tfnamespace.h:194
Definition: tfnamespace.h:44
Definition: tfnamespace.h:177
Definition: tfnamespace.h:87
Definition: tfnamespace.h:45
Definition: tfnamespace.h:253
Severe error events that will presumably lead the app to abort.
Definition: tfnamespace.h:221
Definition: tfnamespace.h:165
Definition: tfnamespace.h:289
Definition: tfnamespace.h:166
Definition: tfnamespace.h:42
Definition: tfnamespace.h:242
Definition: tfnamespace.h:20
Definition: tfnamespace.h:208
Definition: tfnamespace.h:52
Definition: tfnamespace.h:112
Definition: tfnamespace.h:196
Definition: tfnamespace.h:254
Definition: tfnamespace.h:116
Definition: tfnamespace.h:290
Definition: tfnamespace.h:51
Definition: tfnamespace.h:176