symfony API

sfMessageCache Class

You are currently browsing
the website for symfony 1

Visit the Symfony2 website


« Back to API menu

Packages

You are currently browsing the symfony API for the 1.0 version. Switch to:
This version of symfony is not maintained anymore.
If some of your projects still use this version, consider upgrading as soon as possible.

Cache the translation table into the file system.

Method Summary

  • clean($catalogue, $culture)
    Cleans up the cache for the specified section and locale.
  • clear()
    Flushes the cache. Deletes all the cache files.
  • mixed get($catalogue, $culture, $filename)
    Gets the data from the cache.
  • getGroup($catalogue, $culture)
    Gets the cache file GROUP based section and locale.
  • getID($catalogue, $culture)
    Gets the cache file ID based section and locale.
  • int getLifeTime()
    Gets the cache life time.
  • initialize($cacheDir)
    Creates a new Translation cache.
  • save($data, $catalogue, $culture)
    Saves the data to cache for the specified section and locale.
  • setLifeTime($time)
    Sets the cache life time.

Method Details

  • clean ($catalogue, $culture)

    $catalogue The translation section.
    $culture The translation locale, e.g. "en_AU".

    Cleans up the cache for the specified section and locale.

  • clear ()

    Flushes the cache. Deletes all the cache files.

  • (mixed) get ($catalogue, $culture, $filename)

    $catalogue The translation section.
    $culture The translation locale, e.g. "en_AU".
    $filename If the source is a file, this file's modified time is newer than the cache's modified time, no cache hit.

    Gets the data from the cache.

    returns Boolean FALSE if no cache hit. Otherwise, translation table data for the specified section and locale.

  • getGroup ($catalogue, $culture)

    $catalogue The translation section.
    $culture The translation locale, e.g. "en_AU".

    Gets the cache file GROUP based section and locale.

  • getID ($catalogue, $culture)

    $catalogue The translation section.
    $culture The translation locale, e.g. "en_AU".

    Gets the cache file ID based section and locale.

  • (int) getLifeTime ()

    Gets the cache life time.

    returns Cache life time.

  • initialize ($cacheDir)

    $cacheDir Directory to store the cache files.

    Creates a new Translation cache.

  • save ($data, $catalogue, $culture)

    $data The data to save.
    $catalogue The translation section.
    $culture The translation locale, e.g. "en_AU".

    Saves the data to cache for the specified section and locale.

  • setLifeTime ($time)

    $time Cache life time.

    Sets the cache life time.