Dave Rolsky > Lingua-ZH-CCDICT-0.05 > Lingua::ZH::CCDICT::Romanization::Pinyin

Download:
Lingua-ZH-CCDICT-0.05.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
View/Report Bugs
Source  

NAME ^

Lingua::ZH::CCDICT::Romanization::Pinyin - A pinyin romanization of a Chinese character

SYNOPSIS ^

  print $pinyin->syllable();
  print $pinyin->as_ascii();
  print $pinyin->as_unicode();

DESCRIPTION ^

The Lingua::ZH::CCDICT::Romanization::Pinyin class is used for the return values of the Lingua::ZH::CCDICT::ResultItem class's tongyong method, and provides the following additional methods:

$pinyin->syllable()

This returns the syllable with the tone markings appended as a number at the end, but it may contain a u with an umlaut.

$pinyin->as_ascii()

Returns the syllable as ascii. The tone is appended as a number, and a u with an umlaut is represented as two u's in row.

$pinyin->as_unicode()

The syllable with the tone marking represented as diacritics using Unicode characters.

AUTHOR ^

David Rolsky <autarch@urth.org>

COPYRIGHT ^

Copyright (c) 2002-2007 David Rolsky. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

The full text of the license can be found in the LICENSE file included with this module.

syntax highlighting: