The PCLT package

[ Tags: deprecated, lgpl, library, text ] [ Propose Tags ]

"PCLT" is an abbreviation for "Parametric Composable Localizable Templates" - in fact it should also hold Detalizable. Term "Detailizable content (message)" in this package has a following meaning: some content, representing which it is possible to regulate, in how much details it is represented.

Conceptually, this package is a powerful extension to the well known Show class, that (extension) is thought to be embeded in any Haskell program, which requires multilanguage support, and/or where messages should be detailizable.

The PCLT catalog consists of:

Each catalog entry (localizable template) consists of

Each localized template is a sequence of chunks:

To make a message one needs to specify

The last two fields (localizable template ID + a map of parameters together with their values) is called instaniation (of templated message). In the program it wrapped in a PCSI data type.

A parameter value may be

This package comes together with another one - a dependent package PCLT-DB (section Database), which provides

IMPORTANT!!! : It is highly recommended to use ISO 639(3) standard for language names, since PCLT-DB package is oriented on 3 letters (not bigger) language names. Without modifications PCLT-DB won't work for bigger (then 3-letters) names.

ToDo considerations for the next versions:

  1. Consider using state monad in order to put catalog into an implicit context... and maybe also other uses if monads.

  2. Rewrite MakeCatalog, so that it uses CatalogMaths functions. Otherwise the both modules do similar work, and keeping double code is a bad style.

  3. Introduction of a new parameter value type: "reparsable" wrapping for parameter value.

  4. CatalogMaths extension.

  5. Enchance required SDLs with min & max functions.

  6. Sacrificing ldtSubcompositesMap of LocalizedTemplate, which initially was introduced to enchance speed of messages generation, in favor of making catalogs easier to modify (which curently isn't supported and isn't an easy task).


Versions 0.1
Dependencies base (==4.*), bytestring, containers, mtl, utf8-string [details]
License LGPL
Copyright Copyright (c) 2009 Andrejs Sisojevs
Author Andrejs Sisojevs <>
Maintainer Andrejs Sisojevs <>
Category Text
Home page
Uploaded Sat Dec 12 01:04:15 UTC 2009 by AndreySisoyev
Distributions NixOS:0.1
Downloads 449 total (3 in the last 30 days)
Rating 0.0 (0 ratings) [clear rating]
  • λ
  • λ
  • λ
Status Docs uploaded by user
Build status unknown [no reports yet]
Hackage Matrix CI




Maintainer's Corner

For package maintainers and hackage trustees