Client cache service - File attributes¶
Since Sculptor version |
New attributes have been added to the ![o]file to activate and configure the client cache for that specific file.
cache_option attribute¶
file_id->cache_option = CACHE_OFF|CACHE_ACCESS|CACHE_ALL|CACHE_SHARED
Defines how the file is cached (it can even work with local files). Defined in sculptor.h:
CACHE_OFF: Means the file is not going to be cached (default value)
CACHE_ACCESS: Means only the accessed records are saved on the cache
CACHE_ALL: Means the entire file is copied to the cache when opened
CACHE_SHARED: Must be set with CACHE_ACCESS or CACHE_ALL. Means the cache is shared between clients. See shared cache.
cache_auto_refresh attribute¶
file_id->cache_auto_refresh = secs
Defines the refresh “policy”:
0: Means the file must be refreshed manually (not refreshed otherwise). This is the default behaviour if not specified.
>0: a number of seconds to check if refresh is needed, invalidating the cache data in case the refresh is needed.
RELATED TOPICS |