Client cache service - exampleΒΆ
Since Sculptor version |
In this example we just open a KfServer remote file defining the use of a CACHE_ALL and CACHE_SHARED cache:
!include <sculptor.h>
-database dbClientCache {
!file FILE "filename"
}
. Define the FILE accesed through KfServer in a remote server_name and server_path directrory
dbClientCache->type = DBT_SCULPTOR
dbClientCache->source = "server_name:/server_path"
. Define the !file cache attributes (Shared all cache check for a refresh every 10 seconds)
FILE->cache_option = CACHE_ALL | CACHE_SHARED
FILE->cache_auto_refresh = 10
. Open the datbase and !file
opendb dbClientCache
openfile FILE name="filename" update
. Use the file normally
...
readu FILE
...
RELATED TOPICS |