Package org.gedcom4j.model

Examples of org.gedcom4j.model.PersonalNameVariation


        pn.basic = "Bj\u00F8rn /J\u00F8orgen/";

        rootValidator.validate();
        assertNoIssues();

        PersonalNameVariation romanized = new PersonalNameVariation();
        pn.romanized.add(romanized);
        romanized.givenName = new StringWithCustomTags("Bjorn");
        romanized.surname = new StringWithCustomTags("Jorgen");
        rootValidator.validate();
        assertFindingsContain(Severity.ERROR, "variation", "name", "required");
        romanized.variation = "Bjorn /Jorgen/";
        rootValidator.validate();
        assertNoIssues();

        PersonalNameVariation phonetic = new PersonalNameVariation();
        pn.phonetic.add(phonetic);
        phonetic.givenName = new StringWithCustomTags("Byorn");
        phonetic.surname = new StringWithCustomTags("Yorgen");
        rootValidator.validate();
        assertFindingsContain(Severity.ERROR, "variation", "name", "required");
View Full Code Here


        }
        if (!(nv instanceof PersonalNameVariation)) {
            addError("Name variation on person is not a PersonalNameVariation");
            return;
        }
        PersonalNameVariation pnv = (PersonalNameVariation) nv;
        if (pnv.citations == null) {
            if (rootValidator.autorepair) {
                pnv.citations = new ArrayList<AbstractCitation>();
                addInfo("citations collection for personal name was null - autorepaired", pnv);
            } else {
View Full Code Here

            } else {
                rootValidator.addError("Event has null list of phonetic name variations", pn);
            }
        } else {
            for (NameVariation nv : pn.phonetic) {
                PersonalNameVariation pnv = (PersonalNameVariation) nv;
                new PersonalNameVariationValidator(rootValidator, pnv).validate();
            }
        }

        if (pn.romanized == null) {
            if (rootValidator.autorepair) {
                pn.romanized = new ArrayList<PersonalNameVariation>();
                rootValidator.addInfo("Event had null list of romanized name variations - repaired", pn);
            } else {
                rootValidator.addError("Event has null list of romanized name variations", pn);
            }
        } else {
            for (NameVariation nv : pn.romanized) {
                PersonalNameVariation pnv = (PersonalNameVariation) nv;
                new PersonalNameVariationValidator(rootValidator, pnv).validate();
            }
        }
    }
View Full Code Here

TOP

Related Classes of org.gedcom4j.model.PersonalNameVariation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.