-
Notifications
You must be signed in to change notification settings - Fork 0
/
amelinium.web.html
326 lines (326 loc) · 229 KB
/
amelinium.web.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
<!DOCTYPE html PUBLIC ""
"">
<html><head><meta charset="UTF-8" /><title>amelinium.web documentation</title><link rel="stylesheet" type="text/css" href="css/default.css" /><link rel="stylesheet" type="text/css" href="css/highlight.css" /><script type="text/javascript" src="js/highlight.min.js"></script><script type="text/javascript" src="js/jquery.min.js"></script><script type="text/javascript" src="js/page_effects.js"></script><script>hljs.initHighlightingOnLoad();</script><link rel="stylesheet" type="text/css" href="css/randomseed.css" /></head><body><div id="header"><h2>Generated by <a href="https://github.com/weavejester/codox">Codox</a></h2><h1><a href="index.html"><span class="project-title"><span class="project-name">Amelinium</span> <span class="project-version">1.0.1</span></span></a></h1></div><div class="sidebar primary"><h3 class="no-link"><span class="inner">Project</span></h3><ul class="index-link"><li class="depth-1 "><a href="index.html"><div class="inner">Index</div></a></li></ul><h3 class="no-link"><span class="inner">Topics</span></h3><ul><li class="depth-1 "><a href="10_introduction.html"><div class="inner"><span>Introduction</span></div></a></li><li class="depth-1 "><a href="20_hypermedia.html"><div class="inner"><span>Hypermedia-driven</span></div></a></li></ul><h3 class="no-link"><span class="inner">Namespaces</span></h3><ul><li class="depth-1"><a href="amelinium.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>amelinium</span></div></a></li><li class="depth-2 branch"><a href="amelinium.admin.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>admin</span></div></a></li><li class="depth-2"><a href="amelinium.api.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>api</span></div></a></li><li class="depth-3"><a href="amelinium.api.controller.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>controller</span></div></a></li><li class="depth-4"><a href="amelinium.api.controller.user.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>user</span></div></a></li><li class="depth-3"><a href="amelinium.api.url.html"><div class="inner"><span class="tree" style="top: -52px;"><span class="top" style="height: 61px;"></span><span class="bottom"></span></span><span>url</span></div></a></li><li class="depth-2 branch"><a href="amelinium.app.html"><div class="inner"><span class="tree" style="top: -114px;"><span class="top" style="height: 123px;"></span><span class="bottom"></span></span><span>app</span></div></a></li><li class="depth-2"><a href="amelinium.auth.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>auth</span></div></a></li><li class="depth-3"><div class="no-link"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>algo</span></div></div></li><li class="depth-4 branch"><a href="amelinium.auth.algo.append.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>append</span></div></a></li><li class="depth-4 branch"><a href="amelinium.auth.algo.fail.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>fail</span></div></a></li><li class="depth-4 branch"><a href="amelinium.auth.algo.pbkdf2.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>pbkdf2</span></div></a></li><li class="depth-4"><a href="amelinium.auth.algo.scrypt.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>scrypt</span></div></a></li><li class="depth-3 branch"><a href="amelinium.auth.pwd.html"><div class="inner"><span class="tree" style="top: -145px;"><span class="top" style="height: 154px;"></span><span class="bottom"></span></span><span>pwd</span></div></a></li><li class="depth-3"><a href="amelinium.auth.specs.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>specs</span></div></a></li><li class="depth-2"><a href="amelinium.common.html"><div class="inner"><span class="tree" style="top: -238px;"><span class="top" style="height: 247px;"></span><span class="bottom"></span></span><span>common</span></div></a></li><li class="depth-3 branch"><a href="amelinium.common.controller.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>controller</span></div></a></li><li class="depth-3"><a href="amelinium.common.oplog.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>oplog</span></div></a></li><li class="depth-4"><a href="amelinium.common.oplog.auth.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>auth</span></div></a></li><li class="depth-3 branch"><a href="amelinium.common.populators.html"><div class="inner"><span class="tree" style="top: -52px;"><span class="top" style="height: 61px;"></span><span class="bottom"></span></span><span>populators</span></div></a></li><li class="depth-3"><a href="amelinium.common.swagger.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>swagger</span></div></a></li><li class="depth-2 branch"><a href="amelinium.core.html"><div class="inner"><span class="tree" style="top: -176px;"><span class="top" style="height: 185px;"></span><span class="bottom"></span></span><span>core</span></div></a></li><li class="depth-2"><a href="amelinium.db.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>db</span></div></a></li><li class="depth-3"><a href="amelinium.db.sql.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>sql</span></div></a></li><li class="depth-2 branch"><a href="amelinium.errors.html"><div class="inner"><span class="tree" style="top: -52px;"><span class="top" style="height: 61px;"></span><span class="bottom"></span></span><span>errors</span></div></a></li><li class="depth-2"><a href="amelinium.http.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>http</span></div></a></li><li class="depth-3"><div class="no-link"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>client</span></div></div></li><li class="depth-4"><a href="amelinium.http.client.twilio.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>twilio</span></div></a></li><li class="depth-3 branch"><a href="amelinium.http.handler.html"><div class="inner"><span class="tree" style="top: -52px;"><span class="top" style="height: 61px;"></span><span class="bottom"></span></span><span>handler</span></div></a></li><li class="depth-3"><a href="amelinium.http.middleware.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>middleware</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.coercion.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>coercion</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.content.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>content</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.db.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>db</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.debug.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>debug</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.format.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>format</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.headers.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>headers</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.language.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>language</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.lazy-req.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>lazy-req</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.populators.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>populators</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.remote-ip.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>remote-ip</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.roles.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>roles</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.middleware.session.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>session</span></div></a></li><li class="depth-4"><a href="amelinium.http.middleware.validators.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>validators</span></div></a></li><li class="depth-3 branch"><a href="amelinium.http.router.html"><div class="inner"><span class="tree" style="top: -424px;"><span class="top" style="height: 433px;"></span><span class="bottom"></span></span><span>router</span></div></a></li><li class="depth-3"><a href="amelinium.http.server.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>server</span></div></a></li><li class="depth-4 branch"><a href="amelinium.http.server.jetty.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>jetty</span></div></a></li><li class="depth-4"><a href="amelinium.http.server.undertow.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>undertow</span></div></a></li><li class="depth-2"><a href="amelinium.i18n.html"><div class="inner"><span class="tree" style="top: -672px;"><span class="top" style="height: 681px;"></span><span class="bottom"></span></span><span>i18n</span></div></a></li><li class="depth-3"><a href="amelinium.i18n.pluralizers.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>pluralizers</span></div></a></li><li class="depth-2 branch"><a href="amelinium.identity.html"><div class="inner"><span class="tree" style="top: -52px;"><span class="top" style="height: 61px;"></span><span class="bottom"></span></span><span>identity</span></div></a></li><li class="depth-2 branch"><a href="amelinium.locale.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>locale</span></div></a></li><li class="depth-2 branch"><a href="amelinium.logging.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>logging</span></div></a></li><li class="depth-2"><div class="no-link"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>model</span></div></div></li><li class="depth-3 branch"><a href="amelinium.model.confirmation.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>confirmation</span></div></a></li><li class="depth-3"><a href="amelinium.model.user.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>user</span></div></a></li><li class="depth-2"><div class="no-link"><div class="inner"><span class="tree" style="top: -83px;"><span class="top" style="height: 92px;"></span><span class="bottom"></span></span><span>proto</span></div></div></li><li class="depth-3 branch"><a href="amelinium.proto.auth.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>auth</span></div></a></li><li class="depth-3 branch"><a href="amelinium.proto.errors.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>errors</span></div></a></li><li class="depth-3 branch"><a href="amelinium.proto.identity.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>identity</span></div></a></li><li class="depth-3 branch"><a href="amelinium.proto.session.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>session</span></div></a></li><li class="depth-3"><a href="amelinium.proto.twilio.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>twilio</span></div></a></li><li class="depth-2 branch"><a href="amelinium.schemas.html"><div class="inner"><span class="tree" style="top: -176px;"><span class="top" style="height: 185px;"></span><span class="bottom"></span></span><span>schemas</span></div></a></li><li class="depth-2"><div class="no-link"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>server</span></div></div></li><li class="depth-3"><a href="amelinium.server.ssl.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>ssl</span></div></a></li><li class="depth-2 branch"><a href="amelinium.system.html"><div class="inner"><span class="tree" style="top: -52px;"><span class="top" style="height: 61px;"></span><span class="bottom"></span></span><span>system</span></div></a></li><li class="depth-2"><div class="no-link"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>types</span></div></div></li><li class="depth-3 branch"><a href="amelinium.types.auth.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>auth</span></div></a></li><li class="depth-3 branch"><a href="amelinium.types.db.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>db</span></div></a></li><li class="depth-3 branch"><a href="amelinium.types.errors.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>errors</span></div></a></li><li class="depth-3 branch"><a href="amelinium.types.identity.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>identity</span></div></a></li><li class="depth-3 branch"><a href="amelinium.types.session.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>session</span></div></a></li><li class="depth-3"><a href="amelinium.types.twilio.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>twilio</span></div></a></li><li class="depth-2 branch"><a href="amelinium.utils.html"><div class="inner"><span class="tree" style="top: -207px;"><span class="top" style="height: 216px;"></span><span class="bottom"></span></span><span>utils</span></div></a></li><li class="depth-2 current"><a href="amelinium.web.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>web</span></div></a></li><li class="depth-3"><a href="amelinium.web.controller.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>controller</span></div></a></li><li class="depth-4 branch"><a href="amelinium.web.controller.admin.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>admin</span></div></a></li><li class="depth-4"><a href="amelinium.web.controller.user.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>user</span></div></a></li><li class="depth-3 branch"><a href="amelinium.web.js.html"><div class="inner"><span class="tree" style="top: -83px;"><span class="top" style="height: 92px;"></span><span class="bottom"></span></span><span>js</span></div></a></li><li class="depth-3 branch"><a href="amelinium.web.taggers.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>taggers</span></div></a></li><li class="depth-3"><a href="amelinium.web.url.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>url</span></div></a></li></ul></div><div class="sidebar secondary"><h3><a href="#top"><span class="inner">Public Vars</span></a></h3><ul><li class="depth-1"><a href="amelinium.web.html#var-add-app-data"><div class="inner"><span>add-app-data</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-add-header"><div class="inner"><span>add-header</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-add-headers"><div class="inner"><span>add-headers</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-add-missing-sub-status"><div class="inner"><span>add-missing-sub-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-add-slash"><div class="inner"><span>add-slash</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-add-status"><div class="inner"><span>add-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-app-data"><div class="inner"><span>app-data</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-assoc-app-data"><div class="inner"><span>assoc-app-data</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-auth-page"><div class="inner"><span>auth-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-auth-page.3F"><div class="inner"><span>auth-page?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-common-auth-keys"><div class="inner"><span>common-auth-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-common-keys"><div class="inner"><span>common-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-current-page"><div class="inner"><span>current-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-current-page-id"><div class="inner"><span>current-page-id</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-current-page-id-or-path"><div class="inner"><span>current-page-id-or-path</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-def-render"><div class="inner"><span>def-render</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-default-contexts-labeler"><div class="inner"><span>default-contexts-labeler</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-default-html"><div class="inner"><span>default-html</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-dot-html"><div class="inner"><span>dot-html</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-form-params-error.21"><div class="inner"><span>form-params-error!</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-for-status"><div class="inner"><span>get-for-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-layout"><div class="inner"><span>get-layout</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-layout-dir"><div class="inner"><span>get-layout-dir</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-missing-app-data-from-req"><div class="inner"><span>get-missing-app-data-from-req</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-target"><div class="inner"><span>get-target</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-view"><div class="inner"><span>get-view</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-get-view-dir"><div class="inner"><span>get-view-dir</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-go-to"><div class="inner"><span>go-to</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-go-to-with-status"><div class="inner"><span>go-to-with-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-guess-lang-param"><div class="inner"><span>guess-lang-param</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-handle-bad-request-form-params"><div class="inner"><span>handle-bad-request-form-params</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-handle-error"><div class="inner"><span>handle-error</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hard-lock-time"><div class="inner"><span>hard-lock-time</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hard-locked.3F"><div class="inner"><span>hard-locked?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-has-any-role.3F"><div class="inner"><span>has-any-role?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-has-param.3F"><div class="inner"><span>has-param?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-has-role.3F"><div class="inner"><span>has-role?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-http-go-to"><div class="inner"><span>http-go-to</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-http-go-to-with-status"><div class="inner"><span>http-go-to-with-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-http-handle-bad-request-form-params"><div class="inner"><span>http-handle-bad-request-form-params</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-http-move-to"><div class="inner"><span>http-move-to</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-go-to"><div class="inner"><span>hx-go-to</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-go-to-with-status"><div class="inner"><span>hx-go-to-with-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-handle-bad-request-form-params"><div class="inner"><span>hx-handle-bad-request-form-params</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-inject"><div class="inner"><span>hx-inject</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-localized-redirect"><div class="inner"><span>hx-localized-redirect</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-move-to"><div class="inner"><span>hx-move-to</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-redirect"><div class="inner"><span>hx-redirect</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-request.3F"><div class="inner"><span>hx-request?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-target"><div class="inner"><span>hx-target</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-hx-transform-redirect"><div class="inner"><span>hx-transform-redirect</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-i18n-keys"><div class="inner"><span>i18n-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lang-config"><div class="inner"><span>lang-config</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lang-from-req"><div class="inner"><span>lang-from-req</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lang-id"><div class="inner"><span>lang-id</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lang-param"><div class="inner"><span>lang-param</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lang-redir"><div class="inner"><span>lang-redir</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lang-str"><div class="inner"><span>lang-str</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-language-keys"><div class="inner"><span>language-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-layouts-str"><div class="inner"><span>layouts-str</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-localized-page"><div class="inner"><span>localized-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-localized-path"><div class="inner"><span>localized-path</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-localized-render-created"><div class="inner"><span>localized-render-created</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-localized-see-other"><div class="inner"><span>localized-see-other</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-localized-temporary-redirect"><div class="inner"><span>localized-temporary-redirect</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lock-wait"><div class="inner"><span>lock-wait</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-lock-wait-default"><div class="inner"><span>lock-wait-default</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-login-auth-state"><div class="inner"><span>login-auth-state</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-login-page"><div class="inner"><span>login-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-login-page.3F"><div class="inner"><span>login-page?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-map-to-lazy"><div class="inner"><span>map-to-lazy</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-move-to"><div class="inner"><span>move-to</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-no-app-data"><div class="inner"><span>no-app-data</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-no-app-data.3F"><div class="inner"><span>no-app-data?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-on-page.3F"><div class="inner"><span>on-page?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-page"><div class="inner"><span>page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-page-keys"><div class="inner"><span>page-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-param-keys"><div class="inner"><span>param-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-parameterized-page"><div class="inner"><span>parameterized-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-path"><div class="inner"><span>path</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-path-language"><div class="inner"><span>path-language</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-path-param"><div class="inner"><span>path-param</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-path-params"><div class="inner"><span>path-params</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-path-template-with-param"><div class="inner"><span>path-template-with-param</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-path-variants"><div class="inner"><span>path-variants</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-pick-language"><div class="inner"><span>pick-language</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-pick-language-str"><div class="inner"><span>pick-language-str</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-pick-language-str-without-fallback"><div class="inner"><span>pick-language-str-without-fallback</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-pick-language-without-fallback"><div class="inner"><span>pick-language-without-fallback</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-prep-app-data"><div class="inner"><span>prep-app-data</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-remote-ip-keys"><div class="inner"><span>remote-ip-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-remove-status"><div class="inner"><span>remove-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render"><div class="inner"><span>render</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-accepted"><div class="inner"><span>render-accepted</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-already-reported"><div class="inner"><span>render-already-reported</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-bad-gateway"><div class="inner"><span>render-bad-gateway</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-bad-params"><div class="inner"><span>render-bad-params</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-bad-request"><div class="inner"><span>render-bad-request</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-bandwidth-limit-exceeded"><div class="inner"><span>render-bandwidth-limit-exceeded</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-blocked-by-windows-parental-controls"><div class="inner"><span>render-blocked-by-windows-parental-controls</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-conflict"><div class="inner"><span>render-conflict</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-continue"><div class="inner"><span>render-continue</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-created"><div class="inner"><span>render-created</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-early-hints"><div class="inner"><span>render-early-hints</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-enhance-your-calm"><div class="inner"><span>render-enhance-your-calm</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-error"><div class="inner"><span>render-error</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-expectation-failed"><div class="inner"><span>render-expectation-failed</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-failed-dependency"><div class="inner"><span>render-failed-dependency</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-forbidden"><div class="inner"><span>render-forbidden</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-found"><div class="inner"><span>render-found</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-gateway-timeout"><div class="inner"><span>render-gateway-timeout</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-gone"><div class="inner"><span>render-gone</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-http-version-not-supported"><div class="inner"><span>render-http-version-not-supported</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-im-a-teapot"><div class="inner"><span>render-im-a-teapot</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-im-used"><div class="inner"><span>render-im-used</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-insufficient-storage"><div class="inner"><span>render-insufficient-storage</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-internal-server-error"><div class="inner"><span>render-internal-server-error</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-length-required"><div class="inner"><span>render-length-required</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-locked"><div class="inner"><span>render-locked</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-loop-detected"><div class="inner"><span>render-loop-detected</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-method-not-allowed"><div class="inner"><span>render-method-not-allowed</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-misdirected-request"><div class="inner"><span>render-misdirected-request</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-multi-status"><div class="inner"><span>render-multi-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-network-authentication-required"><div class="inner"><span>render-network-authentication-required</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-network-connect-timeout"><div class="inner"><span>render-network-connect-timeout</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-network-read-timeout"><div class="inner"><span>render-network-read-timeout</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-no-content"><div class="inner"><span>render-no-content</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-non-authoritative-information"><div class="inner"><span>render-non-authoritative-information</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-not-acceptable"><div class="inner"><span>render-not-acceptable</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-not-extended"><div class="inner"><span>render-not-extended</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-not-found"><div class="inner"><span>render-not-found</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-not-implemented"><div class="inner"><span>render-not-implemented</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-ok"><div class="inner"><span>render-ok</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-page"><div class="inner"><span>render-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-partial-content"><div class="inner"><span>render-partial-content</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-payment-required"><div class="inner"><span>render-payment-required</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-precondition-failed"><div class="inner"><span>render-precondition-failed</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-precondition-required"><div class="inner"><span>render-precondition-required</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-processing"><div class="inner"><span>render-processing</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-proxy-authentication-required"><div class="inner"><span>render-proxy-authentication-required</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-request-entity-too-large"><div class="inner"><span>render-request-entity-too-large</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-request-header-fields-too-large"><div class="inner"><span>render-request-header-fields-too-large</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-request-timeout"><div class="inner"><span>render-request-timeout</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-request-uri-too-long"><div class="inner"><span>render-request-uri-too-long</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-requested-range-not-satisfiable"><div class="inner"><span>render-requested-range-not-satisfiable</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-reset-content"><div class="inner"><span>render-reset-content</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-response"><div class="inner"><span>render-response</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-response-force"><div class="inner"><span>render-response-force</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-retry-with"><div class="inner"><span>render-retry-with</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-service-unavailable"><div class="inner"><span>render-service-unavailable</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-status"><div class="inner"><span>render-status</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-switching-protocols"><div class="inner"><span>render-switching-protocols</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-too-early"><div class="inner"><span>render-too-early</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-too-many-requests"><div class="inner"><span>render-too-many-requests</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-unauthorized"><div class="inner"><span>render-unauthorized</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-unavailable-for-legal-reasons"><div class="inner"><span>render-unavailable-for-legal-reasons</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-unordered-collection"><div class="inner"><span>render-unordered-collection</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-unprocessable-entity"><div class="inner"><span>render-unprocessable-entity</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-unsupported-media-type"><div class="inner"><span>render-unsupported-media-type</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-upgrade-required"><div class="inner"><span>render-upgrade-required</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-render-variant-also-negotiates"><div class="inner"><span>render-variant-also-negotiates</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-resolve-cached"><div class="inner"><span>resolve-cached</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-resolve-generic"><div class="inner"><span>resolve-generic</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-resolve-layout"><div class="inner"><span>resolve-layout</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-resolve-view"><div class="inner"><span>resolve-view</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-response"><div class="inner"><span>response</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-response-status.3F"><div class="inner"><span>response-status?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-response.3F"><div class="inner"><span>response?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-role-required.21"><div class="inner"><span>role-required!</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-roles-for-context"><div class="inner"><span>roles-for-context</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-roles-for-contexts"><div class="inner"><span>roles-for-contexts</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-roles-keys"><div class="inner"><span>roles-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-roles-matrix"><div class="inner"><span>roles-matrix</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-roles-table"><div class="inner"><span>roles-table</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-roles-tabler"><div class="inner"><span>roles-tabler</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-router-match.3F"><div class="inner"><span>router-match?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-see-other"><div class="inner"><span>see-other</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-session-keys"><div class="inner"><span>session-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-set-target-header"><div class="inner"><span>set-target-header</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-sl-default-html"><div class="inner"><span>sl-default-html</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-slash-redir"><div class="inner"><span>slash-redir</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-soft-lock-passed"><div class="inner"><span>soft-lock-passed</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-soft-lock-remains"><div class="inner"><span>soft-lock-remains</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-soft-lock-time"><div class="inner"><span>soft-lock-time</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-soft-locked.3F"><div class="inner"><span>soft-locked?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-split-query-params"><div class="inner"><span>split-query-params</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-split-query-params-simple"><div class="inner"><span>split-query-params-simple</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-status-lv"><div class="inner"><span>status-lv</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-strictly-localized-page"><div class="inner"><span>strictly-localized-page</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-template-path"><div class="inner"><span>template-path</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-temporary-redirect"><div class="inner"><span>temporary-redirect</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-update-app-data"><div class="inner"><span>update-app-data</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-use-hx.3F"><div class="inner"><span>use-hx?</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-validators-keys"><div class="inner"><span>validators-keys</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-views-str"><div class="inner"><span>views-str</span></div></a></li><li class="depth-1"><a href="amelinium.web.html#var-with-role-only.21"><div class="inner"><span>with-role-only!</span></div></a></li></ul></div><div class="namespace-docs" id="content"><h1 class="anchor" id="top">amelinium.web</h1><h4 class="added">added in 1.0.0</h4><div class="doc"><div class="markdown"><p>Web helpers for amelinium.</p>
</div></div><div class="public anchor" id="var-add-app-data"><h3>add-app-data</h3><h4 class="type">macro</h4><div class="usage"><code>(add-app-data req & body)</code></div><div class="doc"><div class="markdown"><p>Adds a lazy map to a request map <code>req</code> under its key <code>:app/data</code> using <code>qassoc</code>. Overwrites previous value. The body is a result of evaluating expressions passed as additional arguments (<code>body</code>). Returns updated <code>req</code>. Assumes that <code>req</code> is always a map. Ensures that the resulting map is lazy. Ensures that the result is not <code>nil</code> (if it is, empty lazy map is returned).</p>
<p>Associating <code>:app/data</code> with <code>false</code> will prevent it from further processing.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L209">view source</a></div></div><div class="public anchor" id="var-add-header"><h3>add-header</h3><h4 class="type">macro</h4><div class="usage"><code>(add-header req header-name & body)</code></div><div class="doc"><div class="markdown"><p>Adds a header <code>header</code> to <code>:response/headers</code> map of the <code>req</code> using built-in function <code>qassoc</code>. If a header name argument is a literal keyword, a character, a number, or a literal string, it will be converted to a string literal and placed as <code>qassoc</code> argument. Otherwise it will be left as is and wrapped into a call to <code>io.randomseed.utils/some-str</code> to ensure the result is a string run-time. All arguments of the body are used to calculate a value of the header. Assumes that <code>req</code> is always a map.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2317">view source</a></div></div><div class="public anchor" id="var-add-headers"><h3>add-headers</h3><h4 class="type">macro</h4><div class="usage"><code>(add-headers req header-name header-value)</code><code>(add-headers req header-name header-value & more)</code></div><div class="doc"><div class="markdown"><p>Adds headers with associated values to <code>:response/headers</code> map of the <code>req</code> using built-in function <code>qassoc</code>. If any header name argument is a literal keyword, a character, a number, or a literal string, it will be converted to a string literal and placed as an argument passed to <code>qassoc</code>. Otherwise it will be left as is and wrapped in a call to <code>io.randomseed.utils/some-str</code> to ensure at run-time that the result will be a string. Missing header value, if any, will be padded with <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2339">view source</a></div></div><div class="public anchor" id="var-add-missing-sub-status"><h3>add-missing-sub-status</h3><div class="usage"><code>(add-missing-sub-status req sub-status sub-key)</code><code>(add-missing-sub-status data req sub-status sub-key)</code><code>(add-missing-sub-status data req sub-status lang sub-key title-key description-key)</code><code>(add-missing-sub-status req sub-status lang sub-key title-key description-key)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1020">view source</a></div></div><div class="public anchor" id="var-add-slash"><h3>add-slash</h3><div class="usage"><code>(add-slash uri)</code></div><div class="doc"><div class="markdown"><p>Adds trailing slash to a path unless it already exists.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1441">view source</a></div></div><div class="public anchor" id="var-add-status"><h3>add-status</h3><h4 class="type">macro</h4><div class="usage"><code>(add-status req & body)</code></div><div class="doc"><div class="markdown"><p>Adds response status to a request map <code>req</code> under its key <code>:response/status</code> using <code>qassoc</code>. The status is a result of evaluating expressions passed as additional arguments. Returns updated <code>req</code>. Assumes that <code>req</code> is always a map.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2524">view source</a></div></div><div class="public anchor" id="var-app-data"><h3>app-data</h3><div class="usage"><code>(app-data req)</code></div><div class="doc"><div class="markdown"><p>Gets the value of <code>:app/data</code> for the current request. If it does not exist or it is <code>nil</code>, returns an empty lazy map. Otherwise it returns the unmodified value. If it is a map but not a lazy map, converts it to a lazy map.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L176">view source</a></div></div><div class="public anchor" id="var-assoc-app-data"><h3>assoc-app-data</h3><h4 class="type">macro</h4><div class="usage"><code>(assoc-app-data req k v)</code><code>(assoc-app-data req k v & more)</code></div><div class="doc"><div class="markdown"><p>Adds keys with associated values to <code>:app/data</code> map of the <code>req</code> using <code>qassoc</code>. If any key argument is a literal keyword, a character, or a literal string, it will be converted to a keyword literal and placed as <code>qassoc</code> argument. Otherwise it will be left as is and wrapped into a call to <code>io.randomseed.utils/some-keyword</code> to ensure the result is a keyword run-time. Missing last value, if any, will be padded with <code>nil</code>. If there is no body or the body is empty, it will initialize it with a map expression, otherwise it will use <code>assoc</code>. Assumes that <code>req</code> is always a map. If the current value of <code>:app/data</code> is <code>false</code>, it will skip the processing.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L250">view source</a></div></div><div class="public anchor" id="var-auth-page"><h3>auth-page</h3><div class="usage"><code>(auth-page req)</code><code>(auth-page req lang-id)</code></div><div class="doc"><div class="markdown"><p>Returns a path for the authentication page. The page must have ID of <code>:user/welcome</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1002">view source</a></div></div><div class="public anchor" id="var-auth-page.3F"><h3>auth-page?</h3><div class="usage"><code>(auth-page? req)</code><code>(auth-page? req ring-match)</code></div><div class="doc"><div class="markdown"><p>Returns true if the current (or given as a match) page is an authentication page (has :auth-page? route data set to a truthy value).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L160">view source</a></div></div><div class="public anchor" id="var-common-auth-keys"><h3>common-auth-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L56">view source</a></div></div><div class="public anchor" id="var-common-keys"><h3>common-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L61">view source</a></div></div><div class="public anchor" id="var-current-page"><h3>current-page</h3><div class="usage"><code>(current-page req)</code></div><div class="doc"><div class="markdown"><p>Returns a path of the current page.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L981">view source</a></div></div><div class="public anchor" id="var-current-page-id"><h3>current-page-id</h3><div class="usage"><code>(current-page-id req-or-match)</code></div><div class="doc"><div class="markdown"><p>Returns an identifier of a current page if it is defined for a HTTP route.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L986">view source</a></div></div><div class="public anchor" id="var-current-page-id-or-path"><h3>current-page-id-or-path</h3><div class="usage"><code>(current-page-id-or-path req)</code></div><div class="doc"><div class="markdown"><p>Returns an identifier of a current page if it is defined for a HTTP route or a path if the page name is not defined.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L991">view source</a></div></div><div class="public anchor" id="var-def-render"><h3>def-render</h3><h4 class="type">macro</h4><div class="usage"><code>(def-render name f)</code><code>(def-render name f status)</code><code>(def-render name doc f)</code><code>(def-render name doc f status)</code></div><div class="doc"><div class="markdown"><p>Generates a web rendering function.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L802">view source</a></div></div><div class="public anchor" id="var-default-contexts-labeler"><h3>default-contexts-labeler</h3><div class="usage"><code>(default-contexts-labeler _ ids)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1792">view source</a></div></div><div class="public anchor" id="var-default-html"><h3>default-html</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L373">view source</a></div></div><div class="public anchor" id="var-dot-html"><h3>dot-html</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L372">view source</a></div></div><div class="public anchor" id="var-form-params-error.21"><h3>form-params-error!</h3><div class="usage"><code>(form-params-error! req errors)</code><code>(form-params-error! req errors session-key)</code></div><div class="doc"><div class="markdown"><p>Called to manually generate a redirect or display a page with a form to be corrected because of a parameter error. Takes a request map <code>req</code>, a map of erroneous parameter identifiers to parameter types <code>errors</code>, and optional session key <code>session-key</code> used when getting a session object from the <code>req</code>.</p>
<p>Parameter type in <code>errors</code> map can be <code>nil</code>, meaning it is of unknown type.</p>
<p>This function can work in two modes: HTMX and simple HTTP mode.</p>
<p>HTMX mode is in place when a client request contains the <code>HX-Request</code> header set to a non-falsy and not empty value, or it was enforced by using route data key <code>:form-errors/use-htmx?</code> set to a truthy value.</p>
<p>In HTMX mode the HTML result is rendered with layout and view obtained from the <code>:form-errors/page</code> configuration option associated with HTTP route data or the destination page established by checking the <code>Referer</code> header, unless <code>:form-errors/layout</code> and/or <code>:form-errors/view</code> options are set. Layout can be set to <code>false</code> to allow injection of HTML fragments. If form errors page is not specified one is obtained from the <code>Referer</code> request header. See <code>hx-handle-bad-request-form-params</code> for more info.</p>
<p>If simple HTTP mode is in place the <code>http-handle-bad-request-form-params</code> is used, and the following will happen:</p>
<p>If there is a session then the <code>errors</code> map is stored in a session variable <code>:form-errors</code> under the <code>:errors</code> key (additionally, there is a <code>:dest</code> key identifying a path of the current page), unless an HTMX response is to be generated by <code>handle-bad-request-form-params</code> which is called internally).</p>
<p>If there is no valid session or a session variable cannot be stored, the result is serialized as a query string parameter <code>form-errors</code> with erroneous fields separated by commas.</p>
<p>If type name is available for a parameter then a string in a form of <code>parameter:type</code> is generated.</p>
<p>If type name is not available, a simple parameter name is generated. So the example value (before encoding) may look like <code>email,secret:password</code> (<code>email</code> being a parameter without type information, <code>secret</code> being a parameter with type named <code>password</code>).</p>
<p>Next, the originating URI is obtained from the <code>Referer</code> header and a temporary redirect (with HTTP code 307) is generated with this path and a query string containing <code>form-errors</code> parameter. The value of the parameter is empty if form errors were saved in a session variable.</p>
<p>The destination of the redirect can be overriden by the <code>:form-errors/page</code> configuration option associated with HTTP route data.</p>
<p>If the destination URI cannot be established, or if a coercion error happened during handling some previous coercion error (so the current page is where the browser had been redirected to), then instead of generating a redirect, a regular page is rendered with HTTP code of 422. The <code>:app/data</code> key of a request map is updated with:</p>
<ul>
<li><code>:title</code> set to a translated message of <code>:parameters/error</code>,</li>
<li><code>:form/errors</code> containing a map:</li>
<li><code>:errors</code> mapped to <code>errors</code>,</li>
<li><code>:params</code> mapped to <code>values</code>,</li>
<li><code>:dest</code> mapped to destination URI;</li>
<li><code>:coercion/errors</code> set to <code>nil</code>.</li>
</ul>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1775">view source</a></div></div><div class="public anchor" id="var-get-for-status"><h3>get-for-status</h3><div class="usage"><code>(get-for-status req route-data k status)</code><code>(get-for-status req route-data k status other-status)</code></div><div class="doc"><div class="markdown"><p>If the given <code>status</code> is not <code>nil</code> and not <code>false</code>, it looks for <code>k</code> in <code>req</code>, and if that returns <code>nil</code> tries to look for <code>k</code> in <code>route-data</code>, and then, if its not <code>nil</code> gets a value associated with the given <code>status</code> in this map. If <code>other-status</code> is given, it will be used as fallback in the same way as the first, when it will return <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L529">view source</a></div></div><div class="public anchor" id="var-get-layout"><h3>get-layout</h3><div class="usage"><code>(get-layout req)</code><code>(get-layout req route-data)</code></div><div class="doc"><div class="markdown"><p>Gets layout partial path for the current route using :app/layout route data. If it cannot be extracted, returns default.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L341">view source</a></div></div><div class="public anchor" id="var-get-layout-dir"><h3>get-layout-dir</h3><div class="usage"><code>(get-layout-dir req layout-dir)</code><code>(get-layout-dir req layout-dir route-data)</code></div><div class="doc"><div class="markdown"><p>Gets layout optional subdirectory for the current route using :app/layout-dir route data. If it cannot be extracted, returns <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L362">view source</a></div></div><div class="public anchor" id="var-get-missing-app-data-from-req"><h3>get-missing-app-data-from-req</h3><div class="usage"><code>(get-missing-app-data-from-req data req keyz)</code></div><div class="doc"><div class="markdown"><p>Associates missing data identified with keys listed in <code>keyz</code> with values taken from the request map if the key exists. The resulting map is converted to a lazy map if it’s not.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L152">view source</a></div></div><div class="public anchor" id="var-get-target"><h3>get-target</h3><div class="usage"><code>(get-target req)</code></div><div class="doc"><div class="markdown"><p>Gets a target element ID set for the current route using <code>:app/target</code> route data. If it cannot be extracted, returns <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L295">view source</a></div></div><div class="public anchor" id="var-get-view"><h3>get-view</h3><div class="usage"><code>(get-view req)</code><code>(get-view req route-data)</code></div><div class="doc"><div class="markdown"><p>Gets a view partial path for the current route using <code>:app/view</code> route data or <code>:name</code>. If it cannot be extracted, returns default.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L327">view source</a></div></div><div class="public anchor" id="var-get-view-dir"><h3>get-view-dir</h3><div class="usage"><code>(get-view-dir req view-dir)</code><code>(get-view-dir req view-dir route-data)</code></div><div class="doc"><div class="markdown"><p>Gets view optional subdirectory for the current route using <code>:app/layout-dir</code> route data. If it cannot be extracted, returns <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L354">view source</a></div></div><div class="public anchor" id="var-go-to"><h3>go-to</h3><div class="usage"><code>(go-to req)</code><code>(go-to req url)</code><code>(go-to req name-or-path)</code><code>(go-to req name-or-path path-params)</code><code>(go-to req name-or-path path-params query-params)</code><code>(go-to req name-or-path lang)</code><code>(go-to req name-or-path lang path-params)</code><code>(go-to req name-or-path lang path-params query-params)</code><code>(go-to req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>When HTMX is detected with <code>use-hx?</code> calls <code>hx-go-to</code>, otherwise calls <code>http-go-to</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1419">view source</a></div></div><div class="public anchor" id="var-go-to-with-status"><h3>go-to-with-status</h3><div class="usage"><code>(go-to-with-status req)</code><code>(go-to-with-status req app-status)</code><code>(go-to-with-status req app-status default-page)</code><code>(go-to-with-status req route-data app-status default-page)</code><code>(go-to-with-status req route-data app-status default-page hx-status-flag)</code></div><div class="doc"><div class="markdown"><p>Uses <code>hx-go-to-with-status</code> when HTMX is in use (uses <code>common/use-hx?</code>), <code>http-go-to-with-status</code> otherwise. Takes additional <code>hx-status-flag</code> as a key to be checked in route data whether it is associated with a HTMX-enforcement flag.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1514">view source</a></div></div><div class="public anchor" id="var-guess-lang-param"><h3>guess-lang-param</h3><div class="usage"><code>(guess-lang-param)</code><code>(guess-lang-param src)</code></div><div class="doc"><div class="markdown"><p>For the given src argument, tries to obtain a language ID. If it’s a map it looks for <code>:param</code> key and for <code>:language/settings</code> if that fails. If <code>:language/settings</code> is found, it will try to get :param, assuming it’s a map too. If the argument is not a map it will simply convert it into a keyword (without a namespace). If all of that fails (e.g. the src is nil) then the :lang keyword is returned.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L139">view source</a></div></div><div class="public anchor" id="var-handle-bad-request-form-params"><h3>handle-bad-request-form-params</h3><div class="usage"><code>(handle-bad-request-form-params req)</code><code>(handle-bad-request-form-params req errors)</code><code>(handle-bad-request-form-params req errors values)</code><code>(handle-bad-request-form-params req errors values explanations)</code><code>(handle-bad-request-form-params req errors values explanations title)</code><code>(handle-bad-request-form-params req errors values explanations title session-key)</code></div><div class="doc"><div class="markdown"><p>Dispatch function which calls <code>hx-handle-bad-request-form-params</code> when HTMX is in use or <code>http-handle-bad-request-form-params</code> in other cases. HTMX mode will be in place when a client request contains <code>HX-Request</code> header set to a non-falsy and not empty value, or it was enforced by using route data key <code>:form-errors/use-htmx?</code> set to a truthy value.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1734">view source</a></div></div><div class="public anchor" id="var-handle-error"><h3>handle-error</h3><div class="usage"><code>(handle-error req)</code><code>(handle-error req app-status)</code><code>(handle-error req app-status default-view)</code><code>(handle-error req route-data app-status default-view)</code><code>(handle-error req route-data app-status default-view header-name)</code></div><div class="doc"><div class="markdown"><p>Sets proper HTMX response (when <code>common/use-hx?</code> returns <code>true</code> because the request indicated it is HTMX or <code>:error/use-htmx?</code> route data key is set or generic <code>:use-htmx?</code> route data key is set), or a HTTP redirect response, as a result of error encountered. Additionally, sets an HTTP response header named <code>header-name</code> (if set) with error status detected (mainly to be used by reverse proxies). If header name is <code>false</code>, no header is set. If header name is not set or is set to <code>nil</code>, the name <code>Error</code> is used. Returns updated <code>req</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1537">view source</a></div></div><div class="public anchor" id="var-hard-lock-time"><h3>hard-lock-time</h3><div class="usage"><code>(hard-lock-time user)</code></div><div class="doc"><div class="markdown"><p>Gets a hard-lock time for a given user specified by a map having the :locked key.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1469">view source</a></div></div><div class="public anchor" id="var-hard-locked.3F"><h3>hard-locked?</h3><div class="usage"><code>(hard-locked? user)</code></div><div class="doc"><div class="markdown"><p>Returns true if the given user map contains the :locked key and a value associated with it is not nil. Does not connect to a database.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1497">view source</a></div></div><div class="public anchor" id="var-has-any-role.3F"><h3>has-any-role?</h3><div class="usage"><code>(has-any-role? req role)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1743">view source</a></div></div><div class="public anchor" id="var-has-param.3F"><h3>has-param?</h3><div class="usage"><code>(has-param? match param)</code></div><div class="doc"><div class="markdown"><p>Checks if the given route match can be parameterized with a parameter of the given id.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L340">view source</a></div></div><div class="public anchor" id="var-has-role.3F"><h3>has-role?</h3><div class="usage"><code>(has-role? req role)</code><code>(has-role? req role context)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1749">view source</a></div></div><div class="public anchor" id="var-http-go-to"><h3>http-go-to</h3><div class="usage"><code>(http-go-to)</code><code>(http-go-to req)</code><code>(http-go-to url)</code><code>(http-go-to req url)</code><code>(http-go-to req name-or-path)</code><code>(http-go-to req name-or-path path-params)</code><code>(http-go-to req name-or-path path-params query-params)</code><code>(http-go-to req name-or-path lang)</code><code>(http-go-to req name-or-path lang path-params)</code><code>(http-go-to req name-or-path lang path-params query-params)</code><code>(http-go-to req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Uses the <code>localized-page</code> function to calculate the destination path on a basis of page name (identifier) or a path (a string) and performs a redirect with code 303 to it using <code>resp/see-other</code>. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
<p>The difference between this function and its regular counterpart (if defined) is in binary variants of them (when a request map and a name or a path are given as arguments). The regular function will fail to generate a redirect if there is no language parameter and the given path does not point to an existing page. On the contrary, this function will generate a localized path using a language obtained from a request (under <code>:language/str</code> key) and if there will be no language-parameterized variant of the path, it will fail. Use this function to make sure that a localized path will be produced, or <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1269">view source</a></div></div><div class="public anchor" id="var-http-go-to-with-status"><h3>http-go-to-with-status</h3><div class="usage"><code>(http-go-to-with-status req)</code><code>(http-go-to-with-status req app-status)</code><code>(http-go-to-with-status req app-status default-page)</code><code>(http-go-to-with-status req route-data app-status default-page)</code></div><div class="doc"><div class="markdown"><p>Uses <code>http-go-to</code> to make a redirect on a basis of the given application status <code>app-status</code> by looking it up in <code>:error/destinations</code> of a route data map with fallback to a value associated with the <code>:error/destination</code> key or to a value of the <code>default-page</code> argument (if set).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1469">view source</a></div></div><div class="public anchor" id="var-http-handle-bad-request-form-params"><h3>http-handle-bad-request-form-params</h3><div class="usage"><code>(http-handle-bad-request-form-params req route-data errors values explanations title session-key)</code></div><div class="doc"><div class="markdown"><p>Called by other functions to generate a redirect or to display a page with a form to be corrected because of a parameter error (induced manually or caused by coercion exception).</p>
<p>Takes a request map <code>req</code>, a map of erroneous parameter identifiers to parameter types <code>errors</code>, a map of current parameter values <code>values</code>, a map of error explanations (<code>explanations</code>), page title (<code>title</code>), and optional session key <code>session-key</code> used when getting a session object from the <code>req</code>.</p>
<p>The following arguments can be Delay objects and <code>clojure.core/force</code> will be applied to them before use: <code>errors</code>, <code>values</code>, <code>explanations</code>, <code>title</code>.</p>
<p>Parameter type in <code>errors</code> map can be <code>nil</code>, meaning it is of unknown type.</p>
<p>If there is a session then the <code>errors</code> map is stored in a session variable <code>:form-errors</code> under the <code>:errors</code> key (additionally, there is a <code>:dest</code> key identifying a path of the current page).</p>
<p>If there is no valid session or a session variable cannot be stored, the result is serialized as a query string parameter <code>form-errors</code> with erroneous fields separated by commas.</p>
<p>If type name is available for a parameter then a string in a form of <code>parameter:type</code> is generated.</p>
<p>If type name is not available, a simple parameter name is generated. So the example value (before encoding) may look like <code>email,secret:password</code> (<code>email</code> being a parameter without type information, <code>secret</code> being a parameter with type named <code>password</code>).</p>
<p>Next, the originating URI is obtained from the <code>Referer</code> header and a temporary redirect (with HTTP code 307) is generated with this path and a query string containing <code>form-errors</code> parameter. The value of the parameter is empty if form errors were saved in a session variable.</p>
<p>The destination of the redirect can be overriden by the <code>:form-errors/page</code> configuration option associated with HTTP route data.</p>
<p>If the destination URI cannot be established, or if a coercion error happened during handling some previous coercion error (so the current page is where the browser had been redirected to), then instead of generating a redirect, a regular page is rendered with HTTP code of 422. The <code>:app/data</code> key of a request map is updated with:</p>
<ul>
<li><code>:title</code> set to <code>title</code>,</li>
<li><code>:form/errors</code> set to a map containing:</li>
<li><code>:errors</code> mapped to <code>errors</code>,</li>
<li><code>:params</code> mapped to <code>values</code>,</li>
<li><code>:dest</code> mapped to destination URI;</li>
<li><code>:coercion/errors</code> set to <code>explanations</code> map.</li>
</ul>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1569">view source</a></div></div><div class="public anchor" id="var-http-move-to"><h3>http-move-to</h3><div class="usage"><code>(http-move-to)</code><code>(http-move-to req)</code><code>(http-move-to url)</code><code>(http-move-to req url)</code><code>(http-move-to req name-or-path)</code><code>(http-move-to req name-or-path path-params)</code><code>(http-move-to req name-or-path path-params query-params)</code><code>(http-move-to req name-or-path lang)</code><code>(http-move-to req name-or-path lang path-params)</code><code>(http-move-to req name-or-path lang path-params query-params)</code><code>(http-move-to req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Uses the <code>localized-page</code> function to calculate the destination path on a basis of page name (identifier) or a path (a string) and performs a redirect with code 307 to it using <code>resp/temporary-redirect</code>. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
<p>The difference between this function and its regular counterpart (if defined) is in binary variants of them (when a request map and a name or a path are given as arguments). The regular function will fail to generate a redirect if there is no language parameter and the given path does not point to an existing page. On the contrary, this function will generate a localized path using a language obtained from a request (under <code>:language/str</code> key) and if there will be no language-parameterized variant of the path, it will fail. Use this function to make sure that a localized path will be produced, or <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1311">view source</a></div></div><div class="public anchor" id="var-hx-go-to"><h3>hx-go-to</h3><div class="usage"><code>(hx-go-to)</code><code>(hx-go-to req)</code><code>(hx-go-to url)</code><code>(hx-go-to req url)</code><code>(hx-go-to req name-or-path)</code><code>(hx-go-to req name-or-path path-params)</code><code>(hx-go-to req name-or-path path-params query-params)</code><code>(hx-go-to req name-or-path lang)</code><code>(hx-go-to req name-or-path lang path-params)</code><code>(hx-go-to req name-or-path lang path-params query-params)</code><code>(hx-go-to req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Same as <code>http-go-to</code> but uses <code>hx-transform-redirect</code> internally to generate HTMX redirect.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1353">view source</a></div></div><div class="public anchor" id="var-hx-go-to-with-status"><h3>hx-go-to-with-status</h3><div class="usage"><code>(hx-go-to-with-status req)</code><code>(hx-go-to-with-status req app-status)</code><code>(hx-go-to-with-status req app-status default-view)</code><code>(hx-go-to-with-status req route-data app-status default-view)</code></div><div class="doc"><div class="markdown"><p>Uses <code>hx-inject</code> to set a target (<code>HX-Retarget</code> header) on a basis of the given application status <code>app-status</code> by looking it up in <code>:status/targets</code> of a route data map with a fallback to <code>:error/target</code>.</p>
<p>Additionally it sets a fallback view to the given <code>default-view</code> (if set) and a flag <code>:response/set-status!</code> in <code>req</code> to ensure that application status is processed even if an HTTP response status will be <code>:ok/found</code> during rendering.</p>
<p>Returns <code>req</code> with added <code>:response/status</code> set to the value of <code>app-status</code>, updated <code>:response/headers</code> and <code>:response/set-status!</code> flag.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1486">view source</a></div></div><div class="public anchor" id="var-hx-handle-bad-request-form-params"><h3>hx-handle-bad-request-form-params</h3><div class="usage"><code>(hx-handle-bad-request-form-params req route-data errors)</code><code>(hx-handle-bad-request-form-params req route-data errors values)</code><code>(hx-handle-bad-request-form-params req route-data errors values explanations)</code><code>(hx-handle-bad-request-form-params req route-data errors values explanations title _)</code><code>(hx-handle-bad-request-form-params req route-data errors values explanations title)</code></div><div class="doc"><div class="markdown"><p>Called by other functions to render form with feedback about submitted parameter errors (induced manually or caused by coercion exception). On fronted, uses HTMX and JavaScript Fetch API calls to load HTML.</p>
<p>Takes a request map <code>req</code>, a map of erroneous parameter identifiers to parameter types <code>errors</code>, a map of current parameter values <code>values</code>, a map of error explanations (<code>explanations</code>), and a page title (<code>title</code>).</p>
<p>The following arguments can be Delay objects and <code>clojure.core/force</code> will be applied to them before use: <code>errors</code>, <code>values</code>, <code>explanations</code>, <code>title</code>.</p>
<p>Parameter type in <code>errors</code> map can be <code>nil</code>, meaning it is of unknown type.</p>
<p>The layout and view are obtained from the <code>:form-errors/page</code> configuration option associated with HTTP route data or the destination page established by checking <code>Referer</code> header, unless <code>:form-errors/layout</code> and/or <code>:form-errors/view</code> options are set. Layout can be set to <code>false</code> to allow injection of HTML fragments.</p>
<p>If form errors page is not specified one is obtained from the <code>Referer</code> request header.</p>
<p>Sets <code>HX-Retarget</code> response header to a value set in route data option <code>:form-errors/target</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1669">view source</a></div></div><div class="public anchor" id="var-hx-inject"><h3>hx-inject</h3><div class="usage"><code>(hx-inject req)</code><code>(hx-inject req target)</code><code>(hx-inject req target view)</code></div><div class="doc"><div class="markdown"><p>Injects HTML fragment by issuing HTMX response with <code>HX-Retarget</code> header set to <code>target</code> (if given and its value is not <code>false</code> and not <code>nil</code>), <code>:app/layout</code> key of the <code>req</code> set to <code>false</code> and <code>:app/view</code> key of the <code>req</code> set to <code>view</code> (if given and not <code>nil</code>). Returns updated request map <code>req</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1161">view source</a></div></div><div class="public anchor" id="var-hx-localized-redirect"><h3>hx-localized-redirect</h3><div class="usage"><code>(hx-localized-redirect f)</code><code>(hx-localized-redirect f req)</code><code>(hx-localized-redirect f url)</code><code>(hx-localized-redirect f req url)</code><code>(hx-localized-redirect f req name-or-path)</code><code>(hx-localized-redirect f req name-or-path path-params)</code><code>(hx-localized-redirect f req name-or-path path-params query-params)</code><code>(hx-localized-redirect f req name-or-path lang)</code><code>(hx-localized-redirect f req name-or-path lang path-params)</code><code>(hx-localized-redirect f req name-or-path lang path-params query-params)</code><code>(hx-localized-redirect f req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>HTMX redirect wrapper. Uses <code>HX-Redirect</code> header to trigger redirect and resets the status code to 200. The <code>f</code> should be a function which takes a request map and returns a response; should take at least one single argument which should be a URL. The URL will be parameterized with a language. Works almost the same way as the <code>redirect</code> but it will generate a localized path using a language obtained from a request (under <code>:language/str</code> key) and if there will be no language-parameterized variant of the path, it will fail. Use this function to make sure that localized path will be produced, or <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1200">view source</a></div></div><div class="public anchor" id="var-hx-move-to"><h3>hx-move-to</h3><div class="usage"><code>(hx-move-to)</code><code>(hx-move-to req)</code><code>(hx-move-to url)</code><code>(hx-move-to req url)</code><code>(hx-move-to req name-or-path)</code><code>(hx-move-to req name-or-path path-params)</code><code>(hx-move-to req name-or-path path-params query-params)</code><code>(hx-move-to req name-or-path lang)</code><code>(hx-move-to req name-or-path lang path-params)</code><code>(hx-move-to req name-or-path lang path-params query-params)</code><code>(hx-move-to req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Same as <code>http-move-to</code> but uses <code>hx-transform-redirect</code> internally to generate HTMX redirect.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1382">view source</a></div></div><div class="public anchor" id="var-hx-redirect"><h3>hx-redirect</h3><div class="usage"><code>(hx-redirect f)</code><code>(hx-redirect f req)</code><code>(hx-redirect f url)</code><code>(hx-redirect f req url)</code><code>(hx-redirect f req name-or-path)</code><code>(hx-redirect f req name-or-path path-params)</code><code>(hx-redirect f req name-or-path path-params query-params)</code><code>(hx-redirect f req name-or-path lang)</code><code>(hx-redirect f req name-or-path lang path-params)</code><code>(hx-redirect f req name-or-path lang path-params query-params)</code><code>(hx-redirect f req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Generic HTMX redirect wrapper. Uses <code>HX-Redirect</code> header to trigger redirect and resets the status code to 200. The <code>f</code> should be a function which takes a request map and returns a response; should take at least one single argument which should be a URL. The URL will be parameterized with a language if required. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1235">view source</a></div></div><div class="public anchor" id="var-hx-request.3F"><h3>hx-request?</h3><div class="usage"><code>(hx-request? req)</code></div><div class="doc"><div class="markdown"><p>Returns <code>true</code> if the client request has <code>HX-Request</code> header set to any value but <code>false</code> or an empty string.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1126">view source</a></div></div><div class="public anchor" id="var-hx-target"><h3>hx-target</h3><div class="usage"><code>(hx-target req)</code></div><div class="doc"><div class="markdown"><p>Returns a string from <code>HX-Target</code> header set by a client. If the header does not exist, it returns <code>nil</code>. If the header exists but contains an empty string, it returns <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1161">view source</a></div></div><div class="public anchor" id="var-hx-transform-redirect"><h3>hx-transform-redirect</h3><div class="usage"><code>(hx-transform-redirect resp)</code></div><div class="doc"><div class="markdown"><p>Adds the <code>HX-Redirect</code> response header set to a value of existing <code>Location</code> header and removes the last one from the response map <code>resp</code>. Additionally forces HTTP status of the response to be 200.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1188">view source</a></div></div><div class="public anchor" id="var-i18n-keys"><h3>i18n-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L53">view source</a></div></div><div class="public anchor" id="var-lang-config"><h3>lang-config</h3><div class="usage"><code>(lang-config req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2240">view source</a></div></div><div class="public anchor" id="var-lang-from-req"><h3>lang-from-req</h3><div class="usage"><code>(lang-from-req req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L781">view source</a></div></div><div class="public anchor" id="var-lang-id"><h3>lang-id</h3><div class="usage"><code>(lang-id req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2218">view source</a></div></div><div class="public anchor" id="var-lang-param"><h3>lang-param</h3><div class="usage"><code>(lang-param req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2214">view source</a></div></div><div class="public anchor" id="var-lang-redir"><h3>lang-redir</h3><div class="usage"><code>(lang-redir req)</code></div><div class="doc"><div class="markdown"><p>Redirects to a best-suited language version of the URI. Uses <code>:browser</code> pickers chain to get the right language if the path is language-parameterized.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1457">view source</a></div></div><div class="public anchor" id="var-lang-str"><h3>lang-str</h3><div class="usage"><code>(lang-str req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2227">view source</a></div></div><div class="public anchor" id="var-language-keys"><h3>language-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L52">view source</a></div></div><div class="public anchor" id="var-layouts-str"><h3>layouts-str</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L371">view source</a></div></div><div class="public anchor" id="var-localized-page"><h3>localized-page</h3><div class="usage"><code>(localized-page req)</code><code>(localized-page req name-or-path)</code><code>(localized-page req name-or-path path-params)</code><code>(localized-page req name-or-path path-params query-params)</code><code>(localized-page req name-or-path lang)</code><code>(localized-page req name-or-path lang path-params)</code><code>(localized-page req name-or-path lang path-params query-params)</code><code>(localized-page req name-or-path lang lang-required?)</code><code>(localized-page req name-or-path lang path-params lang-required?)</code><code>(localized-page req name-or-path lang path-params query-params lang-required?)</code><code>(localized-page req name-or-path lang path-params query-params lang-required? name-path-fallback?)</code><code>(localized-page req name-or-path lang path-params query-params lang-required? name-path-fallback? router)</code><code>(localized-page _ name-or-path lang path-params query-params lang-required? name-path-fallback? router language-settings-or-param)</code></div><div class="doc"><div class="markdown"><p>Generates a page path for the given page identifier and language identifier. When called with just a request map, returns a path of the current page but re-generated to support current language in use (taken from <code>:language/str</code> key of the request map).</p>
<p>The optional <code>name-path-fallback?</code> argument, when set to a truthy value (<code>true</code> by default), causes non-matching route identifier to be retried by extracting its path and calling this function for that path given as a string.</p>
<p>The optional <code>lang-required?</code> argument (set to <code>false</code> when not given) enables extra check eliminating pages which do not support the given language parameter. Example:</p>
<p><code>(localized-page req :login-page :pl true)</code></p>
<p>will fail if there is no parameter <code>:lang</code> handled by the route named <code>:login-page</code>.</p>
<p>When the given path is already parameterized with language then re-parameterized path is generated and checked if it exists, unless the value of the parameter is the same as the existing one. In such case the path is returned after a quick existence check.</p>
<p>Additional path parameters (<code>path-params</code>) can be given to be used when matching by name. Giving extra (unknown to route) parameters does not affect lookup. Giving <code>path-params</code> when matching by path causes them to be silently ignored.</p>
<p>Additional query parameters (<code>query-params</code>) can be given. They will be used when generating path. If the path was given and it already contains query parameters, they will be replaced.</p>
<p>If the path is given instead of a route identifier, it must exist (after being equipped with any extra parameters, if needed, using <code>path-params</code>).</p>
<p>When the <code>lang-required?</code> is set to <code>false</code> (default) and a path is given but it does not require language parameter, a path will be generated by testing whether it exists for regular and for slash-stripped or slash-added variant (the original variant goes first).</p>
<p>When the <code>lang-required?</code> is set to <code>false</code> (default) and a path is given but it does not require language parameter plus the <code>name-path-fallback?</code> argument is set to <code>:brute-force</code>, all possible path variants (with language parameter injected within its succesive segments) will be tried in hope that one will exist, regardless of parameter name that matches. Use it with caution as it may give weird matches; if for example, there is a route path <code>/users/:id</code> defined, and the given path is <code>/users/</code> with language set to <code>:pl</code>, then it will match <code>/users/pl</code> even though the parameter is not related to a language.</p>
<p>When the <code>lang-required?</code> is set to <code>true</code> and a path is given but it does not require a language parameter, all possible path variants (with parameter injected within its succesive segments) will be tried in hope that one will match, being a path that requires language parameter.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L573">view source</a></div></div><div class="public anchor" id="var-localized-path"><h3>localized-path</h3><div class="usage"><code>(localized-path)</code><code>(localized-path req)</code><code>(localized-path req name-or-path)</code><code>(localized-path req name-or-path lang)</code><code>(localized-path req name-or-path lang params)</code><code>(localized-path req name-or-path lang params query-params)</code><code>(localized-path name-or-path lang params query-params router language-settings-or-param)</code></div><div class="doc"><div class="markdown"><p>Creates a URL on a basis of route name or a path.</p>
<p>Uses very optimistic matching algorithm. Tries to obtain language from user settings and client settings if the path does not contain language information. Uses the <code>:default</code> language picker.</p>
<p>Non-matching route identifier is retried by extracting its path and calling the <code>localized-page</code> function for that path given as a string.</p>
<p>If a page found does not have a language parameter it is accepted too.</p>
<p>When the given path is already parameterized with language then re-parameterized path is generated and checked if it exists, unless the value of the parameter is the same as the existing one. In such case the path is returned after a quick existence check.</p>
<p>Additional path parameters (<code>params</code>) can be given to be used when matching by name. Giving extra (unknown to route) parameters does not affect lookup. Giving <code>params</code> when matching by path causes them to be silently ignored.</p>
<p>Additional query parameters (<code>query-params</code>) can be given. They will be used when generating path. If the path was given and it already contains query parameters, they will be replaced.</p>
<p>If the path is given instead of a route identifier, it must exist (after being equipped with any extra parameters, if needed, using <code>params</code>).</p>
<p>When a path is given but it does not require language parameter, a path will be generated by testing whether it exists for regular and for slash-stripped or slash-added variant (the original variant goes first).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1933">view source</a></div></div><div class="public anchor" id="var-localized-render-created"><h3>localized-render-created</h3><div class="usage"><code>(localized-render-created)</code><code>(localized-render-created req)</code><code>(localized-render-created req data)</code><code>(localized-render-created req data view)</code><code>(localized-render-created req data view layout)</code><code>(localized-render-created req data view layout lang)</code><code>(localized-render-created req data view layout lang name-or-path)</code><code>(localized-render-created req data view layout lang name-or-path params)</code><code>(localized-render-created req data view layout lang name-or-path params query-params)</code></div><div class="doc"><div class="markdown"><p>Renders 201 response with a redirect (possibly localized if a destination path is language-parameterized) and a possible body. Requires the destination URL (specified by arguments or by the <code>:response/location</code> key of the given <code>req</code>) to be language parameterized. See <code>render</code> documentation to know more about body rendering.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L953">view source</a></div></div><div class="public anchor" id="var-localized-see-other"><h3>localized-see-other</h3><div class="usage"><code>(localized-see-other)</code><code>(localized-see-other req)</code><code>(localized-see-other url)</code><code>(localized-see-other req url)</code><code>(localized-see-other req name-or-path)</code><code>(localized-see-other req name-or-path path-params)</code><code>(localized-see-other req name-or-path path-params query-params)</code><code>(localized-see-other req name-or-path lang)</code><code>(localized-see-other req name-or-path lang path-params)</code><code>(localized-see-other req name-or-path lang path-params query-params)</code><code>(localized-see-other req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Uses the <code>localized-page</code> function to calculate the destination path on a basis of page name (identifier) or a path (a string) and performs a redirect with code 303 to it using <code>resp/see-other</code>. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
<p>The difference between this function and its regular counterpart (if defined) is in binary variants of them (when a request map and a name or a path are given as arguments). The regular function will fail to generate a redirect if there is no language parameter and the given path does not point to an existing page. On the contrary, this function will generate a localized path using a language obtained from a request (under <code>:language/str</code> key) and if there will be no language-parameterized variant of the path, it will fail. Use this function to make sure that a localized path will be produced, or <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1370">view source</a></div></div><div class="public anchor" id="var-localized-temporary-redirect"><h3>localized-temporary-redirect</h3><div class="usage"><code>(localized-temporary-redirect)</code><code>(localized-temporary-redirect req)</code><code>(localized-temporary-redirect url)</code><code>(localized-temporary-redirect req url)</code><code>(localized-temporary-redirect req name-or-path)</code><code>(localized-temporary-redirect req name-or-path path-params)</code><code>(localized-temporary-redirect req name-or-path path-params query-params)</code><code>(localized-temporary-redirect req name-or-path lang)</code><code>(localized-temporary-redirect req name-or-path lang path-params)</code><code>(localized-temporary-redirect req name-or-path lang path-params query-params)</code><code>(localized-temporary-redirect req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Uses the <code>localized-page</code> function to calculate the destination path on a basis of page name (identifier) or a path (a string) and performs a redirect with code 307 to it using <code>resp/temporary-redirect</code>. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
<p>The difference between this function and its regular counterpart (if defined) is in binary variants of them (when a request map and a name or a path are given as arguments). The regular function will fail to generate a redirect if there is no language parameter and the given path does not point to an existing page. On the contrary, this function will generate a localized path using a language obtained from a request (under <code>:language/str</code> key) and if there will be no language-parameterized variant of the path, it will fail. Use this function to make sure that a localized path will be produced, or <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1373">view source</a></div></div><div class="public anchor" id="var-lock-wait"><h3>lock-wait</h3><div class="usage"><code>(lock-wait auth-config-or-lock-wait)</code></div><div class="doc"><div class="markdown"><p>Returns lock-wait configuration option taken from the authentication configuration map or given as a time duration. Does not connect to a database.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1488">view source</a></div></div><div class="public anchor" id="var-lock-wait-default"><h3>lock-wait-default</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1467">view source</a></div></div><div class="public anchor" id="var-login-auth-state"><h3>login-auth-state</h3><div class="usage"><code>(login-auth-state req)</code><code>(login-auth-state req ring-match)</code><code>(login-auth-state req login-page-data auth-page-data)</code><code>(login-auth-state req ring-match login-page-data auth-page-data)</code></div><div class="doc"><div class="markdown"><p>Helper which returns 2-element vector telling if the current (or given as a match) page is a login page (1st element) and/or an auth page (2nd element).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L166">view source</a></div></div><div class="public anchor" id="var-login-page"><h3>login-page</h3><div class="usage"><code>(login-page req)</code><code>(login-page req lang-id)</code></div><div class="doc"><div class="markdown"><p>Returns a path for the login page. The page must have ID of <code>:user/login</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L997">view source</a></div></div><div class="public anchor" id="var-login-page.3F"><h3>login-page?</h3><div class="usage"><code>(login-page? req)</code><code>(login-page? req ring-match)</code></div><div class="doc"><div class="markdown"><p>Returns true if the current (or given as a match) page is a login page (has <code>:login-page?</code> route data set to a truthy value).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L154">view source</a></div></div><div class="public anchor" id="var-map-to-lazy"><h3>map-to-lazy</h3><div class="usage"><code>(map-to-lazy m)</code></div><div class="doc"><div class="markdown"><p>Ensures that the given argument <code>m</code> is a lazy map. If it is not a map, it is returned as is. If it is <code>nil</code>, empty lazy map is returned.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L134">view source</a></div></div><div class="public anchor" id="var-move-to"><h3>move-to</h3><div class="usage"><code>(move-to req)</code><code>(move-to req url)</code><code>(move-to req name-or-path)</code><code>(move-to req name-or-path path-params)</code><code>(move-to req name-or-path path-params query-params)</code><code>(move-to req name-or-path lang)</code><code>(move-to req name-or-path lang path-params)</code><code>(move-to req name-or-path lang path-params query-params)</code><code>(move-to req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>When HTMX is detected with <code>use-hx?</code> calls <code>hx-move-to</code>, otherwise calls <code>http-move-to</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1444">view source</a></div></div><div class="public anchor" id="var-no-app-data"><h3>no-app-data</h3><div class="usage"><code>(no-app-data req)</code></div><div class="doc"><div class="markdown"><p>Disables processing of the <code>:app/data</code> key for the given request <code>req</code> by associating it with the <code>false</code> value.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L165">view source</a></div></div><div class="public anchor" id="var-no-app-data.3F"><h3>no-app-data?</h3><div class="usage"><code>(no-app-data? req)</code></div><div class="doc"><div class="markdown"><p>Returns <code>true</code> when the value associated with <code>:app/data</code> in <code>req</code> is <code>false</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L171">view source</a></div></div><div class="public anchor" id="var-on-page.3F"><h3>on-page?</h3><div class="usage"><code>(on-page?)</code><code>(on-page? req)</code><code>(on-page? req page-id-or-path)</code><code>(on-page? req page-id-or-path & more)</code></div><div class="doc"><div class="markdown"><p>Checks if a current page matches the given route name (if an identifier is given) or the exact path. For multiple page names or paths, it returns true when any of them matches.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L106">view source</a></div></div><div class="public anchor" id="var-page"><h3>page</h3><div class="usage"><code>(page req)</code><code>(page req name-or-path)</code><code>(page req name-or-path path-params)</code><code>(page req name-or-path path-params query-params)</code><code>(page req name-or-path lang)</code><code>(page req name-or-path lang path-params)</code><code>(page req name-or-path lang path-params query-params)</code><code>(page req name-or-path lang lang-required?)</code><code>(page req name-or-path lang path-params lang-required?)</code><code>(page req name-or-path lang path-params query-params lang-required?)</code><code>(page req name-or-path lang path-params query-params lang-required? name-path-fallback?)</code><code>(page _ _ name-or-path path-params query-params router hint-lang lang-settings-or-param)</code><code>(page _ name-or-path lang path-params query-params lang-required? name-path-fallback? router lang-settings-or-param)</code></div><div class="doc"><div class="markdown"><p>Generates a page path for the given page identifier (a route name) or a path, and optional language identifier. When called with just a request map, returns a path of the current page.</p>
<p>It tries to be optimistic. When called for a page identified by its name (expressed as an identifier, usually a keyword) and with a language parameter to be found (so it cannot be looked up using just a name alone), it will use currently detected language obtained from the given request map (key <code>:language/str</code>), and will use it.</p>
<p>Additional query parameters (<code>query-params</code>) can be given. They will be used when generating path with <code>localized-page</code>. If the path was given and it already contains query parameters, they will be replaced.</p>
<p>Additional path parameters (<code>path-params</code>) may be given. Giving extra (unknown to route) parameters does not affect lookup. Giving <code>path-params</code> when matching by path causes them to be silently ignored.</p>
<p>When invoked with a language parameter, calls <code>localized-page</code> internally.</p>
<p>When invoked with a language parameter, the <code>lang-required?</code> argument may be used (by default set to <code>false</code>) to check if a matching route is parameterized with a language parameter. This is to ensure that only a localized route is used.</p>
<p>When invoked with a language parameter, the optional <code>name-path-fallback?</code> argument may be used (set to <code>true</code> by default) to cause non-matching route identifier to be retried by extracting its path and calling <code>localized-page</code> function for that path expressed as a string.</p>
<p>If the path is given instead of a route identifier, it must exist (after being equipped with any extra parameters, if needed, using <code>path-params</code>).</p>
<p>When invoked with a language parameter, the <code>lang-required?</code> is set to <code>false</code> (default), and a path is given but it does not require language parameter, a path will be generated by testing whether it exists for regular and for slash-stripped or slash-added variant (the original variant goes first).</p>
<p>When invoked with a language parameter, the <code>lang-required?</code> is set to <code>false</code> (default), and a path is given but it does not require language parameter plus the <code>name-path-fallback?</code> argument is set to <code>:brute-force</code>, all possible path variants (with language parameter injected within its succesive segments) will be tried in hope that one will exist, regardless of parameter name that matches. Use it with caution as it may give weird matches; if for example, there is a route path <code>/users/:id</code> defined, and the given path is <code>/users/</code> with language set to <code>:pl</code>, then it will match <code>/users/pl</code> even though the parameter is not related to a language.</p>
<p>When invoked with a language parameter, the <code>lang-required?</code> is set to <code>true</code>, and a path is given but it does not require a language parameter, all possible path variants (with language parameter injected within its succesive segments) will be tried in hope that one will match, being a path that requires language parameter.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L787">view source</a></div></div><div class="public anchor" id="var-page-keys"><h3>page-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L47">view source</a></div></div><div class="public anchor" id="var-param-keys"><h3>param-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L48">view source</a></div></div><div class="public anchor" id="var-parameterized-page"><h3>parameterized-page</h3><div class="usage"><code>(parameterized-page)</code><code>(parameterized-page req)</code><code>(parameterized-page req name-or-path)</code><code>(parameterized-page req name-or-path param param-value)</code><code>(parameterized-page req name-or-path param param-value path-params)</code><code>(parameterized-page req name-or-path param param-value path-params query-params)</code><code>(parameterized-page req name-or-path param param-value require-param?)</code><code>(parameterized-page req name-or-path param param-value path-params require-param?)</code><code>(parameterized-page req name-or-path param param-value path-params query-params require-param?)</code><code>(parameterized-page req name-or-path param param-value path-params query-params require-param? name-path-fallback?)</code><code>(parameterized-page _ name-or-path param param-value path-params query-params require-param? name-path-fallback? router)</code></div><div class="doc"><div class="markdown"><p>Generates a path for the given page identifier (which may be a name expressed with an identifier, preferably a keyword, or a path expressed as a string) and a parameter with the given value.</p>
<p>Optional path parameters may be given. They will be used to match a page by name if it requires additional parameters to be present.</p>
<p>Examples:</p>
<p><code>(parameterized-page req)</code> <code>(parameterized-page req :login-page)</code> <code>(parameterized-page req :login-page :lang :pl)</code> <code>(parameterized-page req :login-page :lang :pl {:client "wow-corp"})</code> <code>(parameterized-page req "/login/page/")</code> <code>(parameterized-page req "/login/page/" :lang :pl)</code> <code>(parameterized-page req "/en/login/page/" :lang :pl)</code></p>
<p>When called with just a request map, returns a path of the current page if the page exists. When called with a page name or path, it returns a path if the page exists.</p>
<p>The optional <code>name-path-fallback?</code> argument, when set to a truthy value (default is <code>false</code>), causes non-matching route identifier to be retried by extracting its path and calling this function for that path given as a string.</p>
<p>The optional <code>require-param?</code> argument (set to <code>false</code> when not given) enables extra check eliminating pages which do not support the given parameter, yet would be matched. Example:</p>
<p><code>(parameterized-page req :login-page :lang :pl true)</code></p>
<p>will fail if there is no parameter <code>:lang</code> handled by the route named <code>:login-page</code>.</p>
<p>When the given path is already parameterized then re-parameterized path is generated and checked if it exists, unless the value of the parameter is the same as the existing one. In such case the path is returned after a quick existence check.</p>
<p>Additional path parameters (<code>path-params</code>) can be given to be used when matching by name. Giving extra (unknown to route) parameters does not affect lookup. Giving <code>path-params</code> when matching by path causes them to be silently ignored.</p>
<p>Additional query parameters (<code>query-params</code>) can be given. They will be used when generating path. If the path was given and it already contains query parameters, they will be replaced.</p>
<p>If the path is given instead of a route identifier, it must exist (after being equipped with any extra parameters, if needed, using <code>path-params</code>).</p>
<p>When the <code>require-param?</code> is set to <code>false</code> (default) and a path is given but it does not require this parameter, a path will be generated by testing whether it exists for regular and for slash-stripped or slash-added variant (the original variant goes first).</p>
<p>When the <code>require-param?</code> is set to <code>false</code> (default) and a path is given but it does not require this parameter plus the <code>name-path-fallback?</code> argument is set to <code>:brute-force</code>, all possible path variants (with parameter injected within its succesive segments) will be tried in hope that one will exist, regardless of parameter name that matches. Use it with caution as it may give weird matches; if for example, there is a route path <code>/users/:id</code> defined, and the given path is <code>/users/</code> with <code>:lang</code> parameter set to <code>:pl</code>, then it will match <code>/users/pl</code> even though the parameter name is different.</p>
<p>When the <code>require-param?</code> is set to <code>true</code> and a path is given but it does not require this parameter, all possible path variants (with parameter injected within its succesive segments) will be tried in hope that one will match, being a path that requires this parameter.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L459">view source</a></div></div><div class="public anchor" id="var-path"><h3>path</h3><div class="usage"><code>(path)</code><code>(path req)</code><code>(path req name-or-path)</code><code>(path req name-or-path lang)</code><code>(path req name-or-path lang params)</code><code>(path req name-or-path lang params query-params)</code><code>(path name-or-path lang params query-params router language-settings-or-param)</code></div><div class="doc"><div class="markdown"><p>Creates a URL on a basis of route name or a path.</p>
<p>If a page found does not have a language parameter it is accepted too.</p>
<p>When the given path is already parameterized with language then re-parameterized path is generated and checked if it exists, unless the value of the parameter is the same as the existing one. In such case the path is returned after a quick existence check.</p>
<p>Additional path parameters (<code>params</code>) can be given to be used when matching by name. Giving extra (unknown to route) parameters does not affect lookup. Giving <code>params</code> when matching by path causes them to be silently ignored.</p>
<p>Additional query parameters (<code>query-params</code>) can be given. They will be used when generating path. If the path was given and it already contains query parameters, they will be replaced.</p>
<p>If the path is given instead of a route identifier, it must exist (after being equipped with any extra parameters, if needed, using <code>params</code>).</p>
<p>When a path is given but it does not require language parameter, a path will be generated by testing whether it exists for regular and for slash-stripped or slash-added variant (the original variant goes first).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1882">view source</a></div></div><div class="public anchor" id="var-path-language"><h3>path-language</h3><div class="usage"><code>(path-language req)</code><code>(path-language req-or-match path-or-lang-settings)</code><code>(path-language req path router)</code><code>(path-language _ path router language-settings-or-param)</code></div><div class="doc"><div class="markdown"><p>Returns a language string if the given path contains a language parameter. Otherwise it returns nil.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L269">view source</a></div></div><div class="public anchor" id="var-path-param"><h3>path-param</h3><div class="usage"><code>(path-param req-or-match param)</code><code>(path-param req path param)</code><code>(path-param _ path param router)</code></div><div class="doc"><div class="markdown"><p>Returns a parameter if the given path contains it and it is set. Otherwise it returns nil.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L247">view source</a></div></div><div class="public anchor" id="var-path-params"><h3>path-params</h3><div class="usage"><code>(path-params req-or-match)</code><code>(path-params req path)</code><code>(path-params _ path router)</code></div><div class="doc"><div class="markdown"><p>Returns a map of parameters if the given path contains it. Otherwise it returns nil.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L259">view source</a></div></div><div class="public anchor" id="var-path-template-with-param"><h3>path-template-with-param</h3><div class="usage"><code>(path-template-with-param match required-param)</code><code>(path-template-with-param match required-param short-circuit)</code></div><div class="doc"><div class="markdown"><p>Returns a path template for the given match if the route supports the given parameter.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L364">view source</a></div></div><div class="public anchor" id="var-path-variants"><h3>path-variants</h3><div class="usage"><code>(path-variants path lang-id)</code><code>(path-variants path lang suffix)</code></div><div class="doc"><div class="markdown"><p>Generates a list of all possible language variants of a path.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L241">view source</a></div></div><div class="public anchor" id="var-pick-language"><h3>pick-language</h3><div class="usage"><code>(pick-language req)</code><code>(pick-language req pickers)</code><code>(pick-language req picker-id)</code><code>(pick-language req pickers picker-id)</code></div><div class="doc"><div class="markdown"><p>Tries to pick the best language for a known user or a visitor. To be used (among other scenarios) after a successful log-in to show the right language version of a welcome page. Does not use pre-calculated values from a request map, instead triggers configured pickers from a default or given chain. Returns a keyword.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1389">view source</a></div></div><div class="public anchor" id="var-pick-language-str"><h3>pick-language-str</h3><div class="usage"><code>(pick-language-str req)</code><code>(pick-language-str req pickers)</code><code>(pick-language-str req picker-id)</code><code>(pick-language-str req pickers picker-id)</code></div><div class="doc"><div class="markdown"><p>Tries to pick the best language for a known user or a visitor. To be used (among other scenarios) after a successful log-in to show the right language version of a welcome page. Does not use pre-calculated values from a request map, instead triggers configured pickers from a default or given chain. Returns a string.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1401">view source</a></div></div><div class="public anchor" id="var-pick-language-str-without-fallback"><h3>pick-language-str-without-fallback</h3><div class="usage"><code>(pick-language-str-without-fallback req)</code><code>(pick-language-str-without-fallback req pickers)</code><code>(pick-language-str-without-fallback req picker-id)</code><code>(pick-language-str-without-fallback req pickers picker-id)</code></div><div class="doc"><div class="markdown"><p>Tries to pick the best language for a known user or a visitor. To be used (among other scenarios) after a successful log-in to show the right language version of a welcome page. Does not use pre-calculated values from a request map, instead triggers configured pickers from a default or given chain. When a language cannot be found it simply returns <code>nil</code> instead of a default language. Returns a string.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1426">view source</a></div></div><div class="public anchor" id="var-pick-language-without-fallback"><h3>pick-language-without-fallback</h3><div class="usage"><code>(pick-language-without-fallback req)</code><code>(pick-language-without-fallback req pickers)</code><code>(pick-language-without-fallback req picker-id)</code><code>(pick-language-without-fallback req pickers picker-id)</code></div><div class="doc"><div class="markdown"><p>Tries to pick the best language for a known user or a visitor. To be used (among other scenarios) after a successful log-in to show the right language version of a welcome page. Does not use pre-calculated values from a request map, instead triggers configured pickers from a default or given chain. When a language cannot be found it simply returns <code>nil</code> instead of a default language. Returns a keyword.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1413">view source</a></div></div><div class="public anchor" id="var-prep-app-data"><h3>prep-app-data</h3><div class="usage"><code>(prep-app-data req)</code><code>(prep-app-data req data)</code><code>(prep-app-data req data keyz)</code></div><div class="doc"><div class="markdown"><p>Prepares data for the rendering functions by copying the given values associated with the given keys from <code>req</code> to a lazy map under <code>:app/data</code> key of the <code>req</code>. The list of keys to copy must be as a sequential collection, explicitly given as <code>keyz</code>, or reside under <code>:app/data-required</code> of the <code>req</code>. If there already is <code>:app/data</code> in the request map then it will be used as the initial value of the created data map. Data for existing keys will not be copied.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L185">view source</a></div></div><div class="public anchor" id="var-remote-ip-keys"><h3>remote-ip-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L51">view source</a></div></div><div class="public anchor" id="var-remove-status"><h3>remove-status</h3><h4 class="type">macro</h4><div class="usage"><code>(remove-status req)</code></div><div class="doc"><div class="markdown"><p>Removes <code>:response/status</code> from <code>req</code> using <code>clojure.core/dissoc</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L2533">view source</a></div></div><div class="public anchor" id="var-render"><h3>render</h3><div class="usage"><code>(render)</code><code>(render req)</code><code>(render req status)</code><code>(render req status data)</code><code>(render req status data view)</code><code>(render req status data view layout)</code><code>(render req http-status data view layout lang)</code></div><div class="doc"><div class="markdown"><p>HTML web page renderer. Takes a request, a data map to be used in templates, a name of the view file (defaults to <code>:app/view</code> from the <code>req</code>), a name of the template file (defaults to <code>:app/layout</code> from the <code>req</code>) and a language string (guessed if not given, unless explicitly set to <code>false</code>).</p>
<p>Uses values associated with the <code>:layout/dir</code> and <code>:view/dir</code> keys of the <code>req</code> to obtain optional subdirectories to be looked up when searching for views and layouts.</p>
<p>It will add <code>:status</code>, <code>:status/title</code> and <code>:status/description</code> entries to <code>:app/data</code> map (unless it already contains one), using configuration maps associated with the <code>:errors/config</code> key of a route data.</p>
<p>In case of a regular response page (when the namespace of a <code>status</code> keyword is “ok” or “info”) the following sources are checked to find a layout path: - the given <code>layout</code>, - value of <code>:app/layout</code> (in a route data or a request map).</p>
<p>In case of a regular response page (when the namespace of a <code>status</code> keyword is “ok” or “info”) the following sources are checked to find a view path: - the given <code>view</code>, - value of <code>:app/view</code> (in a route data or a request map).</p>
<p>In case of an error response page (when the namespace of a <code>status</code> keyword is not “ok” nor “info”) the following sources are checked to find a layout path: - the given <code>layout</code>, - value of <code>status</code> looked up in a map under <code>:status/layouts</code> (in a route data or a request map), - value of <code>:app/error-layout</code> (in a route data or a request map), - “error”.</p>
<p>In case of an error response page (when the namespace of a status keyword is not “ok” nor “info”) the following sources are checked to find a view path: - the given <code>view</code>, - value of <code>status</code> looked up in a map under <code>:status/views</code> (in a route data or a request map), - value of <code>:app/error-view</code> (in a route data or a request map), - “error”.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L607">view source</a></div></div><div class="public anchor" id="var-render-accepted"><h3>render-accepted</h3><div class="usage"><code>(render-accepted)</code><code>(render-accepted req)</code><code>(render-accepted req data)</code><code>(render-accepted req data view)</code><code>(render-accepted req data view layout)</code><code>(render-accepted req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/accepted</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/accepted</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L856">view source</a></div></div><div class="public anchor" id="var-render-already-reported"><h3>render-already-reported</h3><div class="usage"><code>(render-already-reported)</code><code>(render-already-reported req)</code><code>(render-already-reported req data)</code><code>(render-already-reported req data view)</code><code>(render-already-reported req data view layout)</code><code>(render-already-reported req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/already-reported</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/already-reported</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L860">view source</a></div></div><div class="public anchor" id="var-render-bad-gateway"><h3>render-bad-gateway</h3><div class="usage"><code>(render-bad-gateway)</code><code>(render-bad-gateway req)</code><code>(render-bad-gateway req data)</code><code>(render-bad-gateway req data view)</code><code>(render-bad-gateway req data view layout)</code><code>(render-bad-gateway req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/bad-gateway</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/bad-gateway</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L905">view source</a></div></div><div class="public anchor" id="var-render-bad-params"><h3>render-bad-params</h3><div class="usage"><code>(render-bad-params)</code><code>(render-bad-params req)</code><code>(render-bad-params req data)</code><code>(render-bad-params req data view)</code><code>(render-bad-params req data view layout)</code><code>(render-bad-params req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unprocessable-entity</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/bad-parameters</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L891">view source</a></div></div><div class="public anchor" id="var-render-bad-request"><h3>render-bad-request</h3><div class="usage"><code>(render-bad-request)</code><code>(render-bad-request req)</code><code>(render-bad-request req data)</code><code>(render-bad-request req data view)</code><code>(render-bad-request req data view layout)</code><code>(render-bad-request req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/bad-request</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/bad-request</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L869">view source</a></div></div><div class="public anchor" id="var-render-bandwidth-limit-exceeded"><h3>render-bandwidth-limit-exceeded</h3><div class="usage"><code>(render-bandwidth-limit-exceeded)</code><code>(render-bandwidth-limit-exceeded req)</code><code>(render-bandwidth-limit-exceeded req data)</code><code>(render-bandwidth-limit-exceeded req data view)</code><code>(render-bandwidth-limit-exceeded req data view layout)</code><code>(render-bandwidth-limit-exceeded req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/bandwidth-limit-exceeded</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/bandwidth-limit-exceeded</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L912">view source</a></div></div><div class="public anchor" id="var-render-blocked-by-windows-parental-controls"><h3>render-blocked-by-windows-parental-controls</h3><div class="usage"><code>(render-blocked-by-windows-parental-controls)</code><code>(render-blocked-by-windows-parental-controls req)</code><code>(render-blocked-by-windows-parental-controls req data)</code><code>(render-blocked-by-windows-parental-controls req data view)</code><code>(render-blocked-by-windows-parental-controls req data view layout)</code><code>(render-blocked-by-windows-parental-controls req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/blocked-by-windows-parental-controls</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/blocked-by-windows-parental-controls</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L901">view source</a></div></div><div class="public anchor" id="var-render-conflict"><h3>render-conflict</h3><div class="usage"><code>(render-conflict)</code><code>(render-conflict req)</code><code>(render-conflict req data)</code><code>(render-conflict req data view)</code><code>(render-conflict req data view layout)</code><code>(render-conflict req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/conflict</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/conflict</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L878">view source</a></div></div><div class="public anchor" id="var-render-continue"><h3>render-continue</h3><div class="usage"><code>(render-continue)</code><code>(render-continue req)</code><code>(render-continue req & ignored)</code></div><div class="doc"><div class="markdown"><p>Renders 100 response without a body.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L988">view source</a></div></div><div class="public anchor" id="var-render-created"><h3>render-created</h3><div class="usage"><code>(render-created)</code><code>(render-created req)</code><code>(render-created req data)</code><code>(render-created req data view)</code><code>(render-created req data view layout)</code><code>(render-created req data view layout lang)</code><code>(render-created req data view layout lang name-or-path)</code><code>(render-created req data view layout lang name-or-path params)</code><code>(render-created req data view layout lang name-or-path params query-params)</code></div><div class="doc"><div class="markdown"><p>Renders 201 response with a redirect (possibly localized if a destination path is language-parameterized) and a possible body. See <code>render</code> documentation to know more about body rendering. The destination for a redirect is taken from <code>name-or-path</code> argument or, if not given, from the <code>:response/location</code> key of the given request map (<code>req</code>).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L920">view source</a></div></div><div class="public anchor" id="var-render-early-hints"><h3>render-early-hints</h3><div class="usage"><code>(render-early-hints)</code><code>(render-early-hints req)</code><code>(render-early-hints req data)</code><code>(render-early-hints req data view)</code><code>(render-early-hints req data view layout)</code><code>(render-early-hints req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>common/early-hints</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:info/early-hints</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L865">view source</a></div></div><div class="public anchor" id="var-render-enhance-your-calm"><h3>render-enhance-your-calm</h3><div class="usage"><code>(render-enhance-your-calm)</code><code>(render-enhance-your-calm req)</code><code>(render-enhance-your-calm req data)</code><code>(render-enhance-your-calm req data view)</code><code>(render-enhance-your-calm req data view layout)</code><code>(render-enhance-your-calm req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/enhance-your-calm</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/enhance-your-calm</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L888">view source</a></div></div><div class="public anchor" id="var-render-error"><h3>render-error</h3><div class="usage"><code>(render-error)</code><code>(render-error req)</code><code>(render-error req app-status)</code><code>(render-error req app-statuses)</code><code>(render-error req app-status default)</code><code>(render-error req app-statuses default)</code><code>(render-error req app-status default data)</code><code>(render-error req app-statuses default data)</code><code>(render-error req app-status default data view)</code><code>(render-error req app-statuses default data view)</code><code>(render-error req app-status default data view layout)</code><code>(render-error req app-statuses default data view layout)</code><code>(render-error req app-status default data view layout lang)</code><code>(render-error req app-statuses default data view layout lang)</code><code>(render-error req app-status default data view layout lang & more)</code><code>(render-error req app-statuses default data view layout lang & more)</code></div><div class="doc"><div class="markdown"><p>Renders error response.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1036">view source</a></div></div><div class="public anchor" id="var-render-expectation-failed"><h3>render-expectation-failed</h3><div class="usage"><code>(render-expectation-failed)</code><code>(render-expectation-failed req)</code><code>(render-expectation-failed req data)</code><code>(render-expectation-failed req data view)</code><code>(render-expectation-failed req data view layout)</code><code>(render-expectation-failed req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/expectation-failed</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/expectation-failed</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L886">view source</a></div></div><div class="public anchor" id="var-render-failed-dependency"><h3>render-failed-dependency</h3><div class="usage"><code>(render-failed-dependency)</code><code>(render-failed-dependency req)</code><code>(render-failed-dependency req data)</code><code>(render-failed-dependency req data view)</code><code>(render-failed-dependency req data view layout)</code><code>(render-failed-dependency req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/failed-dependency</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/failed-dependency</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L893">view source</a></div></div><div class="public anchor" id="var-render-forbidden"><h3>render-forbidden</h3><div class="usage"><code>(render-forbidden)</code><code>(render-forbidden req)</code><code>(render-forbidden req data)</code><code>(render-forbidden req data view)</code><code>(render-forbidden req data view layout)</code><code>(render-forbidden req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/forbidden</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/forbidden</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L872">view source</a></div></div><div class="public anchor" id="var-render-found"><h3>render-found</h3><div class="usage"><code>(render-found)</code><code>(render-found req)</code><code>(render-found req data)</code><code>(render-found req data view)</code><code>(render-found req data view layout)</code><code>(render-found req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/ok</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/found</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L852">view source</a></div></div><div class="public anchor" id="var-render-gateway-timeout"><h3>render-gateway-timeout</h3><div class="usage"><code>(render-gateway-timeout)</code><code>(render-gateway-timeout req)</code><code>(render-gateway-timeout req data)</code><code>(render-gateway-timeout req data view)</code><code>(render-gateway-timeout req data view layout)</code><code>(render-gateway-timeout req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/gateway-timeout</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/gateway-timeout</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L907">view source</a></div></div><div class="public anchor" id="var-render-gone"><h3>render-gone</h3><div class="usage"><code>(render-gone)</code><code>(render-gone req)</code><code>(render-gone req data)</code><code>(render-gone req data view)</code><code>(render-gone req data view layout)</code><code>(render-gone req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/gone</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/gone</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L879">view source</a></div></div><div class="public anchor" id="var-render-http-version-not-supported"><h3>render-http-version-not-supported</h3><div class="usage"><code>(render-http-version-not-supported)</code><code>(render-http-version-not-supported req)</code><code>(render-http-version-not-supported req data)</code><code>(render-http-version-not-supported req data view)</code><code>(render-http-version-not-supported req data view layout)</code><code>(render-http-version-not-supported req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/http-version-not-supported</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/http-version-not-supported</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L908">view source</a></div></div><div class="public anchor" id="var-render-im-a-teapot"><h3>render-im-a-teapot</h3><div class="usage"><code>(render-im-a-teapot)</code><code>(render-im-a-teapot req)</code><code>(render-im-a-teapot req data)</code><code>(render-im-a-teapot req data view)</code><code>(render-im-a-teapot req data view layout)</code><code>(render-im-a-teapot req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>common/im-a-teapot</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/im-a-teapot</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L887">view source</a></div></div><div class="public anchor" id="var-render-im-used"><h3>render-im-used</h3><div class="usage"><code>(render-im-used)</code><code>(render-im-used req)</code><code>(render-im-used req data)</code><code>(render-im-used req data view)</code><code>(render-im-used req data view layout)</code><code>(render-im-used req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/im-used</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/im-used</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L861">view source</a></div></div><div class="public anchor" id="var-render-insufficient-storage"><h3>render-insufficient-storage</h3><div class="usage"><code>(render-insufficient-storage)</code><code>(render-insufficient-storage req)</code><code>(render-insufficient-storage req data)</code><code>(render-insufficient-storage req data view)</code><code>(render-insufficient-storage req data view layout)</code><code>(render-insufficient-storage req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/insufficient-storage</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/insufficient-storage</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L910">view source</a></div></div><div class="public anchor" id="var-render-internal-server-error"><h3>render-internal-server-error</h3><div class="usage"><code>(render-internal-server-error)</code><code>(render-internal-server-error req)</code><code>(render-internal-server-error req data)</code><code>(render-internal-server-error req data view)</code><code>(render-internal-server-error req data view layout)</code><code>(render-internal-server-error req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/internal-server-error</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/internal</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L903">view source</a></div></div><div class="public anchor" id="var-render-length-required"><h3>render-length-required</h3><div class="usage"><code>(render-length-required)</code><code>(render-length-required req)</code><code>(render-length-required req data)</code><code>(render-length-required req data view)</code><code>(render-length-required req data view layout)</code><code>(render-length-required req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/length-required</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/length-required</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L880">view source</a></div></div><div class="public anchor" id="var-render-locked"><h3>render-locked</h3><div class="usage"><code>(render-locked)</code><code>(render-locked req)</code><code>(render-locked req data)</code><code>(render-locked req data view)</code><code>(render-locked req data view layout)</code><code>(render-locked req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/locked</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/render-locked</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L892">view source</a></div></div><div class="public anchor" id="var-render-loop-detected"><h3>render-loop-detected</h3><div class="usage"><code>(render-loop-detected)</code><code>(render-loop-detected req)</code><code>(render-loop-detected req data)</code><code>(render-loop-detected req data view)</code><code>(render-loop-detected req data view layout)</code><code>(render-loop-detected req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/loop-detected</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/loop-detected</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L911">view source</a></div></div><div class="public anchor" id="var-render-method-not-allowed"><h3>render-method-not-allowed</h3><div class="usage"><code>(render-method-not-allowed)</code><code>(render-method-not-allowed req)</code><code>(render-method-not-allowed req data)</code><code>(render-method-not-allowed req data view)</code><code>(render-method-not-allowed req data view layout)</code><code>(render-method-not-allowed req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/method-not-allowed</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/method-not-allowed</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L874">view source</a></div></div><div class="public anchor" id="var-render-misdirected-request"><h3>render-misdirected-request</h3><div class="usage"><code>(render-misdirected-request)</code><code>(render-misdirected-request req)</code><code>(render-misdirected-request req data)</code><code>(render-misdirected-request req data view)</code><code>(render-misdirected-request req data view layout)</code><code>(render-misdirected-request req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>common/misdirected-request</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/misdirected-request</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L889">view source</a></div></div><div class="public anchor" id="var-render-multi-status"><h3>render-multi-status</h3><div class="usage"><code>(render-multi-status)</code><code>(render-multi-status req)</code><code>(render-multi-status req data)</code><code>(render-multi-status req data view)</code><code>(render-multi-status req data view layout)</code><code>(render-multi-status req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/multi-status</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/multi-status</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L859">view source</a></div></div><div class="public anchor" id="var-render-network-authentication-required"><h3>render-network-authentication-required</h3><div class="usage"><code>(render-network-authentication-required)</code><code>(render-network-authentication-required req)</code><code>(render-network-authentication-required req data)</code><code>(render-network-authentication-required req data view)</code><code>(render-network-authentication-required req data view layout)</code><code>(render-network-authentication-required req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/network-authentication-required</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/network-authentication-required</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L914">view source</a></div></div><div class="public anchor" id="var-render-network-connect-timeout"><h3>render-network-connect-timeout</h3><div class="usage"><code>(render-network-connect-timeout)</code><code>(render-network-connect-timeout req)</code><code>(render-network-connect-timeout req data)</code><code>(render-network-connect-timeout req data view)</code><code>(render-network-connect-timeout req data view layout)</code><code>(render-network-connect-timeout req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/network-connect-timeout</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/connect-timeout</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L916">view source</a></div></div><div class="public anchor" id="var-render-network-read-timeout"><h3>render-network-read-timeout</h3><div class="usage"><code>(render-network-read-timeout)</code><code>(render-network-read-timeout req)</code><code>(render-network-read-timeout req data)</code><code>(render-network-read-timeout req data view)</code><code>(render-network-read-timeout req data view layout)</code><code>(render-network-read-timeout req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/network-read-timeout</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/read-timeout</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L915">view source</a></div></div><div class="public anchor" id="var-render-no-content"><h3>render-no-content</h3><div class="usage"><code>(render-no-content)</code><code>(render-no-content req)</code><code>(render-no-content req & ignored)</code></div><div class="doc"><div class="markdown"><p>Renders 204 response without a body.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1006">view source</a></div></div><div class="public anchor" id="var-render-non-authoritative-information"><h3>render-non-authoritative-information</h3><div class="usage"><code>(render-non-authoritative-information)</code><code>(render-non-authoritative-information req)</code><code>(render-non-authoritative-information req data)</code><code>(render-non-authoritative-information req data view)</code><code>(render-non-authoritative-information req data view layout)</code><code>(render-non-authoritative-information req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/non-authoritative-information</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/non-authoritative-information</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L857">view source</a></div></div><div class="public anchor" id="var-render-not-acceptable"><h3>render-not-acceptable</h3><div class="usage"><code>(render-not-acceptable)</code><code>(render-not-acceptable req)</code><code>(render-not-acceptable req data)</code><code>(render-not-acceptable req data view)</code><code>(render-not-acceptable req data view layout)</code><code>(render-not-acceptable req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/not-acceptable</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/not-acceptable</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L875">view source</a></div></div><div class="public anchor" id="var-render-not-extended"><h3>render-not-extended</h3><div class="usage"><code>(render-not-extended)</code><code>(render-not-extended req)</code><code>(render-not-extended req data)</code><code>(render-not-extended req data view)</code><code>(render-not-extended req data view layout)</code><code>(render-not-extended req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/not-extended</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/not-extended</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L913">view source</a></div></div><div class="public anchor" id="var-render-not-found"><h3>render-not-found</h3><div class="usage"><code>(render-not-found)</code><code>(render-not-found req)</code><code>(render-not-found req data)</code><code>(render-not-found req data view)</code><code>(render-not-found req data view layout)</code><code>(render-not-found req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/not-found</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/not-found</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L873">view source</a></div></div><div class="public anchor" id="var-render-not-implemented"><h3>render-not-implemented</h3><div class="usage"><code>(render-not-implemented)</code><code>(render-not-implemented req)</code><code>(render-not-implemented req data)</code><code>(render-not-implemented req data view)</code><code>(render-not-implemented req data view layout)</code><code>(render-not-implemented req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/not-implemented</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/not-implemented</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L904">view source</a></div></div><div class="public anchor" id="var-render-ok"><h3>render-ok</h3><div class="usage"><code>(render-ok)</code><code>(render-ok req)</code><code>(render-ok req data)</code><code>(render-ok req data view)</code><code>(render-ok req data view layout)</code><code>(render-ok req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/ok</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/found</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L850">view source</a></div></div><div class="public anchor" id="var-render-page"><h3>render-page</h3><div class="usage"><code>(render-page)</code><code>(render-page req)</code><code>(render-page req data)</code><code>(render-page req data view)</code><code>(render-page req data view layout)</code><code>(render-page req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/ok</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/found</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L851">view source</a></div></div><div class="public anchor" id="var-render-partial-content"><h3>render-partial-content</h3><div class="usage"><code>(render-partial-content)</code><code>(render-partial-content req)</code><code>(render-partial-content req data)</code><code>(render-partial-content req data view)</code><code>(render-partial-content req data view layout)</code><code>(render-partial-content req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/partial-content</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:ok/partial-content</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L858">view source</a></div></div><div class="public anchor" id="var-render-payment-required"><h3>render-payment-required</h3><div class="usage"><code>(render-payment-required)</code><code>(render-payment-required req)</code><code>(render-payment-required req data)</code><code>(render-payment-required req data view)</code><code>(render-payment-required req data view layout)</code><code>(render-payment-required req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/payment-required</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/payment-required</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L871">view source</a></div></div><div class="public anchor" id="var-render-precondition-failed"><h3>render-precondition-failed</h3><div class="usage"><code>(render-precondition-failed)</code><code>(render-precondition-failed req)</code><code>(render-precondition-failed req data)</code><code>(render-precondition-failed req data view)</code><code>(render-precondition-failed req data view layout)</code><code>(render-precondition-failed req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/precondition-failed</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/precondition-failed</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L881">view source</a></div></div><div class="public anchor" id="var-render-precondition-required"><h3>render-precondition-required</h3><div class="usage"><code>(render-precondition-required)</code><code>(render-precondition-required req)</code><code>(render-precondition-required req data)</code><code>(render-precondition-required req data view)</code><code>(render-precondition-required req data view layout)</code><code>(render-precondition-required req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/precondition-required</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/precondition-failed</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L897">view source</a></div></div><div class="public anchor" id="var-render-processing"><h3>render-processing</h3><div class="usage"><code>(render-processing)</code><code>(render-processing req)</code><code>(render-processing req & ignored)</code></div><div class="doc"><div class="markdown"><p>Renders 102 response without a body.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1000">view source</a></div></div><div class="public anchor" id="var-render-proxy-authentication-required"><h3>render-proxy-authentication-required</h3><div class="usage"><code>(render-proxy-authentication-required)</code><code>(render-proxy-authentication-required req)</code><code>(render-proxy-authentication-required req data)</code><code>(render-proxy-authentication-required req data view)</code><code>(render-proxy-authentication-required req data view layout)</code><code>(render-proxy-authentication-required req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/proxy-authentication-required</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/proxy-authentication-required</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L876">view source</a></div></div><div class="public anchor" id="var-render-request-entity-too-large"><h3>render-request-entity-too-large</h3><div class="usage"><code>(render-request-entity-too-large)</code><code>(render-request-entity-too-large req)</code><code>(render-request-entity-too-large req data)</code><code>(render-request-entity-too-large req data view)</code><code>(render-request-entity-too-large req data view layout)</code><code>(render-request-entity-too-large req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/request-entity-too-large</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/request-entity-too-large</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L882">view source</a></div></div><div class="public anchor" id="var-render-request-header-fields-too-large"><h3>render-request-header-fields-too-large</h3><div class="usage"><code>(render-request-header-fields-too-large)</code><code>(render-request-header-fields-too-large req)</code><code>(render-request-header-fields-too-large req data)</code><code>(render-request-header-fields-too-large req data view)</code><code>(render-request-header-fields-too-large req data view layout)</code><code>(render-request-header-fields-too-large req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/request-header-fields-too-large</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/request-header-fields-too-large</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L899">view source</a></div></div><div class="public anchor" id="var-render-request-timeout"><h3>render-request-timeout</h3><div class="usage"><code>(render-request-timeout)</code><code>(render-request-timeout req)</code><code>(render-request-timeout req data)</code><code>(render-request-timeout req data view)</code><code>(render-request-timeout req data view layout)</code><code>(render-request-timeout req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/request-timeout</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/request-timeout</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L877">view source</a></div></div><div class="public anchor" id="var-render-request-uri-too-long"><h3>render-request-uri-too-long</h3><div class="usage"><code>(render-request-uri-too-long)</code><code>(render-request-uri-too-long req)</code><code>(render-request-uri-too-long req data)</code><code>(render-request-uri-too-long req data view)</code><code>(render-request-uri-too-long req data view layout)</code><code>(render-request-uri-too-long req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/request-uri-too-long</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/request-uri-too-long</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L883">view source</a></div></div><div class="public anchor" id="var-render-requested-range-not-satisfiable"><h3>render-requested-range-not-satisfiable</h3><div class="usage"><code>(render-requested-range-not-satisfiable)</code><code>(render-requested-range-not-satisfiable req)</code><code>(render-requested-range-not-satisfiable req data)</code><code>(render-requested-range-not-satisfiable req data view)</code><code>(render-requested-range-not-satisfiable req data view layout)</code><code>(render-requested-range-not-satisfiable req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/requested-range-not-satisfiable</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/requested-range-not-satisfiable</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L885">view source</a></div></div><div class="public anchor" id="var-render-reset-content"><h3>render-reset-content</h3><div class="usage"><code>(render-reset-content)</code><code>(render-reset-content req)</code><code>(render-reset-content req & ignored)</code></div><div class="doc"><div class="markdown"><p>Renders 205 response without a body.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1012">view source</a></div></div><div class="public anchor" id="var-render-response"><h3>render-response</h3><div class="usage"><code>(render-response)</code><code>(render-response resp-fn)</code><code>(render-response resp-fn req)</code><code>(render-response resp-fn status req)</code><code>(render-response resp-fn status req data)</code><code>(render-response resp-fn status req data view)</code><code>(render-response resp-fn status req data view layout)</code><code>(render-response resp-fn status req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Web response renderer. Uses the <code>render</code> function to render a response body (using values associated with the <code>:app/data</code>, <code>:app/view</code>, <code>:app/layout</code>, <code>:app/view-dir</code> and <code>:app/layout-dir</code> in the <code>req</code> map, or provided as arguments) and response headers (using the <code>:response/headers</code> value), unless the <code>req</code> is already a valid response.</p>
<p>It will add <code>:status</code>, <code>:status/title</code> and <code>:status/description</code> entries to <code>:app/data</code> map (unless it already contains one), using configuration maps associated with the <code>:errors/config</code> key of a route data.</p>
<p>In case of a regular response page (when the namespace of a <code>status</code> keyword is “ok” or “info”) the following sources are checked to find a layout path: - the given <code>layout</code>, - value of <code>:app/layout</code> (in a route data or a request map).</p>
<p>In case of a regular response page (when the namespace of a <code>status</code> keyword is “ok” or “info”) the following sources are checked to find a view path: - the given <code>view</code>, - value of <code>:app/view</code> (in a route data or a request map).</p>
<p>In case of an error response page (when the namespace of a <code>status</code> keyword is not “ok” nor “info”) the following sources are checked to find a layout path: - the given <code>layout</code>, - value of <code>status</code> looked up in a map under <code>:status/layouts</code> (in a route data or a request map), - value of <code>:app/error-layout</code> (in a route data or a request map), - “error”.</p>
<p>In case of an error response page (when the namespace of a status keyword is not “ok” nor “info”) the following sources are checked to find a view path: - the given <code>view</code>, - value of <code>status</code> looked up in a map under <code>:status/views</code> (in a route data or a request map), - value of <code>:app/error-view</code> (in a route data or a request map), - “error”.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L688">view source</a></div></div><div class="public anchor" id="var-render-response-force"><h3>render-response-force</h3><div class="usage"><code>(render-response-force)</code><code>(render-response-force resp-fn)</code><code>(render-response-force resp-fn req)</code><code>(render-response-force resp-fn status req)</code><code>(render-response-force resp-fn status req data)</code><code>(render-response-force resp-fn status req data view)</code><code>(render-response-force resp-fn status req data view layout)</code><code>(render-response-force resp-fn status req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Web response renderer. Uses the <code>render</code> function to render a response body (using values associated with the <code>:app/data</code>, <code>:app/view</code> and <code>:app/layout</code> in the <code>req</code> map, or provided as arguments) and the response headers (using the <code>:response/headers</code> value), regardless if the <code>req</code> is already a valid response or not.</p>
<p>It will add <code>:status</code>, <code>:status/title</code> and <code>:status/description</code> entries to <code>:app/data</code> map (unless it already contains one), using configuration maps associated with the <code>:errors/config</code> key of a route data.</p>
<p>In case of a regular response page (when the namespace of a <code>status</code> keyword is “ok” or “info”) the following sources are checked to find a layout path: - the given <code>layout</code>, - value of <code>:app/layout</code> (in a route data or a request map).</p>
<p>In case of a regular response page (when the namespace of a <code>status</code> keyword is “ok” or “info”) the following sources are checked to find a view path: - the given <code>view</code>, - value of <code>:app/view</code> (in a route data or a request map).</p>
<p>In case of an error response page (when the namespace of a <code>status</code> keyword is not “ok” nor “info”) the following sources are checked to find a layout path: - the given <code>layout</code>, - value of <code>status</code> looked up in a map under <code>:status/layouts</code> (in a route data or a request map), - value of <code>:app/error-layout</code> (in a route data or a request map), - “error”.</p>
<p>In case of an error response page (when the namespace of a status keyword is not “ok” nor “info”) the following sources are checked to find a view path: - the given <code>view</code>, - value of <code>status</code> looked up in a map under <code>:status/views</code> (in a route data or a request map), - value of <code>:app/error-view</code> (in a route data or a request map), - “error”.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L745">view source</a></div></div><div class="public anchor" id="var-render-retry-with"><h3>render-retry-with</h3><div class="usage"><code>(render-retry-with)</code><code>(render-retry-with req)</code><code>(render-retry-with req data)</code><code>(render-retry-with req data view)</code><code>(render-retry-with req data view layout)</code><code>(render-retry-with req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/retry-with</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/retry-with</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L900">view source</a></div></div><div class="public anchor" id="var-render-service-unavailable"><h3>render-service-unavailable</h3><div class="usage"><code>(render-service-unavailable)</code><code>(render-service-unavailable req)</code><code>(render-service-unavailable req data)</code><code>(render-service-unavailable req data view)</code><code>(render-service-unavailable req data view layout)</code><code>(render-service-unavailable req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/service-unavailable</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/service-unavailable</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L906">view source</a></div></div><div class="public anchor" id="var-render-status"><h3>render-status</h3><div class="usage"><code>(render-status)</code><code>(render-status req)</code><code>(render-status req app-status)</code><code>(render-status req app-statuses)</code><code>(render-status req app-status default)</code><code>(render-status req app-statuses default)</code><code>(render-status req app-status default data)</code><code>(render-status req app-statuses default data)</code><code>(render-status req app-status default data view)</code><code>(render-status req app-statuses default data view)</code><code>(render-status req app-status default data view layout)</code><code>(render-status req app-statuses default data view layout)</code><code>(render-status req app-status default data view layout lang)</code><code>(render-status req app-statuses default data view layout lang)</code><code>(render-status req app-status default data view layout lang & more)</code><code>(render-status req app-statuses default data view layout lang & more)</code></div><div class="doc"><div class="markdown"><p>Renders status response.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L1094">view source</a></div></div><div class="public anchor" id="var-render-switching-protocols"><h3>render-switching-protocols</h3><div class="usage"><code>(render-switching-protocols)</code><code>(render-switching-protocols req)</code><code>(render-switching-protocols req & ignored)</code></div><div class="doc"><div class="markdown"><p>Renders 101 response without a body.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L994">view source</a></div></div><div class="public anchor" id="var-render-too-early"><h3>render-too-early</h3><div class="usage"><code>(render-too-early)</code><code>(render-too-early req)</code><code>(render-too-early req data)</code><code>(render-too-early req data view)</code><code>(render-too-early req data view layout)</code><code>(render-too-early req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unordered-collection</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/too-early</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L895">view source</a></div></div><div class="public anchor" id="var-render-too-many-requests"><h3>render-too-many-requests</h3><div class="usage"><code>(render-too-many-requests)</code><code>(render-too-many-requests req)</code><code>(render-too-many-requests req data)</code><code>(render-too-many-requests req data view)</code><code>(render-too-many-requests req data view layout)</code><code>(render-too-many-requests req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/too-many-requests</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/too-many-requests</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L898">view source</a></div></div><div class="public anchor" id="var-render-unauthorized"><h3>render-unauthorized</h3><div class="usage"><code>(render-unauthorized)</code><code>(render-unauthorized req)</code><code>(render-unauthorized req data)</code><code>(render-unauthorized req data view)</code><code>(render-unauthorized req data view layout)</code><code>(render-unauthorized req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unauthorized</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/unauthorized</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L870">view source</a></div></div><div class="public anchor" id="var-render-unavailable-for-legal-reasons"><h3>render-unavailable-for-legal-reasons</h3><div class="usage"><code>(render-unavailable-for-legal-reasons)</code><code>(render-unavailable-for-legal-reasons req)</code><code>(render-unavailable-for-legal-reasons req data)</code><code>(render-unavailable-for-legal-reasons req data view)</code><code>(render-unavailable-for-legal-reasons req data view layout)</code><code>(render-unavailable-for-legal-reasons req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unavailable-for-legal-reasons</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/unavailable-for-legal-reasons</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L902">view source</a></div></div><div class="public anchor" id="var-render-unordered-collection"><h3>render-unordered-collection</h3><div class="usage"><code>(render-unordered-collection)</code><code>(render-unordered-collection req)</code><code>(render-unordered-collection req data)</code><code>(render-unordered-collection req data view)</code><code>(render-unordered-collection req data view layout)</code><code>(render-unordered-collection req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unordered-collection</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/unordered-collection</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L894">view source</a></div></div><div class="public anchor" id="var-render-unprocessable-entity"><h3>render-unprocessable-entity</h3><div class="usage"><code>(render-unprocessable-entity)</code><code>(render-unprocessable-entity req)</code><code>(render-unprocessable-entity req data)</code><code>(render-unprocessable-entity req data view)</code><code>(render-unprocessable-entity req data view layout)</code><code>(render-unprocessable-entity req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unprocessable-entity</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/unprocessable-entity</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L890">view source</a></div></div><div class="public anchor" id="var-render-unsupported-media-type"><h3>render-unsupported-media-type</h3><div class="usage"><code>(render-unsupported-media-type)</code><code>(render-unsupported-media-type req)</code><code>(render-unsupported-media-type req data)</code><code>(render-unsupported-media-type req data view)</code><code>(render-unsupported-media-type req data view layout)</code><code>(render-unsupported-media-type req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/unsupported-media-type</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/unsupported-media-type</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L884">view source</a></div></div><div class="public anchor" id="var-render-upgrade-required"><h3>render-upgrade-required</h3><div class="usage"><code>(render-upgrade-required)</code><code>(render-upgrade-required req)</code><code>(render-upgrade-required req data)</code><code>(render-upgrade-required req data view)</code><code>(render-upgrade-required req data view layout)</code><code>(render-upgrade-required req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/upgrade-required</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:error/upgrade-required</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L896">view source</a></div></div><div class="public anchor" id="var-render-variant-also-negotiates"><h3>render-variant-also-negotiates</h3><div class="usage"><code>(render-variant-also-negotiates)</code><code>(render-variant-also-negotiates req)</code><code>(render-variant-also-negotiates req data)</code><code>(render-variant-also-negotiates req data view)</code><code>(render-variant-also-negotiates req data view layout)</code><code>(render-variant-also-negotiates req data view layout lang)</code></div><div class="doc"><div class="markdown"><p>Renders a response with a possible body generated with views, layouts and data obtained from a request map (<code>:app/layout</code>, <code>:app/view</code>, <code>:app/data</code> keys). Uses <code>resp/variant-also-negotiates</code> to set the response code. Additionaly, associates <code>:status</code> key with <code>:server-error/variant-also-negotiates</code> in <code>:app/data</code> by passing it as an argument to <code>render-response</code> (which will also set the <code>:status/title</code> and <code>:status/description</code> if possible).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L909">view source</a></div></div><div class="public anchor" id="var-resolve-cached"><h3>resolve-cached</h3><div class="usage"><code>(resolve-cached uri pre dir lang core)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L436">view source</a></div></div><div class="public anchor" id="var-resolve-generic"><h3>resolve-generic</h3><div class="usage"><code>(resolve-generic uri pre dir lang core)</code></div><div class="doc"><div class="markdown"><p>Generic view resolver. Takes <code>uri</code>, prefix (<code>pre</code>), base directory (<code>dir</code>), language (<code>lang</code>) and core name (<code>core</code>), and tries different combinations of path segments based on these parameters until it finds an existing view file within java resource directories.</p>
<p>If <code>dir</code> is <code>nil</code> or <code>false</code> it will create <code>auto-dir</code> by taking a directory part of <code>core</code> (if it has a directory part). Otherwise <code>auto-dir</code> will be same as <code>dir</code>.</p>
<p>Returns a pathname as a string.</p>
<p>Paths tried:</p>
<ul>
<li><code>pre</code>/<code>lang</code>/<code>dir</code>/<code>core</code>.html</li>
<li><code>pre</code>/<code>lang</code>/<code>dir</code>/<code>core</code>/default.html</li>
<li><code>pre</code>/<code>dir</code>/<code>core</code>.html</li>
<li><code>pre</code>/<code>lang</code>/<code>auto-dir</code>/default.html</li>
<li><code>pre</code>/<code>lang</code>/<code>auto-dir</code>.html (if <code>auto-dir</code> is not <code>nil</code>)</li>
<li><code>pre</code>/<code>auto-dir</code>/default.html (if <code>auto-dir</code> is not <code>nil</code>)</li>
<li><code>pre</code>/<code>auto-dir</code>.html (if <code>auto-dir</code> is not <code>nil</code>)</li>
<li><code>pre</code>/<code>lang</code>/default.html</li>
<li><code>pre</code>/default.html</li>
</ul>
<p>Example paths tried for <code>pre</code>=<code>"views"</code>, <code>lang</code>=<code>"pl"</code>, <code>dir</code>=<code>nil</code> and <code>core</code>=<code>:login/prolongate</code>:</p>
<ul>
<li><code>views/pl/login/prolongate.html</code></li>
<li><code>views/pl/login/prolongate/default.html</code></li>
<li><code>views/login/prolongate.html</code></li>
<li><code>views/pl/prolongate/default.html</code></li>
<li><code>views/pl/prolongate.html</code></li>
<li><code>views/prolongate/default.html</code></li>
<li><code>views/prolongate.html</code></li>
<li><code>views/pl/default.html</code></li>
<li><code>views/default.html</code></li>
</ul>
<p>Results are cached.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L376">view source</a></div></div><div class="public anchor" id="var-resolve-layout"><h3>resolve-layout</h3><div class="usage"><code>(resolve-layout req lang layout)</code><code>(resolve-layout req lang layout route-data)</code></div><div class="doc"><div class="markdown"><p>Returns a layout file for the given language <code>lang</code> and <code>layout</code> (a 2-element sequence of base directory and a layout name, or just a name as a single value). Uses <code>resolve-generic</code>.</p>
<p>If no layout name is given it uses <code>get-layout</code> to obtain it from a route data (<code>:app/layout</code> key) or to fall back to default.</p>
<p>If layout is set to <code>false</code>, explicitly disables using layout by returning <code>false</code> (may be helpful with partials rendered using AJAX calls).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L440">view source</a></div></div><div class="public anchor" id="var-resolve-view"><h3>resolve-view</h3><div class="usage"><code>(resolve-view req lang view)</code><code>(resolve-view req lang view route-data)</code></div><div class="doc"><div class="markdown"><p>Returns a view file for the given language <code>lang</code> and <code>view</code> (a 2-element sequence of base directory and a view name, or just a name as a single value). Uses <code>resolve-generic</code>.</p>
<p>If no view name is given it uses <code>get-view</code> to obtain it from a route data (<code>:app/view</code> key) or to fall back to default.</p>
<p>If view is set to <code>false</code>, explicitly disables using it by returning <code>false</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L464">view source</a></div></div><div class="public anchor" id="var-response"><h3>response</h3><h4 class="type">macro</h4><div class="usage"><code>(response req & code)</code></div><div class="doc"><div class="markdown"><p>Creates a response block. If the given <code>req</code> is already a response then it is simply returned. Otherwise the expressions from <code>code</code> are evaluated.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L144">view source</a></div></div><div class="public anchor" id="var-response-status.3F"><h3>response-status?</h3><div class="usage"><code>(response-status? req k)</code></div><div class="doc"><div class="markdown"><p>Returns <code>true</code> if the response status of the given <code>req</code> is equal to <code>k</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L492">view source</a></div></div><div class="public anchor" id="var-response.3F"><h3>response?</h3><div class="usage"><code>(response? req)</code></div><div class="doc"><div class="markdown"><p>Returns <code>true</code> if the given context map <code>req</code> is a response.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L683">view source</a></div></div><div class="public anchor" id="var-role-required.21"><h3>role-required!</h3><div class="usage"><code>(role-required! req role)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1757">view source</a></div></div><div class="public anchor" id="var-roles-for-context"><h3>roles-for-context</h3><div class="usage"><code>(roles-for-context req user-id context)</code><code>(roles-for-context req context)</code><code>(roles-for-context req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1768">view source</a></div></div><div class="public anchor" id="var-roles-for-contexts"><h3>roles-for-contexts</h3><div class="usage"><code>(roles-for-contexts req user-id)</code><code>(roles-for-contexts req)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1778">view source</a></div></div><div class="public anchor" id="var-roles-keys"><h3>roles-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L54">view source</a></div></div><div class="public anchor" id="var-roles-matrix"><h3>roles-matrix</h3><div class="usage"><code>(roles-matrix req)</code><code>(roles-matrix req opts)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1796">view source</a></div></div><div class="public anchor" id="var-roles-table"><h3>roles-table</h3><div class="usage"><code>(roles-table req)</code><code>(roles-table req opts)</code></div><div class="doc"><div class="markdown"><p>Generates roles table as HTML string.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L121">view source</a></div></div><div class="public anchor" id="var-roles-tabler"><h3>roles-tabler</h3><div class="usage"><code>(roles-tabler req)</code><code>(roles-tabler {{:keys [global-context], :or {global-context :!}} :roles/config, :as req} {:keys [user-id effective? include-global? include-self? present-label missing-label global-label global-marker global-present-label context-label contexts-labeler], :or {present-label "YES", missing-label "—", global-label "global", context-label "Context", contexts-labeler default-contexts-labeler, include-global? (not effective?), include-self? false}, :as opts})</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1840">view source</a></div></div><div class="public anchor" id="var-router-match.3F"><h3>router-match?</h3><div class="usage"><code>(router-match? v)</code></div><div class="doc"><div class="markdown"><p>Returns true if the given argument is Reitit’s Match object.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L101">view source</a></div></div><div class="public anchor" id="var-see-other"><h3>see-other</h3><div class="usage"><code>(see-other)</code><code>(see-other req)</code><code>(see-other url)</code><code>(see-other req url)</code><code>(see-other req name-or-path)</code><code>(see-other req name-or-path path-params)</code><code>(see-other req name-or-path path-params query-params)</code><code>(see-other req name-or-path lang)</code><code>(see-other req name-or-path lang path-params)</code><code>(see-other req name-or-path lang path-params query-params)</code><code>(see-other req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Uses the page function to calculate the destination path on a basis of page name (identifier) or a path (a string) and performs a redirect with code 303 to it using <code>resp/see-other</code>. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1361">view source</a></div></div><div class="public anchor" id="var-session-keys"><h3>session-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L50">view source</a></div></div><div class="public anchor" id="var-set-target-header"><h3>set-target-header</h3><div class="usage"><code>(set-target-header req)</code><code>(set-target-header req target)</code><code>(set-target-header req target replace?)</code></div><div class="doc"><div class="markdown"><p>Sets the <code>HX-Retarget</code> header to a string value of the given <code>target</code> in response headers (under the <code>:response/headers</code> key) of the given <code>req</code> map. If the target is not given, its value is obtained from <code>:app/target</code> of the <code>req</code> or the route data within a request map. Returns updated <code>req</code>.</p>
<p>By default it will not replace existing <code>HX-Retarget</code> header, unless the <code>replace?</code> argument is set to <code>true</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L302">view source</a></div></div><div class="public anchor" id="var-sl-default-html"><h3>sl-default-html</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L374">view source</a></div></div><div class="public anchor" id="var-slash-redir"><h3>slash-redir</h3><div class="usage"><code>(slash-redir req)</code></div><div class="doc"><div class="markdown"><p>Redirects to a slash-trailed version of the same URI. If the URI already has a slash, it returns a req.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1451">view source</a></div></div><div class="public anchor" id="var-soft-lock-passed"><h3>soft-lock-passed</h3><div class="usage"><code>(soft-lock-passed user time)</code></div><div class="doc"><div class="markdown"><p>Returns the time duration between soft lock and the given moment. If the duration is zero or negative, it returns nil.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1480">view source</a></div></div><div class="public anchor" id="var-soft-lock-remains"><h3>soft-lock-remains</h3><div class="usage"><code>(soft-lock-remains lock-passed auth-config-or-lw)</code><code>(soft-lock-remains user auth-config-or-lw time)</code></div><div class="doc"><div class="markdown"><p>Returns the amount of time left before reaching lock-wait. If the amount is negative or zero, it returns nil. Does not connect to a database.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1517">view source</a></div></div><div class="public anchor" id="var-soft-lock-time"><h3>soft-lock-time</h3><div class="usage"><code>(soft-lock-time user)</code></div><div class="doc"><div class="markdown"><p>Gets a soft lock time for the given user specified by a map having :soft-locked key.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1474">view source</a></div></div><div class="public anchor" id="var-soft-locked.3F"><h3>soft-locked?</h3><div class="usage"><code>(soft-locked? lock-passed auth-config-or-lw)</code><code>(soft-locked? user auth-config-or-lw time)</code></div><div class="doc"><div class="markdown"><p>Returns true if the given user account is soft-locked (the time amount which passed from the lock till the given time is lesser than the soft lock wait configuration option). Does not connect to a database.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1503">view source</a></div></div><div class="public anchor" id="var-split-query-params"><h3>split-query-params</h3><div class="usage"><code>(split-query-params path)</code></div><div class="doc"><div class="markdown"><p>Splits path into 3 string components: path, location and query params. Returns a vector.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L289">view source</a></div></div><div class="public anchor" id="var-split-query-params-simple"><h3>split-query-params-simple</h3><div class="usage"><code>(split-query-params-simple path)</code></div><div class="doc"><div class="markdown"><p>Splits path into 2 components: path string and location / query params string. Returns a sequence.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L283">view source</a></div></div><div class="public anchor" id="var-status-lv"><h3>status-lv</h3><div class="usage"><code>(status-lv req)</code><code>(status-lv req status)</code><code>(status-lv req status layout)</code><code>(status-lv req status layout view)</code><code>(status-lv req status layout view route-data)</code></div><div class="doc"><div class="markdown"><p>Sets a different layout and/or view when the given HTTP status (<code>status</code>) is not <code>:ok/found</code> nor <code>:ok</code> nor <code>nil</code> and the <code>:response/set-status!</code> entry of the <code>req</code> does not have a truthy value.</p>
<p>If <code>layout</code> is given and it is not <code>nil</code>, it will not be changed but returned as is. If <code>view</code> is given and it is not <code>nil</code>, it will not be changed but returned as is.</p>
<p>To establish a layout it will check for <code>:status/layouts</code> key in <code>req</code> and then in <code>route-data</code> to obtain a mapping of statuses to layouts. It will then look for an application status (taken from <code>:response/status</code> of the given <code>req</code>) and if that will return <code>nil</code> it will look for an HTTP status <code>status</code> in the same map. If that will fail, it will try <code>:error/layout</code> key of the <code>req</code> and the <code>:error/layout</code> key of the <code>route-data</code>. Finally, it will return a string <code>"error"</code>.</p>
<p>To establish a view it will check for <code>:status/views</code> key in <code>req</code> and then in <code>route-data</code> to obtain a mapping of statuses to views. It will then look for an application status (taken from <code>:response/status</code> of the given <code>req</code>) and if that will return <code>nil</code> it will look for an HTTP status <code>status</code> in the same map. If that will fail, it will try <code>:error/layout</code> key of the <code>req</code> and then <code>:error/layout</code> key of the <code>route-data</code>. Finally, it will return a string <code>"error"</code>.</p>
<p>Returns a 2-element vector in a form of <code>[layout view]</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L548">view source</a></div></div><div class="public anchor" id="var-strictly-localized-page"><h3>strictly-localized-page</h3><div class="usage"><code>(strictly-localized-page req)</code><code>(strictly-localized-page req name-or-path)</code><code>(strictly-localized-page req name-or-path lang)</code><code>(strictly-localized-page req name-or-path lang params)</code><code>(strictly-localized-page req name-or-path lang params query-params)</code><code>(strictly-localized-page name-or-path lang params query-params router lang-param)</code></div><div class="doc"><div class="markdown"><p>Same as <code>localized-page</code> with <code>lang-required?</code> always set to <code>true</code>, <code>name-path-fallback?</code> set to <code>false</code>, and with less arities supported. When the language version of a page identified by its name is not present it will return <code>nil</code>.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L716">view source</a></div></div><div class="public anchor" id="var-template-path"><h3>template-path</h3><div class="usage"><code>(template-path match params)</code><code>(template-path match params query-params)</code><code>(template-path path template params _)</code></div><div class="doc"><div class="markdown"><p>Replaces parameters in the given path using a template.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L348">view source</a></div></div><div class="public anchor" id="var-temporary-redirect"><h3>temporary-redirect</h3><div class="usage"><code>(temporary-redirect)</code><code>(temporary-redirect req)</code><code>(temporary-redirect url)</code><code>(temporary-redirect req url)</code><code>(temporary-redirect req name-or-path)</code><code>(temporary-redirect req name-or-path path-params)</code><code>(temporary-redirect req name-or-path path-params query-params)</code><code>(temporary-redirect req name-or-path lang)</code><code>(temporary-redirect req name-or-path lang path-params)</code><code>(temporary-redirect req name-or-path lang path-params query-params)</code><code>(temporary-redirect req name-or-path lang path-params query-params & more)</code></div><div class="doc"><div class="markdown"><p>Uses the page function to calculate the destination path on a basis of page name (identifier) or a path (a string) and performs a redirect with code 307 to it using <code>resp/temporary-redirect</code>. If the language is given it uses the <code>localized-page</code> function. If there is no language given but the page identified by its name requires a language parameter to be set, it will be obtained from the given request map (under the key <code>:language/str</code>).</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1363">view source</a></div></div><div class="public anchor" id="var-update-app-data"><h3>update-app-data</h3><div class="usage"><code>(update-app-data req)</code><code>(update-app-data req f)</code><code>(update-app-data req f a)</code><code>(update-app-data req f a b)</code><code>(update-app-data req f a b c)</code><code>(update-app-data req f a b c d)</code><code>(update-app-data req f a b c d & more)</code></div><div class="doc"><div class="markdown"><p>Updates the <code>:app/data</code> in a request map <code>req</code> with a result of calling the function <code>f</code> on the previous value and optional arguments. Uses <code>io.randomseed.utils.map/qassoc</code>. Returns updated <code>req</code> with a lazy map under <code>:add/data</code> key. Ensures that the result of calling <code>f</code> is a lazy map and if it is not, tries to convert it to a lazy map (if it is <code>nil</code>). When the current value of <code>:app/data</code> is <code>false</code> it will short-circuit and skip updating.</p>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L222">view source</a></div></div><div class="public anchor" id="var-use-hx.3F"><h3>use-hx?</h3><div class="usage"><code>(use-hx? req)</code><code>(use-hx? req route-data)</code><code>(use-hx? req route-data extra-key)</code></div><div class="doc"><div class="markdown"><p>Returns <code>true</code> if response should be HTMX-compatible, <code>false</code> if it should not. Uses optional <code>route-data</code> or gets it from the <code>req</code> to look for (optional) <code>extra-key</code> first, and if it is not given or has falsy value then gets a value associated with the <code>:use-htmx?</code> key.</p>
<ul>
<li>If the obtained value is <code>false</code>, it will return <code>false</code>.</li>
<li>If the obtained value is <code>true</code> or any non-<code>nil</code> value, it will return <code>true</code>.</li>
<li>If the obtained value is <code>nil</code>, or there is no route data nor any of the mentioned keys can be found in route data, it will try to auto-detect HTMX using <code>hx-request?</code> function which analyzes the <code>HX-Request</code> request header.</li>
</ul>
</div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1136">view source</a></div></div><div class="public anchor" id="var-validators-keys"><h3>validators-keys</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L49">view source</a></div></div><div class="public anchor" id="var-views-str"><h3>views-str</h3><div class="usage"></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/web.clj#L370">view source</a></div></div><div class="public anchor" id="var-with-role-only.21"><h3>with-role-only!</h3><h4 class="type">macro</h4><div class="usage"><code>(with-role-only! req role & body)</code></div><div class="doc"><div class="markdown"></div></div><div class="src-link"><a href="https://github.com/randomseed-io/amelinium/tree/1.0.1/src/amelinium/common.clj#L1763">view source</a></div></div></div></body></html>