Search in sources :

Example 1 with ConceptBuilder

use of org.openmrs.module.metadatadeploy.builder.ConceptBuilder in project openmrs-module-pihcore by PIH.

the class AdministrativeConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    Concept freeTextGeneral = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.FREE_TEXT_GENERAL);
    Concept nurse = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.NURSE);
    Concept doctor = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.DOCTOR);
    Concept communityHealthWorker = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.COMMUNITY_HEALTH_WORKER);
    Concept otherNonCoded = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.OTHER_NON_CODED);
    Concept yes = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.YES);
    Concept no = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.NO);
    Concept titleWhoCompletedForm = install(new ConceptBuilder("162577AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(coded).conceptClass(question).name("126197BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Title of who completed form", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("126196BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Form completed by", Locale.ENGLISH, null).mapping(new ConceptMapBuilder("19191dac-4035-4b8f-9f4b-9330e01d3d9c").type(sameAs).ensureTerm(pih, "9720").build()).mapping(new ConceptMapBuilder("56235ed7-80f2-4965-bfb1-b935d45c0f1a").type(sameAs).ensureTerm(pih, "TITLE WHO COMPLETED FORM").build()).mapping(new ConceptMapBuilder("277833ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162577").build()).answers(nurse, doctor, communityHealthWorker, otherNonCoded).build());
    install(new ConceptBuilder("162581AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(convSet).name("126203BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Title of who completed form detail", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("33edea2b-a1a1-48f5-9055-8582cd72a931").type(sameAs).ensureTerm(pih, "9722").build()).mapping(new ConceptMapBuilder("277841ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162581").build()).setMembers(titleWhoCompletedForm, freeTextGeneral).build());
    install(new ConceptBuilder(Concepts.ID_CARD_PRINTING_REQUESTED).datatype(coded).conceptClass(question).name("3fe8bbf9-e9f6-11e4-a8a3-54ee7513a7ff", "ID Card Printing Requested", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).answers(yes, no).mapping(new ConceptMapBuilder("df6b97bc-e9f6-11e4-a8a3-54ee7513a7ff").type(sameAs).ensureTerm(pih, "ID Card Printing Requested").build()).build());
    // TODO: Concept named PrintingIDCardStatus on zanmi / lacolline / mirebalais exists. It wasn't really preferred to use this for a few reasons:
    // * It does not have a consistent UUID between servers (it is set up at runtime at first use, and UUID is not a constant)
    // * It does not have the appropriate data type, and stores values as value_text true/false rather than as coded values
    // * We should migrate the existing functionality to use this concept
    install(new ConceptBuilder(Concepts.ID_CARD_PRINTING_SUCCESSFUL).datatype(coded).conceptClass(question).name("590d36df-ee77-11e4-a257-54ee7513a7ff", "ID Card Printing Successful", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).answers(yes, no).mapping(new ConceptMapBuilder("5fc65369-ee77-11e4-a257-54ee7513a7ff").type(sameAs).ensureTerm(pih, "ID Card Printing Successful").build()).build());
}
Also used : Concept(org.openmrs.Concept) ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Example 2 with ConceptBuilder

use of org.openmrs.module.metadatadeploy.builder.ConceptBuilder in project openmrs-module-pihcore by PIH.

the class AnswerConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    install(new ConceptBuilder(Concepts.NURSE).datatype(notApplicable).conceptClass(misc).name("1848BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Nurse", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("1849BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Infirmière", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("1437FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "Trained nurse personnel", Locale.ENGLISH).mapping(new ConceptMapBuilder("8f123093-5759-45aa-b96f-f7d66402f995").type(sameAs).ensureTerm(pih, "9718").build()).mapping(new ConceptMapBuilder("414cf5b2-4de1-4c00-ad0f-398aa5dcb84b").type(sameAs).ensureTerm(pih, "NURSE").build()).mapping(new ConceptMapBuilder("aad6252d-b190-4a03-8c84-7402a40fc63d").type(sameAs).ensureTerm(ciel, "1577").build()).mapping(new ConceptMapBuilder("136285ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "106292003").build()).mapping(new ConceptMapBuilder("256d1c2a-4556-4e19-8954-995b841e694c").type(sameAs).ensureTerm(ampath, "6280").build()).build());
    install(new ConceptBuilder(Concepts.DOCTOR).datatype(notApplicable).conceptClass(misc).name("107418BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Doctor", Locale.ENGLISH, // locale-preferred
    null).name("1844BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CLINICAL OFFICER/DOCTOR", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("107417BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Physician", Locale.ENGLISH, null).name("611d795d-6b27-4d26-8c61-af4a78b8388b", "Médecin", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("1435FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "Physician, doctor or clinical officer", Locale.ENGLISH).mapping(new ConceptMapBuilder("4d1beffe-760b-4440-9a1b-54dc27200232").type(sameAs).ensureTerm(pih, "DOCTOR").build()).mapping(new ConceptMapBuilder("022890d2-b180-4680-950f-23f3825f9c91").type(sameAs).ensureTerm(pih, "9719").build()).mapping(new ConceptMapBuilder("f086820a-fe21-47e4-9e3c-719f179e46ea").type(sameAs).ensureTerm(ciel, "1574").build()).mapping(new ConceptMapBuilder("136911ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "309343006").build()).mapping(new ConceptMapBuilder("135312ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "5082").build()).mapping(new ConceptMapBuilder("135655ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "5506").build()).build());
    install(new ConceptBuilder(Concepts.COMMUNITY_HEALTH_WORKER).datatype(notApplicable).conceptClass(misc).name("0b785ea4-15f5-102d-96e4-000c29c2a5d7", "Village Health Worker", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("1819BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Community Health Care Worker", Locale.ENGLISH, null).name("126198BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CCHA (Community and Clinical Health Assistant)", Locale.ENGLISH, null).name("99967BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "VHW (Village Health Worker)", Locale.ENGLISH, null).name("89434BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CHEW (Community Health Extension Worker)", Locale.ENGLISH, null).name("107416BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CHO (Community Health Officer)", Locale.ENGLISH, null).name("89567BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CHW (Community Health Worker)", Locale.ENGLISH, null).name("107415BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CHN (Community Health Nurse)", Locale.ENGLISH, null).name("7049249e-6ade-4743-a33d-fb3f6d4b33cd", "Accompagnateur", Locale.FRENCH, // locale-preferred
    null).name("1820BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Officier de Santé du Village", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("137476ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(snomedNp, "223366009").build()).mapping(new ConceptMapBuilder("3b9816c5-9bd3-441c-a453-5912baf4cfcc").type(sameAs).ensureTerm(ciel, "1555").build()).mapping(new ConceptMapBuilder("b25f6544-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "3645").build()).mapping(new ConceptMapBuilder("4c10c0b5-ca8e-4b5f-87a4-3142a269929e").type(sameAs).ensureTerm(ampath, "1862").build()).mapping(new ConceptMapBuilder("75a0ac8c-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "VILLAGE HEALTH WORKER").build()).mapping(new ConceptMapBuilder("141538ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedMvp, "15551000105005").build()).build());
    install(new ConceptBuilder(Concepts.HOME).datatype(notApplicable).conceptClass(misc).name("9880d702-6a5a-11e2-b6f9-aa00f871a3e1", "Home", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("44c1416d-4de3-4cb6-8ff2-af7b5cba366a", "Domicile", Locale.FRENCH, // locale-preferred
    null).name("f358b82d-631b-49b4-be8e-577d345de149", "Sortie par la maison", Locale.FRENCH, // TODO sketchy translation
    ConceptNameType.FULLY_SPECIFIED).name("cd429b94-7bb0-4edd-a746-f83f682729ee", "Lakay", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("988417fa-6a5a-11e2-b6f9-aa00f871a3e1").type(sameAs).ensureTerm(pih, "Home").build()).mapping(new ConceptMapBuilder("98843e1a-6a5a-11e2-b6f9-aa00f871a3e1").type(sameAs).ensureTerm(pih, "7889").build()).build());
    install(new ConceptBuilder(Concepts.HOSPITAL).datatype(notApplicable).conceptClass(misc).name("3e215a0a-26fe-102b-80cb-0017a47871b2", "Hospital", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("dbd54ca7-747c-485e-b27b-91bdc50cf0bf", "Hôpital", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecef53c0-07fe-102c-b5fa-0017a47871b2", "hospital", Locale.ENGLISH).mapping(new ConceptMapBuilder("75826862-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "HOSPITAL").build()).mapping(new ConceptMapBuilder("b21fb656-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2070").build()).build());
    install(new ConceptBuilder(Concepts.OUTSIDE_OF_INSTITUTION).datatype(notApplicable).conceptClass(misc).name("f3bbedb4-91b0-46de-a166-456a6502acda", "Outside of institution", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("d8311920-93a7-4ddf-aa4c-8211451f5d87", "Not in the hospital", Locale.ENGLISH, null).name("da62bffc-ae71-4d3d-817a-05c08f5f119b", "Extra institutionnel", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("0b7bd483-895b-42c6-8b1b-e282a9329ba0", "Not within the hospital, health center, or institution", Locale.ENGLISH).mapping(new ConceptMapBuilder("3e83d428-773c-4285-abf3-d52979752048").type(sameAs).ensureTerm(pih, "Outside of institution").build()).mapping(new ConceptMapBuilder("3001f390-94ca-49ba-88d3-3e4101fd29eb").type(sameAs).ensureTerm(pih, "9670").build()).build());
    install(new ConceptBuilder(Concepts.FAMILY_MEMBER).datatype(notApplicable).conceptClass(misc).name("0b95af4a-15f5-102d-96e4-000c29c2a5d7", "Family member", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b95b044-15f5-102d-96e4-000c29c2a5d7", "FAMILY REPRESENTATIVE", Locale.ENGLISH, null).name("0b95b134-15f5-102d-96e4-000c29c2a5d7", "PERSON RELATED TO PATIENT", Locale.ENGLISH, null).name("0753fb31-7dcc-4d79-ae5e-129ee80cb071", "Membre de la famille", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("69566475-e2d7-4c93-8756-2da07ca672a4", "Manm nan fanmi an", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("229dde7e-60c8-4bad-a80f-4cd77fda4bc9", "A member of the family or someone who can represent the family", Locale.ENGLISH).mapping(new ConceptMapBuilder("75af7b7c-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FAMILY MEMBER").build()).mapping(new ConceptMapBuilder("b2af2854-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "6441").build()).mapping(new ConceptMapBuilder("1e90497e-d591-11e4-9dcf-b36e1005e77b").type(sameAs).ensureTerm(snomedCt, "303071001").build()).build());
    install(new ConceptBuilder(Concepts.POLICE).datatype(notApplicable).conceptClass(misc).name("8281322d-5616-4cc4-8439-092a5388105d", "Police", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("993d6ce0-699a-4f16-8218-099b2effe4a9", "Police", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("54bc35fb-adaf-4d03-b471-fe9d286b8016", "A police force is a constituted body of persons empowered by the state to enforce the law, protect property, and limit civil disorder.", Locale.ENGLISH).mapping(new ConceptMapBuilder("e932f7a2-87d1-4caa-beda-5b66725a172b").type(sameAs).ensureTerm(pih, "Police").build()).mapping(new ConceptMapBuilder("9d91a9bd-90e9-411f-a996-0b007d96024f").type(sameAs).ensureTerm(pih, "9674").build()).build());
    install(new ConceptBuilder(Concepts.SURGERY).datatype(notApplicable).conceptClass(misc).name("0b928a22-15f5-102d-96e4-000c29c2a5d7", "Surgery", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b940cd0-15f5-102d-96e4-000c29c2a5d7", "Chirurgie", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ebff68ec-d039-4bc1-83da-2d99d1924972", "An act of performing surgery may be called a surgical procedure, operation, or simply surgery. In this context, the verb operate means performing surgery.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b2ae45e2-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "6298").build()).mapping(new ConceptMapBuilder("992f5fec-50ab-4db2-a9db-a7935ebe8289").type(sameAs).ensureTerm(pih, "SURGERY").build()).build());
    install(new ConceptBuilder(Concepts.FATHER).datatype(notApplicable).conceptClass(misc).name("3e2259b4-26fe-102b-80cb-0017a47871b2", "Father", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("f672d7ee-d5db-102d-ad2a-000c29c2a5d7", "Père", Locale.FRENCH, // locale-preferred
    null).description("ecf0be2c-07fe-102c-b5fa-0017a47871b2", "A father to another person", Locale.ENGLISH).mapping(new ConceptMapBuilder("b220bc86-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2174").build()).mapping(new ConceptMapBuilder("7587049e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FATHER").build()).mapping(new ConceptMapBuilder("dfcdf95e-d593-11e4-9dcf-b36e1005e77b").type(sameAs).ensureTerm(ciel, "971").build()).build());
    install(new ConceptBuilder(Concepts.MOTHER).datatype(notApplicable).conceptClass(misc).name("3e225b1c-26fe-102b-80cb-0017a47871b2", "Mother", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("f673058e-d5db-102d-ad2a-000c29c2a5d7", "Mère", Locale.FRENCH, // locale-preferred
    null).description("ecf0bf80-07fe-102c-b5fa-0017a47871b2", "A mother of another person", Locale.ENGLISH).mapping(new ConceptMapBuilder("75870606-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MOTHER").build()).mapping(new ConceptMapBuilder("b220be0c-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2175").build()).mapping(new ConceptMapBuilder("e1d4e225-6760-46e7-8579-7390d0ec9bea").type(sameAs).ensureTerm(ciel, "970").build()).build());
    install(new ConceptBuilder(Concepts.OTHER_RELATIVE).datatype(notApplicable).conceptClass(misc).name("3e2265d0-26fe-102b-80cb-0017a47871b2", "Other relative", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("ac1661a2-4b4b-4fc5-b683-6ceac5ab24c2", "Autre parent", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecf0ce30-07fe-102c-b5fa-0017a47871b2", "A relative (non-coded) to another person", Locale.ENGLISH).mapping(new ConceptMapBuilder("b220c3d4-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2179").build()).mapping(new ConceptMapBuilder("75870bba-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "OTHER RELATIVE").build()).mapping(new ConceptMapBuilder("4c7d9bcf-0691-4f85-8dc6-9f936dbde00d").type(sameAs).ensureTerm(ciel, "5620").build()).build());
    install(new ConceptBuilder(Concepts.SIBLING).datatype(notApplicable).conceptClass(misc).name("3e225f36-26fe-102b-80cb-0017a47871b2", "Sibling", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("57063624-1e75-4529-9731-f79134c27f01", "Soeur/Frère", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecf0cc5a-07fe-102c-b5fa-0017a47871b2", "A sibling to another person", Locale.ENGLISH).mapping(new ConceptMapBuilder("b220c262-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2178").build()).mapping(new ConceptMapBuilder("75870a48-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SIBLING").build()).mapping(new ConceptMapBuilder("676d75d2-5930-4b35-aca1-34d8bfe22314").type(sameAs).ensureTerm(ciel, "972").build()).build());
    install(new ConceptBuilder(Concepts.PARTNER_OR_SPOUSE).datatype(notApplicable).conceptClass(misc).name("3e405a36-26fe-102b-80cb-0017a47871b2", "Partner or Spouse", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("78abf00f-360f-4fe1-92a8-2e33fa0c9fba", "Partenaire ou époux", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed191d5e-07fe-102c-b5fa-0017a47871b2", "General descriptive answer: a patient's partner or spouse.", Locale.ENGLISH).mapping(new ConceptMapBuilder("75aa8f18-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "PARTNER OR SPOUSE").build()).mapping(new ConceptMapBuilder("c4b3136a-2eb6-4536-865b-4842246aa015").type(sameAs).ensureTerm(ciel, "5617").build()).mapping(new ConceptMapBuilder("b299ae3e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5617").build()).build());
    // (This concept is both a question and an answer.)
    install(new ConceptBuilder(Concepts.GUARDIAN).datatype(text).conceptClass(question).name("3e1ef350-26fe-102b-80cb-0017a47871b2", "Guardian relationship to child", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("93b6c704-07d4-102c-b5fa-0017a47871b2", "GUARDIAN RELATION", Locale.ENGLISH, ConceptNameType.SHORT).name("50fde515-7d03-4aea-820a-1208acb0fdcf", "Relation de tuteur à l'enfant", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("eceddad6-07fe-102c-b5fa-0017a47871b2", "IF GUARDIAN IS NOT THE CHILD'S PARENTS, WHAT IS HIS/HER RELATION TO THE CHILD?", Locale.ENGLISH).mapping(new ConceptMapBuilder("757852a0-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "GUARDIAN RELATIONSHIP TO CHILD").build()).mapping(new ConceptMapBuilder("9d730eed-dae6-4800-9c0c-13cc7fe49bf2").type(sameAs).ensureTerm(ciel, "160639").build()).mapping(new ConceptMapBuilder("b21637a2-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1826").build()).build());
    install(new ConceptBuilder(Concepts.BROTHER).datatype(notApplicable).conceptClass(misc).name("3e225c7a-26fe-102b-80cb-0017a47871b2", "Brother", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f8400b03-3c37-4675-a3a4-027d67c7ad63", "Frère", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecf0c0e8-07fe-102c-b5fa-0017a47871b2", "A brother to another person", Locale.ENGLISH).mapping(new ConceptMapBuilder("457a7d24-c13b-4ad9-af3f-b58da4153dfd").type(sameAs).ensureTerm(ciel, "160729").build()).mapping(new ConceptMapBuilder("b220bf7e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2176").build()).mapping(new ConceptMapBuilder("7587076e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "BROTHER").build()).build());
    install(new ConceptBuilder(Concepts.SISTER).datatype(notApplicable).conceptClass(misc).name("3e225dd8-26fe-102b-80cb-0017a47871b2", "Sister", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("338ad7f5-1d55-4c45-9c6c-3b7391d0127b", "Soeur", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecf0ca5c-07fe-102c-b5fa-0017a47871b2", "Sister to another person", Locale.ENGLISH).mapping(new ConceptMapBuilder("b220c0f0-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2177").build()).mapping(new ConceptMapBuilder("3ddec89b-4770-4777-9d9b-7c15c10322a3").type(sameAs).ensureTerm(ciel, "160730").build()).mapping(new ConceptMapBuilder("758708e0-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SISTER").build()).build());
}
Also used : ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Example 3 with ConceptBuilder

use of org.openmrs.module.metadatadeploy.builder.ConceptBuilder in project openmrs-module-pihcore by PIH.

the class DeathConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    Concept yes = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.YES);
    Concept no = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.NO);
    Concept home = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.HOME);
    Concept hospital = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.HOSPITAL);
    Concept outsideOfInstitution = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.OUTSIDE_OF_INSTITUTION);
    Concept otherNonCoded = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.OTHER_NON_CODED);
    Concept familyMember = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.FAMILY_MEMBER);
    Concept police = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.POLICE);
    Concept surgery = MetadataUtils.existing(Concept.class, AnswerConcepts.Concepts.SURGERY);
    install(new ConceptBuilder("e2d8ea09-3c19-4574-92f3-b3ea67187986").datatype(text).conceptClass(question).name("9c194ad7-331b-410b-ac20-2a8dab166dd2", "Location of death at institution", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("6b1acb11-5fb0-4ea7-9532-6c81544b8eba", "Hospital service or outpatient clinic where the patient died. (A location.) \n\nAn observation of this concept implies that the patient died in a healthcare institution managed by this EMR system.", Locale.ENGLISH).mapping(new ConceptMapBuilder("2e9ce64f-2b2b-4648-b70b-3af895eb83a8").type(sameAs).ensureTerm(pih, "Location of death at institution").build()).mapping(new ConceptMapBuilder("50eebcc7-d330-4af9-b6b3-d61211e07978").type(sameAs).ensureTerm(pih, "9709").build()).build());
    install(new ConceptBuilder("e4310421-915a-4720-9d6a-42f5ca2ae975").datatype(text).conceptClass(question).name("e17f482c-c814-4ae6-ae07-bd6d29d707a9", "Location of death, non-coded", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("afe40b97-be99-46a7-bd76-bedaa7f5a037", "Where did the patient die, if it cannot be represented by a coded answer to \"Location of death\"", Locale.ENGLISH).mapping(new ConceptMapBuilder("85ba20be-383f-4539-b584-5790e76c0f1e").type(sameAs).ensureTerm(pih, "9708").build()).mapping(new ConceptMapBuilder("073d4569-c1d0-4aef-bd04-20060f85ff11").type(sameAs).ensureTerm(pih, "Location of death non coded").build()).build());
    install(new ConceptBuilder("ea2a816b-a8fc-437f-949d-391314f17445").datatype(text).conceptClass(question).name("8a24c13d-a614-4251-85f9-be5526708ad1", "Condition contributing to the death but not related to the disease or morbid condition, non-coded", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("e374ee4d-5baa-48a5-b24b-ccc7020a2a26", "Condition contributing to the death, non-coded", Locale.ENGLISH, null).description("a2d423b7-9da2-4af4-8f1e-e619c049e3df", "Condition contributing to the death but not related to the disease or morbid condition, as free-text", Locale.ENGLISH).mapping(new ConceptMapBuilder("87ec0d78-048f-423a-8732-b04de82c796e").type(sameAs).ensureTerm(pih, "9723").build()).mapping(new ConceptMapBuilder("6ed991d3-e5ad-4b4f-9c6c-601a35c0412c").type(sameAs).ensureTerm(pih, "Condition contributing to the death non coded").build()).build());
    install(new ConceptBuilder("07501ef7-e073-4541-a9e5-a697d91e1370").datatype(coded).conceptClass(finding).name("bc50cee2-8468-4b3b-8f0e-a5f95890df7c", "Location of death", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("717517a6-e488-457e-8320-6e42b816c0b2", "Lieu du décès", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ca30ec30-292b-4b59-8c4d-5b0c10d87308", "Where did the patient die?", Locale.ENGLISH).mapping(new ConceptMapBuilder("0bdb3d14-77b8-4d38-8a12-1b6ad26d5713").type(sameAs).ensureTerm(pih, "9669").build()).mapping(new ConceptMapBuilder("0225e69b-cc73-420a-b54d-93c1b7ce8921").type(sameAs).ensureTerm(pih, "Location of death").build()).answers(home, hospital, outsideOfInstitution, otherNonCoded).build());
    install(new ConceptBuilder("59ded805-b258-43f1-bd89-9fcb7e51a375").datatype(coded).conceptClass(diagnosis).name("6f43829f-b338-489a-af10-531992fd929f", "Final disease resulting in death", Locale.ENGLISH, // locale-preferred
    null).name("2a41c308-2b82-40fe-9d73-c67efacd8a77", "Final disease or condition resulting in death", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("22562a24-8ec1-463e-9562-d6e5564a88cd", "Maladie ou ayant directement provoqué le décès", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("01142bc3-575e-42bf-95e1-c7147428e006").type(sameAs).ensureTerm(pih, "Final disease resulting in death").build()).mapping(new ConceptMapBuilder("1b953954-e0ad-4838-8d0f-4d595dfe5e60").type(sameAs).ensureTerm(pih, "9676").build()).build());
    install(new ConceptBuilder("c86df3dd-4e05-4aab-ba0d-3003d559cdbe").datatype(coded).conceptClass(question).name("730f5e1b-9bb4-497a-aca3-553dc500d80b", "Maternal death", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("a51ac050-0309-4d2c-bb53-91fe6153be44", "Is the mother alive?", Locale.ENGLISH).mapping(new ConceptMapBuilder("85eab777-6dba-41ee-89fe-001c74f71f65").type(sameAs).ensureTerm(pih, "Maternal death").build()).mapping(new ConceptMapBuilder("5e9327f2-a09a-4e59-9d53-a12df62317e1").type(sameAs).ensureTerm(pih, "9668").build()).answers(yes, no).build());
    Concept diagnosisSequenceNumber = install(new ConceptNumericBuilder("1815AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").precise(false).datatype(numeric).conceptClass(misc).name("2095BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "DIAGNOSIS SEQUENCE NUMBER", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("105907BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "NUMÉRO D'ORDRE DES DIAGNOSTICS", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("1625FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "The number/order of a diagnosis on a list or death certificate.", Locale.ENGLISH).mapping(new ConceptMapBuilder("2c836f5d-2346-4c44-92c6-c3272120ac5c").type(sameAs).ensureTerm(pih, "9712").build()).mapping(new ConceptMapBuilder("b8a7f15d-82c0-4571-b4fb-cf1a577b84f7").type(sameAs).ensureTerm(ciel, "1815").build()).build());
    Concept causeOfDeathFromCertificate = install(new ConceptBuilder(CAUSE_OF_DEATH_FROM_DEATH_CERTIFICATE).datatype(coded).conceptClass(question).name("2094BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CAUSE OF DEATH FROM DEATH CERTIFICATE", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("105848BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CAUSE DU DÉCÈS SUR CERTIFICAT DE DÉCÈS", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("2af0667b-3a89-4aac-a873-5a2900c2240b").type(sameAs).ensureTerm(pih, "9713").build()).mapping(new ConceptMapBuilder("cc260f30-e152-49a3-ac29-b85c4845e25b").type(sameAs).ensureTerm(ciel, "1814").build()).mapping(new ConceptMapBuilder("141593ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedMvp, "18141000105007").build()).mapping(new ConceptMapBuilder("137578ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(snomedNp, "184305005").build()).build());
    Concept probableCauseOfDeath = install(new ConceptBuilder("160218AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(text).conceptClass(question).name("108120BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Probable cause of death (text)", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("caa6e803-c410-47cc-846b-8f84eb0b400e").type(sameAs).ensureTerm(pih, "9715").build()).mapping(new ConceptMapBuilder("217351ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "160218").build()).mapping(new ConceptMapBuilder("144080ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(snomedNp, "184305005").build()).build());
    install(new ConceptBuilder("1816AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(convSet).name("2096BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CAUSES OF DEATH FROM DEATH CERTIFICATE", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("105850BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "CAUSES DU DÉCÈS SUR CERTIFICAT DE DÉCÈS", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("1626FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "Ordered list of causes of death from death certificate", Locale.ENGLISH).mapping(new ConceptMapBuilder("5111c9c3-0894-4b9f-9c03-92f3d8da6156").type(sameAs).ensureTerm(pih, "9714").build()).mapping(new ConceptMapBuilder("70211dda-7985-4489-be51-e19c58e7ae88").type(sameAs).ensureTerm(ciel, "1816").build()).mapping(new ConceptMapBuilder("137579ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(snomedNp, "184305005").build()).mapping(new ConceptMapBuilder("141594ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedMvp, "18161000105006").build()).setMembers(diagnosisSequenceNumber, causeOfDeathFromCertificate, probableCauseOfDeath).build());
    install(new ConceptBuilder("9cb08a8b-19f2-49df-85f1-57c66ea63832").datatype(coded).conceptClass(question).name("11109d13-834c-4d94-9895-14d44d41e6ce", "Visited provider during illness", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("69d27c06-165e-4de3-a122-4e980d112749", "Visité un personnel de santé au cours de maladie", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("f2006f9f-2ea3-41ba-a2ca-c24150f0ff0d", "Did the person visit a provider during the sickness?", Locale.ENGLISH).mapping(new ConceptMapBuilder("d9a47600-36bb-4644-817c-8593d7051ad7").type(sameAs).ensureTerm(pih, "9671").build()).mapping(new ConceptMapBuilder("b9509e02-4b12-41bd-9e36-824548b3e85c").type(sameAs).ensureTerm(pih, "Visited provider during illness").build()).answers(yes, no).build());
    Concept mortician = install(new ConceptBuilder("0b725999-8fa0-40e0-b140-a5dfac05403c").datatype(notApplicable).conceptClass(misc).name("111496ab-31cc-4e9a-8bdb-b6f629fe13a3", "Mortician", Locale.ENGLISH, // locale-preferred
    null).name("473f645d-cb32-490d-b306-560774d54dd7", "Funeral home staff", Locale.ENGLISH, null).name("78f45753-4148-43a1-b904-aa9ef5773a96", "Undertaker", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("a98c1ca2-fef3-4818-9f82-2e614daa35f2", "Funeral director", Locale.ENGLISH, null).name("3c72ec96-42ac-46ae-a8e7-c36f1895af18", "Pompe funèbres", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("d64695ce-a749-4ff8-894f-b0aba79c8431").type(sameAs).ensureTerm(pih, "Undertaker").build()).mapping(new ConceptMapBuilder("d0f017dc-0f18-4941-8f41-bd5769f49237").type(sameAs).ensureTerm(pih, "9673").build()).build());
    install(new ConceptBuilder("5112fbab-db4a-4e67-aa96-be1bfbc0c2d1").datatype(coded).conceptClass(question).name("db2b86a9-d43c-458c-a985-327a814a67d0", "Source of information", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("b25ec3ad-8fc1-482a-b79d-8f5fab3feccd", "Source d'information", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("048b6945-c09d-4715-8984-e00b6ed78cca").type(sameAs).ensureTerm(pih, "9672").build()).mapping(new ConceptMapBuilder("9ef74eb4-d9e7-4a05-84bc-d1918113841e").type(sameAs).ensureTerm(pih, "Source of information").build()).answers(familyMember, police, mortician, otherNonCoded).build());
    install(new ConceptBuilder("cf68b8c0-5d4d-4835-a40d-bc30e0cf5d95").datatype(text).conceptClass(question).name("61b214fb-888f-4fa0-9edb-44fd872309be", "Burial certificate number", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("9d8755e8-be55-4749-bafe-b67974cb01a3", "Burial permit", Locale.ENGLISH, null).name("6cfb0bea-d4bf-4e81-be3f-1a83000cf26a", "Burial certificate", Locale.ENGLISH, null).name("d6f2eeb0-cc9e-4c22-abef-f40ddffad5ce", "Permit d'inhumer", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("3be725fb-2988-4415-b71f-89b30dcb75bb").type(sameAs).ensureTerm(pih, "Burial certificate").build()).mapping(new ConceptMapBuilder("b13384e0-fa9b-46b7-a57e-af989a606f45").type(sameAs).ensureTerm(pih, "9680").build()).build());
    install(new ConceptBuilder("fa03343d-2143-4769-b421-a018717cd13b").datatype(coded).conceptClass(diagnosis).name("c8f588cc-133c-4c62-a04b-c347d8f31d68", "Condition contributing to the death", Locale.ENGLISH, // locale-preferred
    null).name("75a26b39-c8e0-4b65-83ef-9b1f2be7161d", "Condition contributing to the death but not related to the disease or morbid condition", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).description("b6f07641-b175-437f-adde-438547a78981", "Condition contributing to the death but not related to the disease or morbid condition", Locale.ENGLISH).mapping(new ConceptMapBuilder("cac289be-04e3-4dff-9f4d-d2201945f42d").type(sameAs).ensureTerm(pih, "9678").build()).mapping(new ConceptMapBuilder("1526b421-e9ab-4493-9682-6a620bf2bfb6").type(sameAs).ensureTerm(pih, "Condition contributing to the death").build()).build());
    Concept autopsy = install(new ConceptBuilder("7198e4f4-8bf0-4816-92cb-569b62bc2fef").datatype(notApplicable).conceptClass(misc).name("e767ddbb-53fa-44f8-97b7-ed47e1c97e61", "Autopsy", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0f3edffb-88cd-40f1-b9ab-9b960e9067b3", "Obduction", Locale.ENGLISH, null).name("76943508-c269-4d73-8158-3e34964a1a49", "Post-mortem examination", Locale.ENGLISH, null).name("d4db623c-55f8-4f0f-99a5-296423f19808", "Autopsia cadaverum", Locale.ENGLISH, null).name("cee5fea8-93b5-4da1-8fc7-5d3343be03a0", "Autopsie", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("206bea47-900d-4393-8804-b629a442bccb", "An autopsy is a highly specialized surgical procedure that consists of a thorough examination of a corpse to determine the cause and manner of death and to evaluate any disease or injury that may be present. It is usually performed by a specialized medical doctor called a pathologist.", Locale.ENGLISH).mapping(new ConceptMapBuilder("8197c3be-2399-423d-81a0-4dc05d926f5c").type(sameAs).ensureTerm(pih, "Autopsy").build()).mapping(new ConceptMapBuilder("1aaa2d94-250b-4f3b-b3ac-fce9af8a4cf0").type(sameAs).ensureTerm(pih, "9682").build()).build());
    install(new ConceptBuilder("b3f04355-1e38-477e-9664-feda30c0aedb").datatype(coded).conceptClass(question).name("e028e91c-3498-45b7-a2e5-f0fc0731e821", "Method of confirming death", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("00f0132f-4ef3-4ba9-bb35-c396777d673f", "Moyen de confirmation du diagnostic", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("a18206ce-c93b-4f5e-9cb9-f2d85f27ee89", "How was the cause of death confirmed?", Locale.ENGLISH).mapping(new ConceptMapBuilder("a9752950-23bd-442a-bd8e-5bba63f44464").type(sameAs).ensureTerm(pih, "Method of confirming death").build()).mapping(new ConceptMapBuilder("5d355151-550e-4207-aa0a-b4dff5d15e82").type(sameAs).ensureTerm(pih, "9681").build()).answers(autopsy, surgery).build());
    install(new ConceptBuilder("eeb48585-432a-48be-af84-c2f2b8c5b541").datatype(text).conceptClass(question).name("9ff10896-e6c3-4c7c-9249-b430c1747031", "Circumstances of death", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("08bbc806-32dd-44fe-8e75-62310a912ab2", "Description of death by non-clinician", Locale.ENGLISH, null).name("e7607abd-c2e6-44b2-980e-004759df2c20", "Circonstances du décès", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ee223551-4f65-4f79-aab2-cfca818f691d", "Description of death from a non-medical background", Locale.ENGLISH).mapping(new ConceptMapBuilder("349807f4-57b6-4351-bb09-292f547bdfd5").type(sameAs).ensureTerm(pih, "Circumstances of death").build()).mapping(new ConceptMapBuilder("b8f0135c-4d68-41b9-b8c5-eff1096e4108").type(sameAs).ensureTerm(pih, "9675").build()).build());
    install(new ConceptBuilder("c983f4d2-7e8d-4336-ac56-f4bec4f4cfc9").datatype(coded).conceptClass(question).name("d1bea751-68b8-4b7f-830d-567456eb26ed", "Underlying cause of death", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("25582932-056b-4739-abbd-341bec6d5f0d", "Cause sous-jacente de la mort", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("304e9546-d0f7-4330-b980-45c3d7a09b02", "Line 4 of the death certificate", Locale.ENGLISH).mapping(new ConceptMapBuilder("9c522d02-d6ac-4b19-b845-60ad844cda89").type(sameAs).ensureTerm(pih, "9679").build()).mapping(new ConceptMapBuilder("9d64cd23-866d-49d5-b52b-70112776b331").type(sameAs).ensureTerm(pih, "Underlying cause of death").build()).build());
    install(new ConceptBuilder("12a8fbd6-8ac9-4bb1-ac25-b3c25661ba85").datatype(coded).conceptClass(diagnosis).name("c4b4dc79-72e4-45bd-b1d6-4da66939bc9e", "Condition causing the final disease", Locale.ENGLISH, // locale-preferred
    null).name("3e5204bb-fabd-4c96-9ac1-c57b8258d150", "Condition which caused the final disease or condition", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("b9ff3a12-8bc9-4c45-9575-2e48da83b573", "Affectations morbides ayant éventuellement conduit a l'état préciser l'affectation initiale étant indiquée en dernier lieu", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("68bb8153-da6d-4e19-a4ad-2169f8896857", "Conditions qui causent des maladies finale", Locale.FRENCH, null).description("700f71f8-336d-4b08-b648-b8baecfd96cc", "The 2nd line on the death certificate", Locale.ENGLISH).mapping(new ConceptMapBuilder("366d1dc5-3d60-492c-8823-3ca6c03d26fd").type(sameAs).ensureTerm(pih, "9677").build()).mapping(new ConceptMapBuilder("c500e3a2-2252-4efd-85c7-ce2ae1a792fa").type(sameAs).ensureTerm(pih, "Condition causing the final disease").build()).build());
    install(new ConceptNumericBuilder("6e656477-72e2-4ecf-a777-0c488c4a14e2").units("days").precise(false).datatype(numeric).conceptClass(question).name("c2424b53-cc4b-415c-998a-1c5365c3af9d", "Duration of hospitalization during which patient died, in days", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("da7384c7-29fa-4806-af62-5a3681cfa34a", "If the patient died while hospitalized, then this concept represents the duration of that hospitalization, in days", Locale.ENGLISH).mapping(new ConceptMapBuilder("ce3e74e7-53d8-4e73-88ab-8191ab5c1aa1").type(sameAs).ensureTerm(pih, "Duration of hospitalization when patient died").build()).mapping(new ConceptMapBuilder("8334471b-ba18-453a-8ce8-747911c01e06").type(sameAs).ensureTerm(pih, "9710").build()).build());
    // Update Death-related Global Properties
    setGlobalProperty("concept.causeOfDeath", causeOfDeathFromCertificate.getId().toString());
}
Also used : Concept(org.openmrs.Concept) ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder) ConceptNumericBuilder(org.openmrs.module.metadatadeploy.builder.ConceptNumericBuilder)

Example 4 with ConceptBuilder

use of org.openmrs.module.metadatadeploy.builder.ConceptBuilder in project openmrs-module-pihcore by PIH.

the class InsuranceConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    Concept unknown = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.UNKNOWN);
    Concept other = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.OTHER_NON_CODED);
    Concept none = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.NONE);
    Concept insuranceNumber = install(new ConceptBuilder(Concepts.INSURANCE_POLICY_NUMBER).datatype(text).conceptClass(question).name("efd4653e-9a0f-4d60-bd41-19795c7ffce9", "Insurance policy number", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("92f5bdd1-6a09-43ed-a83f-e750474ed562", "Numéro d'assurance", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("8d2bf20b-5cb9-405a-84cb-6c3e31fc21d9", "Nimewo asirans", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("5b859e0f-57e1-45b6-a2af-5cee07e414e9", "Policy number for insurance", Locale.ENGLISH).mapping(new ConceptMapBuilder("4b4fd997-3b3e-4ee2-8a38-cc3f5cf10e20").type(sameAs).ensureTerm(pih, "Insurance policy number").build()).mapping(new ConceptMapBuilder("19e0f0c4-dd0e-4002-a501-368d042d3d73").type(sameAs).ensureTerm(pih, "10737").build()).build());
    Concept cigna = install(new ConceptBuilder("e45d8d56-a6bd-4b46-9939-3f6ae24bbba5").datatype(notApplicable).conceptClass(misc).name("d8b1954e-aabf-426e-8f39-932f6899bfed", "CIGNA (Vanbreda)", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("5aa133dd-29dd-421d-b2c4-ce4c44d2481f", "CIGNA (Vanbreda)", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("c972ca93-3f9a-4ec3-8828-46c78a84cb4b", "CIGNA (Vanbreda)", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("0350f7c1-0377-4fb4-884f-53f742645065", "Haitian insurance", locale_HAITI).mapping(new ConceptMapBuilder("65a15b60-0d4a-4cc1-8325-4f70e3e75158").type(sameAs).ensureTerm(pih, "CIGNA (Vanbreda)").build()).mapping(new ConceptMapBuilder("842d0137-3cda-4d5e-ba56-3db54b1c5cc9").type(sameAs).ensureTerm(pih, "10736").build()).build());
    Concept gmcHenner = install(new ConceptBuilder("aa6e61f7-dafd-4f5d-a013-97cbeab9c14f").datatype(notApplicable).conceptClass(misc).name("57a38db5-5468-44c4-af20-82f5f84130fd", "GMC Henner", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("1d2be8c6-9205-49ed-935f-a18b8f7e54fc", "GMC Henner", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("7368fe1b-05ea-4c38-9606-67d853a60d6e", "GMC Henner", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("70ef0782-68b5-4bd7-b0bb-3e0b9451d0e6", "Insurance company", Locale.ENGLISH).mapping(new ConceptMapBuilder("460302b5-2731-40ab-b525-b71bc3c3532b").type(sameAs).ensureTerm(pih, "10735").build()).mapping(new ConceptMapBuilder("c31ec091-7e3b-41ae-ba5a-c4d00c404f17").type(sameAs).ensureTerm(pih, "GMC Henner").build()).build());
    Concept uniAssurances = install(new ConceptBuilder("fbb45a9d-25be-41ca-8fba-a64d96f2867a").datatype(notApplicable).conceptClass(misc).name("c0cf8282-39e0-46a2-aca2-767c589c0d77", "UniAssurances", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("1a40d23f-4f48-4392-9a7f-7709b2a0e891", "UniAssurances", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("adb79f84-6c91-4234-a8fd-a0202767a92c", "UniAssurances", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("d424f821-3539-4f79-875d-2a1504230ef5", "Haitian insurance company", locale_HAITI).mapping(new ConceptMapBuilder("a962b737-4a78-4a27-b3f6-5ac2494f3d72").type(sameAs).ensureTerm(pih, "10734").build()).mapping(new ConceptMapBuilder("ccdf1c5d-f36e-48a2-8113-f13facbb9e3c").type(sameAs).ensureTerm(pih, "UniAssurances").build()).build());
    Concept sogeAssurance = install(new ConceptBuilder("bfa263ac-cf3d-4250-a6d4-180ce918b0ef").datatype(notApplicable).conceptClass(misc).name("003d636f-4eb8-4895-8a23-60db0510db81", "SOGE Assurance", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("335f7137-da23-41c9-851b-734c1412ce2e", "SOGE Assurance", Locale.FRENCH, // locale-preferred
    null).name("b5fdb5a1-d5b6-45c6-923f-808c571fc8af", "Société générale haïtienne de Banque", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("a7a88d46-ab0e-4df0-b1cf-c497c96db78b", "SOGE Assurance", locale_HAITI, // locale-preferred
    null).name("9af9a671-4ca6-4cb1-b21b-f0261612b81a", "Société générale haïtienne de Banque", locale_HAITI, ConceptNameType.FULLY_SPECIFIED).description("ab749613-15b0-4110-9d92-f7d991f5cfcb", "Haitian insurance company", Locale.ENGLISH).mapping(new ConceptMapBuilder("f0b4cb9c-1a73-4df9-9bf0-de08d6f7e4f1").type(sameAs).ensureTerm(pih, "10733").build()).mapping(new ConceptMapBuilder("23ddc03d-1fd7-451f-b7bd-4442f076642d").type(sameAs).ensureTerm(pih, "Sogebank Assurance").build()).build());
    Concept conam = install(new ConceptBuilder("939e2288-a9df-4f63-8b24-95674d04bd33").datatype(notApplicable).conceptClass(misc).name("255165d4-8646-4b4f-a362-0148fb107944", "CONAM", Locale.ENGLISH, // locale-preferred
    null).name("4cda186d-c11c-4c9d-a6b8-9f7dd3808cc8", "Coordination Nationale Maladie", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("bf36623c-9c5f-4c8d-9207-76665ffa7f7f", "CONAM", Locale.FRENCH, // locale-preferred
    null).name("69e12f35-8ec4-490e-9bef-55c55061cb8c", "Coordination Nationale Maladie", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("34645aaa-109b-4bf1-9c78-7cfdb2d0c884", "CONAM", locale_HAITI, // locale-preferred
    null).name("102b89f6-3a3e-4c72-953f-9d826abe8c31", "Coordination Nationale Maladie", locale_HAITI, ConceptNameType.FULLY_SPECIFIED).description("b952d4ba-ae41-41ba-8bf1-752b3dd2b96e", "Haiti insurance company", Locale.ENGLISH).mapping(new ConceptMapBuilder("f5af26fd-7bc4-4c74-a3b1-f2121d752a0c").type(sameAs).ensureTerm(pih, "10732").build()).mapping(new ConceptMapBuilder("179e0d4f-ce72-44fe-a236-089590c62e44").type(sameAs).ensureTerm(pih, "CONAM").build()).build());
    Concept cah = install(new ConceptBuilder("acf84e71-a141-4d3a-a33d-8aa8694ce03b").datatype(notApplicable).conceptClass(misc).name("58408ad2-905e-4e13-8e97-f61085baa89e", "CAH", Locale.ENGLISH, // locale-preferred
    null).name("cd8735e9-93bc-4c43-8087-9560ea91ac34", "Compagnie d’assurance d’Haïti", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("d64ce12b-6eb6-4c5d-8c45-0484b00dfb41", "CAH", Locale.FRENCH, // locale-preferred
    null).name("c020de03-bc1f-4f60-ae46-b2a0ecc6d463", "Compagnie d’assurance d’Haïti", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("736a7b0d-0544-4828-a9f7-98c06b0e1d06", "CAH", locale_HAITI, // locale-preferred
    null).name("cda4e0e9-f0d7-45a4-8d1a-af9832c7aad9", "Compagnie d’assurance d’Haïti", locale_HAITI, ConceptNameType.FULLY_SPECIFIED).description("2d98725f-7fde-4847-b234-6942ee55baa6", "Insurance company in Haiti", Locale.ENGLISH).mapping(new ConceptMapBuilder("8b6103b6-419c-4512-9430-61f9b6929d7f").type(sameAs).ensureTerm(pih, "10731").build()).mapping(new ConceptMapBuilder("02a8eff2-24eb-4266-8eec-c901b7eed04c").type(sameAs).ensureTerm(pih, "CAH").build()).build());
    Concept inassa = install(new ConceptBuilder("8e027388-697b-4a82-9249-7f76bd7b00d8").datatype(notApplicable).conceptClass(misc).name("96f118d2-f5df-4dbe-908f-0abd0661eb74", "INASSA", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("926305e0-dd7e-439d-96c2-ffa9cda206dc", "INASSA", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("6aa6e224-75a9-4cad-8a31-cd549d8ca043", "INASSA", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("841caf86-9af3-4d2b-810b-0a5fae4b35ca", "Haitian insurance company", Locale.ENGLISH).mapping(new ConceptMapBuilder("0def79ed-eaba-4fea-a459-b30eea7226a2").type(sameAs).ensureTerm(pih, "INASSA").build()).mapping(new ConceptMapBuilder("d17cac75-2f7a-47e5-bcee-8a9a1b17c5c0").type(sameAs).ensureTerm(pih, "10730").build()).build());
    Concept aic = install(new ConceptBuilder("4ee3cbfa-1e09-4d5e-bcd1-d7529a34774b").datatype(notApplicable).conceptClass(misc).name("47dd45ea-c049-44fb-9869-e11afe505f41", "AIC", Locale.ENGLISH, // locale-preferred
    null).name("5e469492-243d-4c55-87eb-f11d8d653694", "Alternative Insurance Company", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("c1576739-a764-4a14-b9b5-bba66304a72c", "AIC", Locale.FRENCH, // locale-preferred
    null).name("285085cb-1ee7-434d-a4c8-8e755b95c812", "Alternative Insurance Company", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("4f7d9907-395c-4dd6-ab41-c0a970fd1da9", "AIC", locale_HAITI, // locale-preferred
    null).name("4c1b5cf7-a611-4e47-9d90-4e9ad8960ed4", "Alternative Insurance Company", locale_HAITI, ConceptNameType.FULLY_SPECIFIED).description("81bad248-9a7c-4103-844a-b0ec00b6f3b8", "Haitian insurance company", Locale.ENGLISH).mapping(new ConceptMapBuilder("4a926977-24ef-45fd-b314-c366e8eb5f7a").type(sameAs).ensureTerm(pih, "AIC").build()).mapping(new ConceptMapBuilder("d0f37631-dfd9-42cb-92cf-d8858cbb595b").type(sameAs).ensureTerm(pih, "10729").build()).build());
    Concept ofatma = install(new ConceptBuilder("fb323f04-44cd-4cc0-9eb5-5c0d2c9988c7").datatype(notApplicable).conceptClass(misc).name("72dfc07b-9007-440c-92e6-d2c674dbc4d9", "OFATMA", Locale.ENGLISH, // locale-preferred
    null).name("e2b966de-826c-47f5-acde-f5521b00545e", "OFATMA", Locale.FRENCH, // locale-preferred
    null).name("e89aa8be-78ee-41df-bbeb-310da7e9afb0", "OFATMA", locale_HAITI, // locale-preferred
    null).description("87361b91-29d9-472f-bd16-a92995cac380", "Office d'Assurance Accidents du Travail, Maladie et Maternité", Locale.ENGLISH).mapping(new ConceptMapBuilder("7f301c49-9d51-45be-a717-203233419b19").type(sameAs).ensureTerm(pih, "OFATMA").build()).mapping(new ConceptMapBuilder("f0ff2a37-cfc5-43b4-aff2-9daebd664eeb").type(sameAs).ensureTerm(pih, "11544").build()).build());
    Concept haitiInsuranceCo = install(new ConceptBuilder(Concepts.HAITI_INSURANCE_COMPANY_NAME).datatype(coded).conceptClass(question).name("be6a0015-3fc1-4559-8c31-24a5126e0537", "Haiti insurance company name", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("6c174385-836d-481f-9753-4a6ccbe26086", "The name of various insurance companies in Haiti.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b942bae4-3e9d-490e-89e7-7a36309d603a").type(sameAs).ensureTerm(pih, "Haiti insurance company name").build()).mapping(new ConceptMapBuilder("18eb55fa-080b-406a-a09e-ed1378b19f1a").type(sameAs).ensureTerm(pih, "10728").build()).answers(aic, inassa, cah, conam, sogeAssurance, uniAssurances, gmcHenner, cigna, ofatma, none, other, unknown).build());
    Concept insuranceCoOther = install(new ConceptBuilder(Concepts.OTHER_INSURANCE_COMPANY_NAME).datatype(text).conceptClass(question).name("ddd3d35b-0b7a-4d33-8ffe-dce09cb978aa", "Insurance company name (text)", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("9b49feaa-cc1b-47d9-aab9-207606317bac", "Insurance company name, non-coded", Locale.ENGLISH, null).description("96e8ab41-b110-42c8-9fce-4968a35a3cea", "The insurance company name (non coded, free text)", Locale.ENGLISH).mapping(new ConceptMapBuilder("667fbdc3-9ba9-471c-b9a6-d30e3d4b58f0").type(sameAs).ensureTerm(pih, "Insurance company name (text)").build()).mapping(new ConceptMapBuilder("740b2a1b-0aee-4f7f-ae76-a338545a800c").type(sameAs).ensureTerm(pih, "10740").build()).build());
    install(new ConceptBuilder("729cf278-2a3e-4f0c-87ff-3cbe25bf2bc9").datatype(notApplicable).conceptClass(convSet).name("abf48113-0bc7-4ae6-9b9f-7f7e09cbc69c", "Insurance construct", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("bc1585aa-7341-4704-9734-51b27b230153").type(sameAs).ensureTerm(pih, "10738").build()).mapping(new ConceptMapBuilder("f43ad6e1-a34f-4ec2-9e6f-b778e9c6e383").type(sameAs).ensureTerm(pih, "Insurance construct").build()).setMembers(haitiInsuranceCo, insuranceCoOther, insuranceNumber).build());
}
Also used : Concept(org.openmrs.Concept) ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Example 5 with ConceptBuilder

use of org.openmrs.module.metadatadeploy.builder.ConceptBuilder in project openmrs-module-pihcore by PIH.

the class SocioEconomicConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    Concept unknown = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.UNKNOWN);
    Concept otherNonCoded = MetadataUtils.existing(Concept.class, CommonConcepts.Concepts.OTHER_NON_CODED);
    // start address fields
    Concept country = install(new ConceptBuilder(Concepts.COUNTRY).datatype(text).conceptClass(question).name("5619bbf9-a49b-4fb4-a70b-ee2304d981a3", "Country concept", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("256b5ce3-e0c4-4ca7-9e4b-6564c0865c1b", "Generic concept for storing the equivalent to person_address.country", Locale.ENGLISH).mapping(new ConceptMapBuilder("27e264c3-8af8-4a51-8576-f7a4c6033edd").type(sameAs).ensureTerm(pih, "Country").build()).mapping(new ConceptMapBuilder("30cec689-68e1-47ac-a56d-0d26b9068c57").type(sameAs).ensureTerm(pih, "10382").build()).build());
    Concept stateProvince = install(new ConceptBuilder(Concepts.STATE_PROVINCE).datatype(text).conceptClass(question).name("a4eacc94-69c4-4a75-901a-0108a1a69db7", "State Province concept", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("17c9da99-a8c6-4958-8080-69e413539b15", "Generic concept for storing the equivalent to person_address.state_province", Locale.ENGLISH).mapping(new ConceptMapBuilder("dea4f883-a703-4092-b150-2367f00c3b94").type(sameAs).ensureTerm(pih, "State Province").build()).mapping(new ConceptMapBuilder("362f24a6-0137-45fb-b9a8-b212a95f5868").type(sameAs).ensureTerm(pih, "10384").build()).build());
    Concept cityVillage = install(new ConceptBuilder(Concepts.CITY_VILLAGE).datatype(text).conceptClass(question).name("ad2d1756-b011-4a14-a0ee-039ccb7362f5", "City Village concept", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("27d17b99-168d-45bf-80fe-cad83da60b4e", "Generic concept for storing the equivalent to person_address.city_village", Locale.ENGLISH).mapping(new ConceptMapBuilder("bce8f3f2-453c-42c5-abfc-151510ab61d7").type(sameAs).ensureTerm(pih, "10383").build()).mapping(new ConceptMapBuilder("72f423c2-a2c3-412a-a61f-0b7325315dd4").type(sameAs).ensureTerm(pih, "City Village").build()).build());
    Concept address3 = install(new ConceptBuilder(Concepts.ADDRESS_3).datatype(text).conceptClass(question).name("c343b137-2521-46f4-bb12-4f39c0451ac7", "Address3 concept", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("e8813644-1649-48f4-8b1c-b1ab5ab61bc4", "Generic concept for storing the equivalent to person_address.address3", Locale.ENGLISH).mapping(new ConceptMapBuilder("d17481fd-4549-4ac2-9fe9-4030e2e276bf").type(sameAs).ensureTerm(pih, "10381").build()).mapping(new ConceptMapBuilder("5d17859d-d548-4a69-aebf-34e6c8a35fc0").type(sameAs).ensureTerm(pih, "Address3").build()).build());
    Concept address2 = install(new ConceptBuilder(Concepts.ADDRESS_2).datatype(text).conceptClass(question).name("86a028ff-c879-4efd-a239-079cbd11cf59", "Address2 concept", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("eb802d1d-409c-49b1-b46b-977f96183e08", "Generic concept for storing the equivalent to person_address.address2", Locale.ENGLISH).mapping(new ConceptMapBuilder("2afb9fd2-4682-4e01-b0a4-506399f5a0c9").type(sameAs).ensureTerm(pih, "Address2").build()).mapping(new ConceptMapBuilder("f833385e-bcee-436f-bb8b-f92a3c60e444").type(sameAs).ensureTerm(pih, "10380").build()).build());
    Concept address1 = install(new ConceptBuilder(Concepts.ADDRESS_1).datatype(text).conceptClass(question).name("f9f05252-0128-4d17-b191-f1aaf0415700", "Address1 concept", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("f4489388-bb9e-40d2-8bf1-d85ea312e7bc", "Generic concept for storing the equivalent to person_address.address1", Locale.ENGLISH).mapping(new ConceptMapBuilder("aeec89f3-8813-4324-965a-9f41d4b99982").type(sameAs).ensureTerm(pih, "Address1").build()).mapping(new ConceptMapBuilder("e83bf96b-5e4e-4659-8d0b-780de1b6284d").type(sameAs).ensureTerm(pih, "10378").build()).build());
    // end address construct
    // start place of birth
    install(new ConceptBuilder(Concepts.BIRTHPLACE).datatype(text).conceptClass(question).name("956ec9c0-07d4-102c-b5fa-0017a47871b2", "Birthplace", Locale.ENGLISH, // locale-preferred
    null).name("0b6aeb84-15f5-102d-96e4-000c29c2a5d7", "Place of birth", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("8f149876-967b-4207-86a7-ffb717d31c01", "Lieu de naissance", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("ea5a0b1d-5a89-45ce-a774-9144338a1eba", "Kote li fèt", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed1fea62-07fe-102c-b5fa-0017a47871b2", "The place where the person was born.  This could be a city, town or country.", Locale.ENGLISH).mapping(new ConceptMapBuilder("759c3c06-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "PLACE OF BIRTH").build()).mapping(new ConceptMapBuilder("b25a331c-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2997").build()).build());
    install(new ConceptBuilder(Concepts.BIRTHPLACE_ADDRESS_CONSTRUCT).datatype(notApplicable).conceptClass(convSet).name("b417be57-726c-4ef5-854d-7eaf2ec9f836", "Birthplace address construct", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("17b5611b-30f2-461e-a062-ab4c674f6a03").type(sameAs).ensureTerm(pih, "Birthplace address construct").build()).mapping(new ConceptMapBuilder("6556b658-6134-4883-85a5-430fda1ce14a").type(sameAs).ensureTerm(pih, "10378").build()).setMembers(address1, address2, address3, cityVillage, stateProvince, country).build());
    // end place of birth
    Concept mainActivityNonCoded = install(new ConceptBuilder(Concepts.MAIN_ACTIVITY_NON_CODED).datatype(text).conceptClass(question).name("3e254494-26fe-102b-80cb-0017a47871b2", "Main activity, non-coded", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b9565bc-15f5-102d-96e4-000c29c2a5d7", "Occupation, non-coded", Locale.ENGLISH, null).name("0b9564cc-15f5-102d-96e4-000c29c2a5d7", "Principal activity, non-coded", Locale.ENGLISH, null).name("f696981e-d5db-102d-ad2a-000c29c2a5d7", "Activité principale, non codée", Locale.FRENCH, // locale-preferred
    null).description("ecf2882e-07fe-102c-b5fa-0017a47871b2", "response if patient main activity is not one of the coded choices", Locale.ENGLISH).mapping(new ConceptMapBuilder("b2560486-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2452").build()).mapping(new ConceptMapBuilder("75956b38-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MAIN ACTIVITY, NON-CODED").build()).build());
    Concept urban = install(new ConceptBuilder(Concepts.URBAN).datatype(notApplicable).conceptClass(misc).name("bf2be020-e02d-45f2-a9f0-3e3573e3a211", "Urban", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("8489dde6-d659-4d3f-ad6c-922e451e534f", "Urbaine", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("b08a5d68-348f-43c7-95e5-bda39a06a2c9", "An urban area is characterized by higher population density and vast human features in comparison to the areas surrounding it.", Locale.ENGLISH).mapping(new ConceptMapBuilder("2e56e31f-877e-45d8-9602-09237d0ba152").type(sameAs).ensureTerm(pih, "Urban").build()).mapping(new ConceptMapBuilder("0cbe6a6c-bb23-420e-9a40-c76747337042").type(sameAs).ensureTerm(pih, "9666").build()).build());
    Concept rural = install(new ConceptBuilder(Concepts.RURAL).datatype(notApplicable).conceptClass(misc).name("ed83c7bf-b7bb-45d1-812c-d8ee37a080e3", "Rural", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("efc13014-58e3-4769-a3f5-f3488e30433b", "Rural", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("fbf39aa9-648b-455c-99d6-2c07cfbe15aa", "In general, a rural area is a geographic area that is located outside cities and towns.", Locale.ENGLISH).mapping(new ConceptMapBuilder("cd3fa7d7-60fd-41a6-98f9-0e110c77af97").type(sameAs).ensureTerm(pih, "Rural").build()).mapping(new ConceptMapBuilder("f683a2ce-8952-4e97-a5cf-de428e0917b1").type(sameAs).ensureTerm(pih, "9665").build()).build());
    install(new ConceptBuilder("6aeb49da-bfdf-4b49-8b68-d1e675f0dc2e").datatype(coded).conceptClass(question).name("6d70ba3d-8464-46d9-89a1-dacff7ceb9bb", "Residential environment", Locale.ENGLISH, // locale-preferred
    null).name("1f3d6109-b6c1-47ab-b207-27af20729596", "Classification of residential environment", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).description("d14a56cb-03f7-4ca4-8d6e-1d855b6c2ad5", "Is the residence urban or rural?", Locale.ENGLISH).mapping(new ConceptMapBuilder("1f33049f-4dde-4ca9-8eab-5adf519102c8").type(sameAs).ensureTerm(pih, "9667").build()).mapping(new ConceptMapBuilder("6f94b002-47a3-4f4b-948e-ed2537f6c5e0").type(sameAs).ensureTerm(pih, "Classification of residential environment").build()).answers(rural, urban).build());
    Concept celibate = install(new ConceptBuilder("60eca8ce-777b-4556-8ea3-f7fa5a439ab2").datatype(notApplicable).conceptClass(misc).name("0b78117e-15f5-102d-96e4-000c29c2a5d7", "Celibate", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("f71e3f26-d5db-102d-ad2a-000c29c2a5d7", "Célibataire", Locale.FRENCH, // locale-preferred
    null).description("ed282fec-07fe-102c-b5fa-0017a47871b2", "Answer which describes a type of civil status.", Locale.ENGLISH).mapping(new ConceptMapBuilder("75a090d0-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "CELIBATE").build()).mapping(new ConceptMapBuilder("b25f4aaa-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "3628").build()).build());
    // TODO:  Change all the names to use Locale.LANGUAGE (ie.  Locale.HAITI or Locale.HT)
    Concept divorced = install(new ConceptBuilder("3cd6e55c-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e150a5c-26fe-102b-80cb-0017a47871b2", "Divorced", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("d1c68e19-cfac-4b72-98c0-17de59bf5b23", "Divorcé(e)", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("c87991b3-02fe-45ef-9325-477787cba57f", "Divòse", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ece42a0e-07fe-102c-b5fa-0017a47871b2", "Answer which describes a type of civil status.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b20d0524-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1058").build()).mapping(new ConceptMapBuilder("75687e8e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "DIVORCED").build()).build());
    Concept singleOrChild = install(new ConceptBuilder("df488243-d1d5-4b50-ae04-40b4ffdcf934").datatype(notApplicable).conceptClass(misc).name("0b75ec14-15f5-102d-96e4-000c29c2a5d7", "Single or a child", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b7feb10-15f5-102d-96e4-000c29c2a5d7", "Single/Child", Locale.ENGLISH, ConceptNameType.SHORT).name("388cae77-22a6-48bc-bfbb-17908c8d61c0", "Célibataire ou un enfant", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("536981db-7436-4edc-9c9d-0eceb1461fda", "Selibatè oubyen timoun", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed244d64-07fe-102c-b5fa-0017a47871b2", "Civil status of patient.", Locale.ENGLISH).mapping(new ConceptMapBuilder("759eda88-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SINGLE OR A CHILD").build()).mapping(new ConceptMapBuilder("b25d1d48-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "3347").build()).build());
    Concept neverMarried = install(new ConceptBuilder("3cd6e3d6-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1508f4-26fe-102b-80cb-0017a47871b2", "Never married", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f5c8e202-d5db-102d-ad2a-000c29c2a5d7", "Jamais marié", Locale.FRENCH, // locale-preferred
    null).description("ece428b0-07fe-102c-b5fa-0017a47871b2", "Answer which describes a type of civil status.", Locale.ENGLISH).mapping(new ConceptMapBuilder("75687cb8-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "NEVER MARRIED").build()).mapping(new ConceptMapBuilder("b20d03a8-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1057").build()).build());
    Concept widowed = install(new ConceptBuilder("3cd6e6f6-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e150bce-26fe-102b-80cb-0017a47871b2", "Widowed", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("95692394-07d4-102c-b5fa-0017a47871b2", "Spouse died", Locale.ENGLISH, null).name("faae1a8e-07c1-4c37-8527-75dc7901d2ac", "Veuf(ve)", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("bf337879-0fd6-4bbb-bb4d-8b4cf68a8e52", "Veuve", Locale.FRENCH, null).name("ab6ed0a7-f146-476f-b6f7-866b44402dce", "Veuf", Locale.FRENCH, null).name("1dd94bf3-0962-4ca6-8a66-0fd1dccd0887", "Vèf", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ece42bf8-07fe-102c-b5fa-0017a47871b2", "Answer which describes a type of civil status.", Locale.ENGLISH).mapping(new ConceptMapBuilder("7568800a-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "WIDOWED").build()).mapping(new ConceptMapBuilder("b20d06aa-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1059").build()).build());
    Concept separated = install(new ConceptBuilder("3cd6e246-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e150782-26fe-102b-80cb-0017a47871b2", "Separated", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("5c572211-edfc-457c-b922-8ee8a5293bf8", "Séparé(e)", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("4e1dd8d7-22ca-4fbc-9163-c1f6cbb328e6", "Separe", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ece42752-07fe-102c-b5fa-0017a47871b2", "Answer which describes a type of civil status.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b20d0236-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1056").build()).mapping(new ConceptMapBuilder("7568786c-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SEPARATED").build()).build());
    Concept partnerInPrison = install(new ConceptBuilder("0e3d6c1e-3dee-4510-9132-36c8f136e41e").datatype(notApplicable).conceptClass(misc).name("0b75eb1a-15f5-102d-96e4-000c29c2a5d7", "Partner in prison", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f6fe72fe-d5db-102d-ad2a-000c29c2a5d7", "Partenaire en prison", Locale.FRENCH, // locale-preferred
    null).description("ed244c06-07fe-102c-b5fa-0017a47871b2", "Patient's partner is in prison.", Locale.ENGLISH).mapping(new ConceptMapBuilder("759ed92a-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "PARTNER IN PRISON").build()).mapping(new ConceptMapBuilder("b25d1bb8-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "3346").build()).build());
    Concept married = install(new ConceptBuilder(Concepts.MARRIED).datatype(notApplicable).conceptClass(finding).name("3e3ffcb2-26fe-102b-80cb-0017a47871b2", "Married", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("90c02968-5164-4e97-ab01-db80aa9e0d56", "Marié(e)", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("cca6224b-3f11-4f7a-b9c8-ac1b784e6c77", "Marye", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed18a7d4-07fe-102c-b5fa-0017a47871b2", "Wedded to another person.", Locale.ENGLISH).mapping(new ConceptMapBuilder("75a9a0ee-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MARRIED").build()).mapping(new ConceptMapBuilder("b295eca4-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5555").build()).build());
    Concept livingWithPartner = install(new ConceptBuilder("3cd6e96c-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e150eb2-26fe-102b-80cb-0017a47871b2", "Living with partner", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("b3a05960-796f-4565-bd44-7dc6331d2d51", "Placé(e)", Locale.FRENCH, // locale-preferred
    null).name("c7510c67-cc7a-4cc5-85fc-12c98cb44b00", "Cohabitant avec le partenaire", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("14a425c9-30dc-4cfb-a23f-23b2e8fdcdda", "Concubine", Locale.FRENCH, null).name("aeb288a7-21af-4800-b972-196adcdd3f14", "Plase", locale_HAITI, // locale-preferred
    null).name("80341f66-14da-4a9a-a03f-f8a0ef3e52c4", "Ap viv ak patnè", locale_HAITI, ConceptNameType.FULLY_SPECIFIED).name("6843ccc2-a24e-4671-aa07-4f89dfd49345", "Konkibinaj", locale_HAITI, null).description("ece42e00-07fe-102c-b5fa-0017a47871b2", "Answer which describes a type of civil status.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b20d081c-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1060").build()).mapping(new ConceptMapBuilder("75688186-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "LIVING WITH PARTNER").build()).build());
    install(new ConceptBuilder(Concepts.CIVIL_STATUS).datatype(coded).conceptClass(question).name("3e15049e-26fe-102b-80cb-0017a47871b2", "Civil status", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b8ec5fe-15f5-102d-96e4-000c29c2a5d7", "CIV_STAT", Locale.ENGLISH, ConceptNameType.SHORT).name("f5c82c18-d5db-102d-ad2a-000c29c2a5d7", "État civil", Locale.FRENCH, // locale-preferred
    null).description("ece42496-07fe-102c-b5fa-0017a47871b2", "More detailed description of the following encounter form question:  \"Are you currently married or living with a partner?\"", Locale.ENGLISH).mapping(new ConceptMapBuilder("b20cff3e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1054").build()).mapping(new ConceptMapBuilder("6b1d3ea7-267d-4077-8b01-522489ca5a22").type(sameAs).ensureTerm(pih, "CIVIL STATUS").build()).mapping(new ConceptMapBuilder("db9aa56a-d4be-11e4-9dcf-b36e1005e77b").type(sameAs).ensureTerm(ciel, "1054").build()).answers(separated, neverMarried, divorced, widowed, livingWithPartner, married, partnerInPrison, singleOrChild, celibate, unknown, otherNonCoded).build());
    uninstall(MetadataUtils.possible(Concept.class, "94807725-b1cf-437e-b439-c5885440121e"), "No longer used");
    uninstall(MetadataUtils.possible(Concept.class, "3cd9786c-26fe-102b-80cb-0017a47871b2"), "No longer used");
    uninstall(MetadataUtils.possible(Concept.class, "1ed2c51d-7d4d-44df-9257-48eaf61a2f7a"), "No longer used");
    uninstall(MetadataUtils.possible(Concept.class, "a2c0bdcf-f4ba-4e10-9af4-d9ad7dcc2ca4"), "No longer using too sick");
    uninstall(MetadataUtils.possible(Concept.class, "96fa6038-30b0-4305-a4ce-0a392a0081c6"), "Small child is not occupation");
    uninstall(MetadataUtils.possible(Concept.class, "b866af07-d583-4d0c-9861-f00e90677042"), "Employed should be coded or other");
    Concept housework = install(new ConceptBuilder("3cda14e8-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e19c6d2-26fe-102b-80cb-0017a47871b2", "Housework", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b8eb1cc-15f5-102d-96e4-000c29c2a5d7", "Housewife", Locale.ENGLISH, null).name("0b8eb0dc-15f5-102d-96e4-000c29c2a5d7", "Domestic", Locale.ENGLISH, null).name("0b8eb2c6-15f5-102d-96e4-000c29c2a5d7", "Ménage", Locale.FRENCH, // locale-preferred
    null).description("ece86506-07fe-102c-b5fa-0017a47871b2", "A main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("b211809a-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1404").build()).build());
    Concept commerce = install(new ConceptBuilder("3cd9740c-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e17c01c-26fe-102b-80cb-0017a47871b2", "Commerce", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b8e937c-15f5-102d-96e4-000c29c2a5d7", "Commerçant", Locale.FRENCH, // locale-preferred
    null).description("ece769da-07fe-102c-b5fa-0017a47871b2", "Main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("b21086fe-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1305").build()).mapping(new ConceptMapBuilder("1f575f52-3942-4430-87a6-35841a024aed").type(sameAs).ensureTerm(pih, "COMMERCE").build()).build());
    Concept houseworkAndFieldwork = install(new ConceptBuilder("3ce40fca-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e252a68-26fe-102b-80cb-0017a47871b2", "Housework/Fieldwork", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("f695e1ee-d5db-102d-ad2a-000c29c2a5d7", "Ménage/Travail de terrain", Locale.FRENCH, // locale-preferred
    null).description("ecf278fc-07fe-102c-b5fa-0017a47871b2", "It's very common (especially in Lesotho) for patients to respond to the main activity question with both housework and fieldwork", Locale.ENGLISH).mapping(new ConceptMapBuilder("75955cd8-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "HOUSEWORK/FIELDWORK").build()).mapping(new ConceptMapBuilder("b255fa68-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2445").build()).build());
    Concept factoryWorker = install(new ConceptBuilder("3cdcbe78-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1d53f6-26fe-102b-80cb-0017a47871b2", "Factory worker", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f6326b1e-d5db-102d-ad2a-000c29c2a5d7", "Ouvrier", Locale.FRENCH, // locale-preferred
    null).description("ecec0c9c-07fe-102c-b5fa-0017a47871b2", "Factory profession or activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("b214b972-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1683").build()).mapping(new ConceptMapBuilder("75776d2c-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FACTORY WORKER").build()).build());
    Concept professional = install(new ConceptBuilder("907716b4-1852-404a-9ee1-beff998f9461").datatype(notApplicable).conceptClass(misc).name("0b76dd22-15f5-102d-96e4-000c29c2a5d7", "Professional", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f7039220-d5db-102d-ad2a-000c29c2a5d7", "Professionnel", Locale.FRENCH, // locale-preferred
    null).description("ed24d0b8-07fe-102c-b5fa-0017a47871b2", "Employment type. Examples are nurse, doctor, teacher, lawyer, or any position outside of agriculture. ", Locale.ENGLISH).mapping(new ConceptMapBuilder("759f2222-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "PROFESSIONAL").build()).mapping(new ConceptMapBuilder("b25d6690-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "3396").build()).build());
    Concept brewer = install(new ConceptBuilder("3cdcc2ec-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1d5838-26fe-102b-80cb-0017a47871b2", "Brewer", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f632b696-d5db-102d-ad2a-000c29c2a5d7", "Brasseur", Locale.FRENCH, // locale-preferred
    null).description("ecec12a0-07fe-102c-b5fa-0017a47871b2", "Brewery profession or activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75777182-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "BREWER").build()).mapping(new ConceptMapBuilder("b214be18-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1686").build()).build());
    Concept teacher = install(new ConceptBuilder("d192f132-999a-4666-8725-028f9fcb8df4").datatype(notApplicable).conceptClass(misc).name("15cddbff-47a3-4bde-8c49-fafa448af031", "Teacher", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("9a35a067-c03a-45da-93b5-5979e8e363bf", "Professor", Locale.ENGLISH, null).name("d774632c-d77a-4181-aa08-c171f0e2afd1", "Professeur", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("84998026-5282-4b20-9f7c-a320448740ca", "Professeur d'école", Locale.FRENCH, null).description("65f4f023-905a-491f-ab52-c136274da38c", "Main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("e1f4236c-ef7c-4be3-be0e-42a6813ce4fe").type(sameAs).ensureTerm(pih, "7098").build()).mapping(new ConceptMapBuilder("ad56aac5-34a9-484f-927b-a04737a9aadd").type(sameAs).ensureTerm(pih, "Teacher").build()).build());
    Concept retired = install(new ConceptBuilder("3ce4113c-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e252bd0-26fe-102b-80cb-0017a47871b2", "Retired", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f695fd3c-d5db-102d-ad2a-000c29c2a5d7", "Retraité", Locale.FRENCH, // locale-preferred
    null).description("ecf27a5a-07fe-102c-b5fa-0017a47871b2", "A main activity for someone who has retired from work", Locale.ENGLISH).mapping(new ConceptMapBuilder("75955e54-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "RETIRED").build()).mapping(new ConceptMapBuilder("b255fbda-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2446").build()).build());
    Concept farmer = install(new ConceptBuilder("3cd9757e-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e17c26a-26fe-102b-80cb-0017a47871b2", "Farmer", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f5ff6d22-d5db-102d-ad2a-000c29c2a5d7", "Fermier", Locale.FRENCH, // locale-preferred
    null).name("3e17c4cc-26fe-102b-80cb-0017a47871b2", "Cultivateur", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).description("ece76be2-07fe-102c-b5fa-0017a47871b2", "Main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75715ef0-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FARMER").build()).mapping(new ConceptMapBuilder("b2108898-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1306").build()).build());
    Concept shopOwner = install(new ConceptBuilder("3cdcc468-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1d59be-26fe-102b-80cb-0017a47871b2", "Shop owner", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f632cfbe-d5db-102d-ad2a-000c29c2a5d7", "Propriétaire de la boutique", Locale.FRENCH, // locale-preferred
    null).description("ecec149e-07fe-102c-b5fa-0017a47871b2", "Shop owner profession or activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("b214bf94-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1687").build()).mapping(new ConceptMapBuilder("757772ea-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SHOP OWNER").build()).build());
    Concept manualLaborer = install(new ConceptBuilder("3cd995ae-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e181328-26fe-102b-80cb-0017a47871b2", "Manual laborer", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f6023714-d5db-102d-ad2a-000c29c2a5d7", "Main-d'œuvre", Locale.FRENCH, // locale-preferred
    null).description("ece7a468-07fe-102c-b5fa-0017a47871b2", "An occupation or main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("b210a81e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1326").build()).mapping(new ConceptMapBuilder("7571791c-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MANUAL LABORER").build()).build());
    Concept driver = install(new ConceptBuilder("f15d07f0-be62-44d4-89ef-0e17e0aa480e").datatype(notApplicable).conceptClass(misc).name("0b75e93a-15f5-102d-96e4-000c29c2a5d7", "Driver", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b829374-15f5-102d-96e4-000c29c2a5d7", "Chauffeur", Locale.ENGLISH, null).name("f6fe3eba-d5db-102d-ad2a-000c29c2a5d7", "Chauffeur", Locale.FRENCH, // locale-preferred
    null).description("ed244954-07fe-102c-b5fa-0017a47871b2", "Employment Activity ", Locale.ENGLISH).mapping(new ConceptMapBuilder("b25d18a2-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "3344").build()).mapping(new ConceptMapBuilder("759ed664-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "DRIVER").build()).build());
    Concept student = install(new ConceptBuilder("3cd976f0-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e17c724-26fe-102b-80cb-0017a47871b2", "Student", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("3e17c97c-26fe-102b-80cb-0017a47871b2", "Étudiant", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ece76fc0-07fe-102c-b5fa-0017a47871b2", "Main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75716076-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "STUDENT").build()).mapping(new ConceptMapBuilder("b2108a1e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1307").build()).build());
    Concept miner = install(new ConceptBuilder("3cdcbd06-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1d5284-26fe-102b-80cb-0017a47871b2", "Miner", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f63251e2-d5db-102d-ad2a-000c29c2a5d7", "Mineur", Locale.FRENCH, // locale-preferred
    null).description("ecec0aa8-07fe-102c-b5fa-0017a47871b2", "Miner profession or activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75776bce-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MINER").build()).mapping(new ConceptMapBuilder("b214b7e2-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1682").build()).build());
    Concept unemployed = install(new ConceptBuilder("3cd979de-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e17d098-26fe-102b-80cb-0017a47871b2", "Unemployed", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f5ffd816-d5db-102d-ad2a-000c29c2a5d7", "Sans emploi", Locale.FRENCH, // locale-preferred
    null).name("3e17d318-26fe-102b-80cb-0017a47871b2", "Chômage", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).description("ece77768-07fe-102c-b5fa-0017a47871b2", "Main activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75716364-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "UNEMPLOYED").build()).mapping(new ConceptMapBuilder("b2108d2a-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1309").build()).build());
    Concept fruitOrVegetableSeller = install(new ConceptBuilder("3cdcbff4-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1d555e-26fe-102b-80cb-0017a47871b2", "Fruit or vegetable vendor", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("9563f9b4-07d4-102c-b5fa-0017a47871b2", "Produce seller", Locale.ENGLISH, null).name("f632845a-d5db-102d-ad2a-000c29c2a5d7", "Vendeur de fruits ou de légumes", Locale.FRENCH, // locale-preferred
    null).description("ecec0e9a-07fe-102c-b5fa-0017a47871b2", "Fruit/Veggie seller profession or activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75776e8a-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FRUIT OR VEGETABLE SELLER").build()).mapping(new ConceptMapBuilder("b214baee-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1684").build()).build());
    Concept shepherd = install(new ConceptBuilder("3cdcc170-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1d56d0-26fe-102b-80cb-0017a47871b2", "Shepherd", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f6329d64-d5db-102d-ad2a-000c29c2a5d7", "Berger", Locale.FRENCH, // locale-preferred
    null).description("ecec1098-07fe-102c-b5fa-0017a47871b2", "Shepherd profession or activity", Locale.ENGLISH).mapping(new ConceptMapBuilder("75777024-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SHEPHERD").build()).mapping(new ConceptMapBuilder("b214bc60-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1685").build()).build());
    Concept fisherman = install(new ConceptBuilder("159674AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("107067BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Fisherman", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("b543fde8-54a7-4a8d-ae75-c792708fc731", "Pêcheur", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("16315FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "occupation", Locale.ENGLISH).mapping(new ConceptMapBuilder("216817ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "159674").build()).mapping(new ConceptMapBuilder("136442ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "106400003").build()).mapping(new ConceptMapBuilder("136443ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(ampath, "6401").build()).build());
    Concept marketVendor = install(new ConceptBuilder("162945AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("a1272096-c77b-4e9e-9516-930f31ffd199", "Market vendor", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("75f8b7d4-e8a1-42e3-84a1-cb0ff968e693", "Vendeur de marché", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("a062c2e8-f589-11e4-b9b2-1697f925ec7b").type(sameAs).ensureTerm(ciel, "162945").build()).build());
    Concept civilServant = install(new ConceptBuilder("162944AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("5f085cf9-1819-499e-b809-f9f790b7f589", "Civil servant", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("9cae05a1-be90-4703-aca6-6488815bf107", "Fonctionnaire", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("a062c7a2-f589-11e4-b9b2-1697f925ec7b").type(sameAs).ensureTerm(ciel, "162944").build()).build());
    Concept healthCareWorker = install(new ConceptBuilder("3cdbc91e-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1b1fdc-26fe-102b-80cb-0017a47871b2", "Health care worker", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("367d3538-9f67-45b2-ab98-34107ce442e3", "Membre du service de santé", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("3dd47072-ffe8-47c8-aa5a-7db571be4e20", "Travailleur de soins de santé", Locale.FRENCH, null).description("ecea574e-07fe-102c-b5fa-0017a47871b2", "A person that works to provide health care. This includes but is not limited to physicians, nurses, health promoters and DOT workers.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b2133e44-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1538").build()).mapping(new ConceptMapBuilder("75769a96-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "HEALTH CARE WORKER").build()).build());
    Concept zlStaff = install(new ConceptBuilder("87cced76-131d-487d-bc5e-50d902c0d1e8").datatype(notApplicable).conceptClass(misc).name("da6c974e-86b0-45fa-bf78-d7a9371507b9", "ZL employee", Locale.ENGLISH, // locale-preferred
    null).name("b286eb9a-4e74-47b1-9e57-34df62b57d54", "Zanmi Lasante employee", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("3f28ec50-3251-47a2-abc8-6c4a565cd2fc", "ZL staff", Locale.ENGLISH, null).name("7d306f1b-0896-4f2d-8267-6fd32043e3dd", "Employé de ZL", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("13d7d1c8-ead6-4240-a28c-91cf6193c6bd", "ZL anplwaye", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("5b9577ac-4b26-4a6c-afdc-08eb50c7814c", "An employee of Zanmi Lasante", Locale.ENGLISH).mapping(new ConceptMapBuilder("31afa0a7-2599-4f8c-8a21-fd992591f465").type(sameAs).ensureTerm(pih, "10741").build()).mapping(new ConceptMapBuilder("c84a233f-996a-4d7c-b9b3-78a537348163").type(sameAs).ensureTerm(pih, "Zanmi Lasante employee").build()).build());
    install(new ConceptBuilder(Concepts.MAIN_ACTIVITY).datatype(coded).conceptClass(question).name("3e17bb4e-26fe-102b-80cb-0017a47871b2", "Main activity", Locale.ENGLISH, // locale-preferred
    null).name("0b8ec22a-15f5-102d-96e4-000c29c2a5d7", "Job", Locale.ENGLISH, null).name("0b9562d8-15f5-102d-96e4-000c29c2a5d7", "Principal activity", Locale.ENGLISH, null).name("0b8ec130-15f5-102d-96e4-000c29c2a5d7", "Occupation", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("0b8ec40a-15f5-102d-96e4-000c29c2a5d7", "Activité principale", Locale.FRENCH, // locale-preferred
    null).description("ece767dc-07fe-102c-b5fa-0017a47871b2", "The main activity or job the patient is engaged in", Locale.ENGLISH).mapping(new ConceptMapBuilder("d311dd1a-b42f-4263-b230-ae9a9b41ab60").type(sameAs).ensureTerm(pih, "Occupation").build()).mapping(new ConceptMapBuilder("b210855a-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1304").build()).answers(farmer, manualLaborer, shepherd, brewer, shopOwner, fruitOrVegetableSeller, miner, factoryWorker, housework, houseworkAndFieldwork, driver, professional, commerce, teacher, fisherman, marketVendor, civilServant, healthCareWorker, zlStaff, retired, student, unemployed, otherNonCoded).build());
    // start religion question and answers
    Concept vodou = install(new ConceptBuilder("162930AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("0fb9b669-e4cf-4215-a4b7-05810077135f", "Voodoo", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127110BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Vaudou", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127111BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Vodou", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("22adced2-1242-4088-83d3-18d6a0cc485e").type(sameAs).ensureTerm(pih, "Voodoo").build()).mapping(new ConceptMapBuilder("21b83615-c9cb-4b93-a835-db85f473a26c").type(sameAs).ensureTerm(ciel, "162930").build()).mapping(new ConceptMapBuilder("96576ffe-f61a-40e8-b9e1-9246fce7dd5f").type(sameAs).ensureTerm(snomedCt, "44399006").build()).build());
    Concept catholic = install(new ConceptBuilder("162931AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("d60f7743-8010-4366-b1a2-67419cb26449", "Catholic", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127114BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Catholique", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127115BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Katolik", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("9c053a48-19ee-4964-8240-c4ba0d163df7").type(sameAs).ensureTerm(pih, "Catholic").build()).mapping(new ConceptMapBuilder("eda8d7a6-08de-4214-ba8b-6feedfd914c1").type(sameAs).ensureTerm(ciel, "162931").build()).mapping(new ConceptMapBuilder("09f579a5-31fa-4282-accc-904ff7bc6f63").type(sameAs).ensureTerm(snomedCt, "276120001").build()).build());
    Concept baptist = install(new ConceptBuilder("1162932AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("acb83b74-09ac-41c5-9d77-9846bee4bd60", "Baptist", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127119BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Baptiste", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127117BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Batis", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("39b96e32-bfed-4ab2-bf31-07d6c0b8cff8").type(sameAs).ensureTerm(pih, "Baptist").build()).mapping(new ConceptMapBuilder("2b52c6ce-d16b-492d-a0fb-0782b277026f").type(sameAs).ensureTerm(ciel, "162932").build()).mapping(new ConceptMapBuilder("4252ad9e-b29e-4deb-bd12-ebdf4923727a").type(sameAs).ensureTerm(snomedCt, "32617004").build()).build());
    Concept islam = install(new ConceptBuilder("162933AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("27fd8d35-310f-4d8b-973c-3b973e6523d4", "Islam", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127122BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Musulman", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127123BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Mizilman", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("a1bb3862-f245-4aaf-ae73-be56f186808f").type(sameAs).ensureTerm(pih, "Islam").build()).mapping(new ConceptMapBuilder("6c5a0151-b600-47e8-ab31-c4f46a009d3b").type(sameAs).ensureTerm(ciel, "162933").build()).mapping(new ConceptMapBuilder("3a42c0ca-0052-434d-bd66-3a31af455012").type(sameAs).ensureTerm(snomedCt, "271390004").build()).build());
    Concept pentecostal = install(new ConceptBuilder("162934AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("649229d4-fb09-4f73-9a47-89e9a99a11ed", "Pentecostal", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127125BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Pentecôtiste", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127127BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Pentkotist", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("3088f507-6835-4c3e-864d-d26b020009fe").type(sameAs).ensureTerm(pih, "Pentecostal").build()).mapping(new ConceptMapBuilder("3811e396-86e3-4fc6-a6f2-d1f24f4318b3").type(sameAs).ensureTerm(ciel, "162934").build()).mapping(new ConceptMapBuilder("dbee5d5f-4915-45d4-b858-00b64ce88731").type(sameAs).ensureTerm(snomedCt, "309862000").build()).build());
    Concept adventist = install(new ConceptBuilder("162935AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("3e47ed11-8d82-466f-82d8-43643ff2923d", "Seventh Day Adventist", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127132BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Adventist", Locale.ENGLISH, null).name("127131BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Adventiste", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127129BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Advantis", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("e7cc2548-e3ea-4892-bc9c-5ba27ba4be4e").type(sameAs).ensureTerm(pih, "Seventh Day Adventist").build()).mapping(new ConceptMapBuilder("b011c46f-0641-4fec-8e47-c5147daa9b92").type(sameAs).ensureTerm(ciel, "162935").build()).mapping(new ConceptMapBuilder("37950a05-3d5a-4375-a676-5d7b9fa48092").type(sameAs).ensureTerm(snomedCt, "298024007").build()).build());
    Concept jehovahsWitness = install(new ConceptBuilder("162936AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("58714a23-6ccf-4816-848b-376862ea86cf", "Jehovah's Witness", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127134BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Témoin de Jéhovah", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127133BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Temwen Jewova", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("c30fc279-7197-4dcc-b2f0-3ed4e80b7f37").type(sameAs).ensureTerm(pih, "Jehovah's Witness").build()).mapping(new ConceptMapBuilder("d98888d2-b834-4b21-a48b-14d83a798cef").type(sameAs).ensureTerm(ciel, "162936").build()).mapping(new ConceptMapBuilder("66f53d55-44b1-4061-a8a1-82bf12f63fe0").type(sameAs).ensureTerm(snomedCt, "276118004").build()).build());
    install(new ConceptBuilder(Concepts.RELIGION).datatype(coded).conceptClass(question).name("1ad1706a-1400-428e-8b99-0d8b073e1a81", "Religion", Locale.ENGLISH, // locale-preferred
    null).name("9050b9ef-96d4-484a-9ca3-a21451d305a8", "Religious affiliation", Locale.ENGLISH, null).name("127108BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Religion", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("127109BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Relijyon", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("10281d23-9f19-487c-a0c3-adde06c6d46b").type(sameAs).ensureTerm(pih, "Religion").build()).mapping(new ConceptMapBuilder("668e0a10-841c-42a4-a394-c706319bb341").type(sameAs).ensureTerm(ciel, "162929").build()).mapping(new ConceptMapBuilder("47714808-2ffb-4ed9-986d-b0810c6ff4a0").type(sameAs).ensureTerm(snomedCt, "160538000").build()).answers(vodou, catholic, baptist, islam, pentecostal, adventist, jehovahsWitness, otherNonCoded).build());
    // end religion question and answers
    // start contacts questions and answers
    Concept namesAndFirstnamesOfContact = install(new ConceptBuilder(Concepts.NAMES_AND_FIRSTNAMES_OF_CONTACT).datatype(text).conceptClass(question).name("3e1817e2-26fe-102b-80cb-0017a47871b2", "The names of a contact of a patient", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("b210a990-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1327").build()).mapping(new ConceptMapBuilder("75717a7a-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "NAMES AND FIRSTNAMES OF CONTACT").build()).build());
    Concept relationshipsOfContact = install(new ConceptBuilder(Concepts.RELATIONSHIPS_OF_CONTACT).datatype(text).conceptClass(question).name("3e181c9c-26fe-102b-80cb-0017a47871b2", "Relationships of contact to patient", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("b210ab02-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1328").build()).mapping(new ConceptMapBuilder("75717bec-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "RELATIONSHIPS OF CONTACT").build()).build());
    Concept telephoneNumberOfContact = install(new ConceptBuilder(Concepts.TELEPHONE_NUMBER_OF_CONTACT).datatype(text).conceptClass(question).name("441d28cf-bbfc-407e-a007-efa91f303d5b", "The phone number for the patient's contact", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("b2adaa88-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "6194").build()).mapping(new ConceptMapBuilder("75ad601c-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "TELEPHONE NUMBER OF CONTACT").build()).build());
    Concept addressOfContact = install(new ConceptBuilder(Concepts.ADDRESS_OF_CONTACT).datatype(text).conceptClass(question).name("A7D167A-1B39-4DE9-8BE7-F3980FBE366F", "The address for the patient's contact", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("20535d6a-eac7-459d-b607-6befe23d9c3a", "Concept to store the address of a patient's contact as free text", Locale.ENGLISH).mapping(new ConceptMapBuilder("18636437-061A-4DA8-87D7-F345F8E8C638").type(sameAs).ensureTerm(pih, "ADDRESS OF PATIENT CONTACT").build()).build());
    install(new ConceptBuilder(Concepts.PATIENT_CONTACTS_CONSTRUCT).datatype(notApplicable).conceptClass(convSet).name("640cbd4d-d2d2-4ccb-9fe6-a76698ba324a", "Questions on contacts of the patient", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ece7a288-07fe-102c-b5fa-0017a47871b2", "Questions on contacts of the patient", Locale.ENGLISH).mapping(new ConceptMapBuilder("757177b4-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "PATIENT CONTACTS CONSTRUCT").build()).mapping(new ConceptMapBuilder("b210a6ac-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1325").build()).setMembers(namesAndFirstnamesOfContact, relationshipsOfContact, telephoneNumberOfContact, addressOfContact, address1, address2, address3, cityVillage, stateProvince, country).build());
// end contacts question and answers
}
Also used : Concept(org.openmrs.Concept) ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Aggregations

ConceptBuilder (org.openmrs.module.metadatadeploy.builder.ConceptBuilder)12 ConceptMapBuilder (org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)12 Concept (org.openmrs.Concept)10 ConceptClass (org.openmrs.ConceptClass)2 ConceptDatatype (org.openmrs.ConceptDatatype)2 ConceptMapType (org.openmrs.ConceptMapType)2 ConceptSource (org.openmrs.ConceptSource)2 ConceptNumericBuilder (org.openmrs.module.metadatadeploy.builder.ConceptNumericBuilder)2