### Class

# Shumate FileCache

#### Description [src]

    final class Shumate.FileCache : GObject.Object
    {
      /* No available fields */
    }

A cache that stores and retrieves tiles from the file system. It is mainly used by `ShumateTileDownloader`, but can also be used by custom data sources.

The cache will be filled up to a certain size limit. When this limit is reached, the cache can be purged, and the tiles that are accessed least are deleted.

## ETags

The cache can optionally store an ETag string with each tile. This is useful to avoid redownloading old tiles that haven’t changed (for example, using the HTTP If-None-Match header).

#### Hierarchy

#### Ancestors

- GObject

#### Constructors

###### shumate_file_cache_new_full

Constructor of `ShumateFileCache`.

#### Instance methods

###### shumate_file_cache_get_cache_dir

Gets the directory where the cache database is stored.

###### shumate_file_cache_get_cache_key

Gets the key used to store and retrieve tiles from the cache. Different keys can be used to store multiple tilesets in the same cache directory.

###### shumate_file_cache_get_size_limit

Gets the cache size limit in bytes.

###### shumate_file_cache_get_tile_async

Gets tile data from the cache, if it is available.

###### shumate_file_cache_get_tile_finish

Gets the tile data from a completed `shumate_file_cache_get_tile_async()` operation.

###### shumate_file_cache_mark_up_to_date

Marks a tile in the cache as being up to date, without changing its data.

###### shumate_file_cache_purge_cache_async

Removes less used tiles from the cache, if necessary, until it fits in the size limit.

###### shumate_file_cache_purge_cache_finish

Gets the result of an async operation started using shumate_file_cache_purge_cache_async().

###### shumate_file_cache_set_size_limit

Sets the cache size limit in bytes.

###### shumate_file_cache_store_tile_async

Stores a tile in the cache.

###### shumate_file_cache_store_tile_finish

Gets the success value of a completed `shumate_file_cache_store_tile_async()` operation.

##### Methods inherited from GObject (43)

Please see GObject for a full list of methods.

#### Properties

###### Shumate.FileCache:cache-dir

The directory where the tile database is stored.

###### Shumate.FileCache:cache-key

The key used to store and retrieve tiles from the cache. Different keys can be used to store multiple tilesets in the same cache directory.

###### Shumate.FileCache:size-limit

The cache size limit in bytes.

#### Signals

##### Signals inherited from GObject (1)

###### GObject::notify

The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.

#### Class structure

    struct ShumateFileCacheClass {
      GObjectClass parent_class;

    }

No description available.

###### Class members

`parent_class: GObjectClass`

  No description available.