Home

Awesome

Iuliia

Transliterate Cyrillic → Latin in every possible way

Transliteration means representing Cyrillic data (mainly names and geographic locations) with Latin letters. It is used for international passports, visas, green cards, driving licenses, mail and goods delivery etc.

Why use Iuliia

For schema details and other information, see https://dangry.ru/iuliia (in Russian).

Requirements

Installation

Maven dependency (works fine with maven 3.6.3)

<!-- https://mvnrepository.com/artifact/com.github.radist-nt/iuliia-java -->
<dependency>
    <groupId>com.github.radist-nt</groupId>
    <artifactId>iuliia-java</artifactId>
    <version>0.1.3</version>
</dependency>

Usage

Simple example:

import com.radist_nt.iuliia.Iuliia;

public class Clazz {
    public static void test() {
        Iuliia.transliterate("Юлия", Iuliia.ICAO_DOC_9303); //Iuliia
    }
}

Advanced usage example:

import com.radist_nt.iuliia.Iuliia;
import com.radist_nt.iuliia.Transliterator;

public class Clazz {
    private static final Transliterator ICAO_DOC_9303 = Iuliia.withSchema(Iuliia.ICAO_DOC_9303);
    public static void test() {
        ICAO_DOC_9303.transliterate("Юлия"); //Iuliia
    }
}

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Make sure to add or update tests as appropriate.

Test "testConstants" could fail after adding new transliteration schemas in https://github.com/nalgeon/iuliia. To make it pass, temporary enable the test "generateIuliiaConstants" and run mvn test. Reformat code before commiting (using built-in eclipse formatting settings).

License

MIT