Bric::Util::CharTrans - Interface to Bricolage UTF-8 Character Translations $LastChangedRevision$ $LastChangedDate: 2005-10-05 00:22:53 +0200 (Wed, 05 Oct 2005) $ # Constructors. my $chartrans = Bric::Util::CharTrans->new('iso-8859-1'); # Instance Methods. my $charset = $chartrans->charset; my $charset = $chartrans->charset('iso-8859-1'); # (note: this is only in-place now -- it used to also return the string) $chartrans->to_utf8(\$some_data); $chartrans->from_utf8(\$some_data); Bric::Util::CharTrans provides an object-oriented interface to conversion of characters from a target character set to Unicode UTF-8 and from Unicode UTF-8 to a target character set.

Constructors
Throws: Unspecified charset Unknown charset Side Effects: Notes: Use new() to get a working CharTrans object.

Public Class Methods
None.

Public Instance Methods
Gets the current target character set in use. Optionally sets the current character set. Throws: NONE. Side Effects: NONE. Notes: NONE. Performs an in-place conversion of the data in $somedata from the character set specified via "charset()" to UTF-8. References to SCALARs, ARRAYs, and HASHes will be recursively processed and their data replaced. Throws: Side Effects: NONE. Notes: This used to return the converted string, but it doesn't any more. Instead, it returns the Bric::Util::CharTrans object itself. Performs an in-place conversion of the UTF-8 data in $utf8_text to the character set specified via "charset()". References to SCALARs, ARRAYs, and HASHes will be recursively processed and their data replaced. Throws: Side Effects: NONE. Notes: This used to return the converted string, but it doesn't any more. Instead, it returns the Bric::Util::CharTrans object itself.