28#ifndef PROTOCORE_HTTPCACHE_H
29#define PROTOCORE_HTTPCACHE_H
33#if PROTOCORE_ENABLE_HTTP_CACHE
48typedef struct protocore_cache_control
65 int32_t stale_while_revalidate;
66 int32_t stale_if_error;
69} protocore_cache_control;
74 protocore_cache_control *cc;
75} HttpcacheControlInitArgs;
82 const protocore_cache_control *cc;
83} HttpcacheControlBuildArgs;
90 protocore_cache_control *cc;
91} HttpcacheControlParseArgs;
96 protocore_cache_control *cc;
98} HttpcacheImmutableAssetArgs;
103 protocore_cache_control *cc;
105 int32_t stale_while_revalidate;
106} HttpcacheRevalidatableArgs;
111 protocore_cache_control *cc;
112} HttpcacheNoStoreArgs;
117 protocore_cache_control *cc;
120} HttpcacheSharedArgs;
125 const protocore_cache_control *cc;
127 long expires_minus_date;
128} HttpcacheFreshnessLifetimeArgs;
165 HttpcacheControlInitArgs control_init_args;
166 HttpcacheControlBuildArgs control_build_args;
167 HttpcacheControlParseArgs control_parse_args;
168 HttpcacheImmutableAssetArgs immutable_asset_args;
169 HttpcacheRevalidatableArgs revalidatable_args;
170 HttpcacheNoStoreArgs no_store_args;
171 HttpcacheSharedArgs shared_args;
172 HttpcacheFreshnessLifetimeArgs freshness_lifetime_args;
179extern HttpcacheVars HttpcacheV;
184 void (*
const control_init)(uint8_t *work);
185 void (*
const control_build)(uint8_t *work);
186 void (*
const control_parse)(uint8_t *work);
187 void (*
const immutable_asset)(uint8_t *work);
188 void (*
const revalidatable)(uint8_t *work);
189 void (*
const no_store)(uint8_t *work);
190 void (*
const shared)(uint8_t *work);
191 void (*
const freshness_lifetime)(uint8_t *work);
196void protocore_httpcache_control_init(uint8_t *work);
197void protocore_httpcache_control_build(uint8_t *work);
198void protocore_httpcache_control_parse(uint8_t *work);
199void protocore_httpcache_immutable_asset(uint8_t *work);
200void protocore_httpcache_revalidatable(uint8_t *work);
201void protocore_httpcache_no_store(uint8_t *work);
202void protocore_httpcache_shared(uint8_t *work);
203void protocore_httpcache_freshness_lifetime(uint8_t *work);
209static const HttpcacheNs Httpcache __attribute__((unused)) = {
210 .control_init = protocore_httpcache_control_init,
211 .control_build = protocore_httpcache_control_build,
212 .control_parse = protocore_httpcache_control_parse,
213 .immutable_asset = protocore_httpcache_immutable_asset,
214 .revalidatable = protocore_httpcache_revalidatable,
215 .no_store = protocore_httpcache_no_store,
216 .shared = protocore_httpcache_shared,
217 .freshness_lifetime = protocore_httpcache_freshness_lifetime,
#define PROTOCORE_BEGIN_DECLS
Give a header's declarations C linkage, so their symbol names carry no parameter types.
_Bool proto_bool
The truth value.
#define PROTOCORE_END_DECLS