symfony API

sfMessageSource_SQLite Class

You are currently browsing
the website for symfony 1

Visit the Symfony2 website


« Back to API menu

1.4 API OpenSearch

Packages

You are currently browsing the symfony API for the 1.4 version. Switch to:

sfMessageSource_SQLite class.

Inheritence

sfMessageSource_SQLite  <  sfMessageSource_Database < sfMessageSource

Method Summary

  • array &($variant)
    Gets an array of messages for a particular catalogue and cultural variant.
  • array catalogues()
    Returns a list of catalogue as key and all it variants as value.
  • boolean delete($message, $catalogue)
    Deletes a particular message from the specified catalogue.
  • array getCatalogueDetails($catalogue)
    Retrieves catalogue details, array($cat_id, $variant, $count).
  • int getLastModified($source)
    Gets the last modified unix-time for this particular catalogue+variant.
  • boolean isValidSource($variant)
    Checks if a particular catalogue+variant exists in the database.
  • boolean save($catalogue)
    Saves the list of untranslated blocks to the translation source.
  • boolean update($text, $target, $comments, $catalogue)
    Updates the translation.
  • boolean updateCatalogueTime()
    Updates the catalogue last modified time.
  • __construct($source)
    Constructor.

Methods inherited from sfMessageSource_Database

getCatalogueList , getId , parseDSN

Methods inherited from sfMessageSource

& , append , factory , getCache , getCatalogueList , getCulture , getLastModified , getSource , isValidSource , load , read , setCache , setCulture , __construct

Method Details

  • (array) & ($variant) Browse code

    $variant the catalogue name + variant

    Gets an array of messages for a particular catalogue and cultural variant.

    returns translation messages.

  • (array) catalogues () Browse code

    Returns a list of catalogue as key and all it variants as value.

    returns list of catalogues

  • (boolean) delete ($message, $catalogue) Browse code

    $message the source message to delete.
    $catalogue the catalogue to delete from.

    Deletes a particular message from the specified catalogue.

    returns true if deleted, false otherwise.

  • (array) getCatalogueDetails ($catalogue) Browse code

    $catalogue catalogue

    Retrieves catalogue details, array($cat_id, $variant, $count).

    returns catalogue details, array($cat_id, $variant, $count).

  • (int) getLastModified ($source) Browse code

    $source catalogue+variant

    Gets the last modified unix-time for this particular catalogue+variant.

    We need to query the database to get the date_modified.

    returns last modified in unix-time format.

  • (boolean) isValidSource ($variant) Browse code

    $variant catalogue+variant

    Checks if a particular catalogue+variant exists in the database.

    returns true if the catalogue+variant is in the database, false otherwise.

  • (boolean) save ($catalogue) Browse code

    $catalogue the catalogue to add to

    Saves the list of untranslated blocks to the translation source.

    If the translation was not found, you should add those
    strings to the translation source via the append() method.

    returns true if saved successfuly, false otherwise.

  • (boolean) update ($text, $target, $comments, $catalogue) Browse code

    $text the source string.
    $target the new translation string.
    $comments comments
    $catalogue the catalogue of the translation.

    Updates the translation.

    returns true if translation was updated, false otherwise.

  • (boolean) updateCatalogueTime () Browse code

    Updates the catalogue last modified time.

    returns true if updated, false otherwise.

  • __construct ($source) Browse code

    $source SQLite datasource, in PEAR's DB DSN format.

    Constructor.

    Creates a new message source using SQLite.