lang::catalog::get_catalog_file_path (private)
lang::catalog::get_catalog_file_path \ [ -backup_from_version backup_from_version ] \ [ -backup_to_version backup_to_version ] -package_key package_key \ -locale locale [ -charset charset ]
Defined in packages/acs-lang/tcl/lang-catalog-procs.tcl
Get the full path of the catalog file for a given package, and locale.
- Switches:
- -backup_from_version (optional)
- -backup_to_version (optional)
- -package_key (required)
- -locale (required)
- -charset (optional)
- Should normally not be provided. Will force the charset to a certain value. If not provided an appropriate charset to write the locale in will be used.
- Author:
- Peter Marklund
- See Also:
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: set catalog_dir [package_catalog_dir $package_key] if { $charset ne "" } { set file_charset $charset } else { # We had problems storing digits in ISO-8859-6 so we decided # to use UTF-8 for all files except for locales that use ISO-8859-1. The reason we are making # ISO-8859-1 an exception is that some developers may make the shortcut of editing # the en_US catalog files directly to add keys and they might mess up the # utf-8 encoding of the files when doing so. set system_charset [lang::util::charset_for_locale $locale] set file_charset [expr {$system_charset eq "ISO-8859-1" ? $system_charset : "utf-8"}] } set message_backup_prefix "" if { $backup_from_version ne "" } { set message_backup_prefix "[message_backup_file_prefix]${backup_from_version}-${backup_to_version}_" } set filename "${message_backup_prefix}${package_key}.${locale}.${file_charset}.xml" set file_path "[package_catalog_dir $package_key]/$filename" return $file_pathGeneric XQL file: packages/acs-lang/tcl/lang-catalog-procs.xql
PostgreSQL XQL file: packages/acs-lang/tcl/lang-catalog-procs-postgresql.xql
Oracle XQL file: packages/acs-lang/tcl/lang-catalog-procs-oracle.xql