Lingua-Translit

 view release on metacpan or  search on metacpan

xml/bgn-pcgn_rus_strict.xml  view on Meta::CPAN

               before а, у, ы, э
             ы -> ·y
               after vowel characters а, е, ё, и, о, у, ы, э, ю, я
                 (these cases are called "unusual Russian character
                 sequences", and are expected mainly in words of
                 non-Russian origin)
             Ñ‹ -> y
               in all other instances
        -->
        <rule>
            <from>Ñ‹</from>
            <to>y·</to>
            <context>
                <!-- capitals А, У, Ы, Э are already transliterated to
                     'A', 'U', '·Y', 'Y·', 'Y', '·E' and 'E'; some й are
                     converted to 'y·' -->
                <before>[AUYE·ауыэ]</before>
            </context>
        </rule>

        <rule>
            <from>Ñ‹</from>
            <to>·y</to>
            <context>
                <!-- vowel characters in uppercase (А, Е, Ё, И, О, У, Ы, Э,
                     Ю, Я) are transliterated to 'A', 'E', 'Ye', 'Ë', 'Yë',
                     'I', 'O', 'U', '·Y', 'Y·', 'Y', '·E', 'E', 'Yu', 'Ya';
                     й became 'y', and some ы already became '·y';
                     е and ё became 'e', 'ye', 'ë' and 'yë';
                     however, we don't include an interpunct character in this
                     context in order to avoid a duplication -->
                <after>[AEËIOUYaueëyаеёиоуыэюя]</after>
            </context>
        </rule>

        <rule>
            <from>Ñ‹</from>
            <to>y</to>
        </rule>

        <!--
             э -> ·e
               after any consonant character except й
                 (these cases are called "unusual Russian character
                 sequences", and are expected mainly in words of
                 non-Russian origin)
             э -> e
               in all other instances

             A note: according to the rules, э should not be
             transliterated as '·e' after й; however, й should be
             transliterated as 'y·' before э, so an interpunct character
             appears anyway when one transliterates Йэ/йэ.
        -->
        <rule>
            <from>э</from>
            <to>·e</to>
            <context>
                <!-- capitals are already transliterated;
                     lowercase letters 'h', 'c' and 's' appear in
                     transliterations of Ж, Ш, Ц, Ч, Щ, Х, ТС/Тс
                     and ШЧ/Шч -->
                <after>[BVGDZhKLMNPRSTsFCScбвгджзклмнпрстфхцчшщ]</after>
            </context>
        </rule>

        <rule>
            <from>э</from>
            <to>e</to>
        </rule>

        <!--
            Then, we proceed to characters whose context doesn't depend
            on other characters.
        -->

        <rule>
            <from>а</from>
            <to>a</to>
        </rule>

        <rule>
            <from>б</from>
            <to>b</to>
        </rule>

        <rule>
            <from>в</from>
            <to>v</to>
        </rule>

        <rule>
            <from>г</from>
            <to>g</to>
        </rule>

        <rule>
            <from>д</from>
            <to>d</to>
        </rule>

        <rule>
            <from>ж</from>
            <to>zh</to>
        </rule>

        <rule>
            <from>з</from>
            <to>z</to>
        </rule>

        <rule>
            <from>и</from>
            <to>i</to>
        </rule>

        <rule>
            <from>к</from>
            <to>k</to>
        </rule>



( run in 0.400 second using v1.01-cache-2.11-cpan-d7a12ab2c7f )