Search in sources :

Example 16 with ConceptMapBuilder

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

the class AllergyConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    Concept mentalStatusChange = install(new ConceptBuilder("121677AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(diagnosis).name("127084BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Mental status change", Locale.ENGLISH, // locale-preferred
    null).name("21808BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Altered Mental Status", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("80786BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Estado mental alterado", locale_SPANISH, // locale-preferred
    null).mapping(new ConceptMapBuilder("95967ABBBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(icd10who, "F99").build()).mapping(new ConceptMapBuilder("266979ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(imoProblemIT, "72276").build()).mapping(new ConceptMapBuilder("70242ABBBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "419284004").build()).mapping(new ConceptMapBuilder("185768ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "121677").build()).build());
    Concept angioedema = install(new ConceptBuilder("148787AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(diagnosis).name("48406BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Angioedema", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("108627BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Angio-edema", Locale.ENGLISH, null).name("57589BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "angioedema", locale_SPANISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("15145FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "Recurring attacks of transient edema suddenly appearing in areas of the skin or mucous membranes and occasionally of the viscera, often associated with dermatographism, urticaria, erythema, and purpura.", Locale.ENGLISH).mapping(new ConceptMapBuilder("275558ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(pih, "1298").build()).mapping(new ConceptMapBuilder("275431ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(icd10who, "T78.3").build()).mapping(new ConceptMapBuilder("276324ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(imoProblemIT, "38248").build()).mapping(new ConceptMapBuilder("46884ABBBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "41291007").build()).mapping(new ConceptMapBuilder("276265ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "148787").build()).build());
    Concept bronchospasm = install(new ConceptBuilder("108AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(symptom).name("123BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Bronchospasm", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("107FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "A contraction of smooth muscle in the walls of the bronchi and bronchioles, causing narrowing of the lumen.", Locale.ENGLISH).mapping(new ConceptMapBuilder("272108ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(imoProblemIT, "522535").build()).mapping(new ConceptMapBuilder("133655ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "4386001").build()).mapping(new ConceptMapBuilder("171007ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "108").build()).mapping(new ConceptMapBuilder("133970ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "108").build()).build());
    Concept arrhythmia = install(new ConceptBuilder("120148AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(diagnosis).name("100604BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Arrhythmia", Locale.ENGLISH, // locale-preferred
    null).name("126137BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Cardiac arrhythmia", Locale.ENGLISH, null).name("20357BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Cardiac Dysrhythmia", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("81689BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Trastorno de conducción cardíaca", locale_SPANISH, // locale-preferred
    null).description("5924FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "Any variation from the normal rhythm or rate of the heart beat.", Locale.ENGLISH).mapping(new ConceptMapBuilder("275573ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(pih, "3310").build()).mapping(new ConceptMapBuilder("71169ABBBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "698247007").build()).mapping(new ConceptMapBuilder("276636ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(imoProblemIT, "38620").build()).mapping(new ConceptMapBuilder("275675ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "1530").build()).mapping(new ConceptMapBuilder("276126ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "120148").build()).mapping(new ConceptMapBuilder("275497ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(icd10who, "I49.9").build()).build());
    install(new ConceptBuilder(Concepts.ALLERGY_REACTIONS_SET).datatype(notApplicable).conceptClass(convSet).name("4c886be0-04c1-11e5-8418-1697f925ec7b", "PIH Core allergic reactions", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("4c886d52-04c1-11e5-8418-1697f925ec7b", "A convenience set to allow for easy selection of common allergic reactions", Locale.ENGLISH).setMembers(arrhythmia, bronchospasm, angioedema, mentalStatusChange).build());
    // Drug allergy
    Concept morphine = install(new ConceptBuilder("80106AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(drug).name("6837BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Morphine", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("94904BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "MST Continus", Locale.ENGLISH, null).name("97722BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Roxanol", Locale.ENGLISH, null).name("97433BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Rescudose", Locale.ENGLISH, null).name("91169BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Duromorph", Locale.ENGLISH, null).name("95276BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Nepenthe", Locale.ENGLISH, null).name("97723BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Roxanol UD", Locale.ENGLISH, null).name("97256BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Rapi-Ject", Locale.ENGLISH, null).name("94254BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "M-Eslon", Locale.ENGLISH, null).name("97602BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "RMS", Locale.ENGLISH, null).name("90413BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Demerol", Locale.ENGLISH, null).name("94900BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "MS Contin", Locale.ENGLISH, null).name("98025BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Sevredol", Locale.ENGLISH, null).name("94963BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "MXL brand of morphine sulfate", Locale.ENGLISH, null).name("97724BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Roxanol-T", Locale.ENGLISH, null).name("94873BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Morcap SR", Locale.ENGLISH, null).name("95796BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Oramorph", Locale.ENGLISH, null).name("88383BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Avinza", Locale.ENGLISH, null).name("100439BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Zomorph", Locale.ENGLISH, null).name("91133BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Duramorph PF", Locale.ENGLISH, null).name("94902BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "MSIR", Locale.ENGLISH, null).name("90466BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Depodur", Locale.ENGLISH, null).name("93576BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Kadian", Locale.ENGLISH, null).name("95797BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Oramorph SR", Locale.ENGLISH, null).name("88282BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Astramorph PF", Locale.ENGLISH, null).name("95707BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "OMS", Locale.ENGLISH, null).name("93316BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Infumorph", Locale.ENGLISH, null).name("94901BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "MS/S", Locale.ENGLISH, null).name("95708BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "OMS brand of Morphine Sulfate", Locale.ENGLISH, null).mapping(new ConceptMapBuilder("130406ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(rxNorm, "7052").build()).mapping(new ConceptMapBuilder("138961ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "73572009").build()).mapping(new ConceptMapBuilder("175991ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "80106").build()).mapping(new ConceptMapBuilder("145370ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(snomedNp, "373529000").build()).build());
    install(new ConceptBuilder(Concepts.ALLERGENS_DRUG_SET).datatype(notApplicable).conceptClass(convSet).name("4c886fbe-04c1-11e5-8418-1697f925ec7b", "PIH Core drug allergies", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("4c8870f4-04c1-11e5-8418-1697f925ec7b", "A convenience set to allow for easy selection of common drug allergies", Locale.ENGLISH).setMembers(morphine).build());
    // Food allergy
    Concept peanuts = install(new ConceptBuilder("162172AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("124965BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Peanuts", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("17166FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "A food often causing allergic reactions", Locale.ENGLISH).mapping(new ConceptMapBuilder("237195ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162172").build()).mapping(new ConceptMapBuilder("237194ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "256349002").build()).build());
    install(new ConceptBuilder(Concepts.ALLERGENS_FOOD_SET).datatype(notApplicable).conceptClass(convSet).name("4c887338-04c1-11e5-8418-1697f925ec7b", "PIH Core food allergens", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("4c8876bc-04c1-11e5-8418-1697f925ec7b", "A convenience set to allow for easy selection of common food allergens", Locale.ENGLISH).setMembers(peanuts).build());
    // Environment allergen
    Concept beeSting = install(new ConceptBuilder("162536AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("127083BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Bee stings", Locale.ENGLISH, // locale-preferred
    null).name("126208BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Sting of bee", Locale.ENGLISH, null).name("126138BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Bee venom", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("277720ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162536").build()).mapping(new ConceptMapBuilder("277719ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "288328004").build()).build());
    install(new ConceptBuilder(Concepts.ALLERGENS_ENVIRONMENT_SET).datatype(notApplicable).conceptClass(convSet).name("4c887928-04c1-11e5-8418-1697f925ec7b", "PIH Core environmental allergens", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("4c887a4a-04c1-11e5-8418-1697f925ec7b", "A convenience set to allow for easy selection of common environmental allergens", Locale.ENGLISH).setMembers(beeSting).build());
    // Levels of severity
    Concept fatal = install(new ConceptBuilder("25b286a2-584b-4bbb-bb8b-558db9684c7a").datatype(notApplicable).conceptClass(misc).name("718228c4-7824-40f6-93a8-9f7e439c01e7", "Fatal", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("cb8ec00c-df19-435f-926f-302ef54c9ff6", "Fatal", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("0f2780f0-a543-102e-a00e-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FATAL").build()).mapping(new ConceptMapBuilder("278367ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "399166001").build()).mapping(new ConceptMapBuilder("278368ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162819").build()).mapping(new ConceptMapBuilder("cf1bfb76-a542-102e-a00e-000c29c2a5d7").type(sameAs).ensureTerm(pih, "7059").build()).build());
    Concept severe = install(new ConceptBuilder(Concepts.ALLERGY_SEVERITY_SEVERE).datatype(notApplicable).conceptClass(finding).name("0b6342d0-15f5-102d-96e4-000c29c2a5d7", "Severe", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("93b806dc-07d4-102c-b5fa-0017a47871b2", "Severe", Locale.ENGLISH, ConceptNameType.SHORT).name("cc2e71b8-1cba-4ef4-9cd6-97e2efa93f0c", "Sévère", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("96a55fca-c66b-4bda-9f10-fb0ec126994d", "Grav", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("16229FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "General qualifier value for the severity assesment", Locale.ENGLISH).mapping(new ConceptMapBuilder("171742ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "1500").build()).mapping(new ConceptMapBuilder("7578d19e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SEVERE").build()).mapping(new ConceptMapBuilder("135122ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "1745").build()).mapping(new ConceptMapBuilder("132651ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "24484000").build()).mapping(new ConceptMapBuilder("b21e7624-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1903").build()).build());
    Concept mild = install(new ConceptBuilder(Concepts.ALLERGY_SEVERITY_MILD).datatype(notApplicable).conceptClass(finding).name("0b6340dc-15f5-102d-96e4-000c29c2a5d7", "Mild", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("93b7febc-07d4-102c-b5fa-0017a47871b2", "Mild", Locale.ENGLISH, ConceptNameType.SHORT).name("caac4020-4fc6-4584-83e0-668177b00a77", "Bénin", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("16227FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "General qualifier value", Locale.ENGLISH).mapping(new ConceptMapBuilder("171740ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "1498").build()).mapping(new ConceptMapBuilder("7578ce42-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MILD").build()).mapping(new ConceptMapBuilder("135120ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "1743").build()).mapping(new ConceptMapBuilder("132650ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "255604002").build()).mapping(new ConceptMapBuilder("b21e72fa-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1901").build()).build());
    Concept moderate = install(new ConceptBuilder(Concepts.ALLERGY_SEVERITY_MODERATE).datatype(notApplicable).conceptClass(finding).name("0b633fa6-15f5-102d-96e4-000c29c2a5d7", "Moderate", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("93b7fa98-07d4-102c-b5fa-0017a47871b2", "Moderate", Locale.ENGLISH, ConceptNameType.SHORT).name("14d2181c-0275-42c8-90e4-f6bc914becad", "Modéré", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("d2fac9a8-b710-4ed7-9f3b-466a48ecaca5", "Modere", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("16228FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "General qualifier value of the severity", Locale.ENGLISH).mapping(new ConceptMapBuilder("b21e7142-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1900").build()).mapping(new ConceptMapBuilder("135121ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ampath, "1744").build()).mapping(new ConceptMapBuilder("171741ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "1499").build()).mapping(new ConceptMapBuilder("133261ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "6736007").build()).mapping(new ConceptMapBuilder("7578ccbc-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MODERATE").build()).build());
    Concept lifeThreatening = install(new ConceptBuilder("162693AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(misc).name("126526BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Life threatening severity", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("278076ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "442452003").build()).mapping(new ConceptMapBuilder("278077ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162693").build()).build());
    install(new ConceptBuilder("162760AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(coded).conceptClass(question).name("126624BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Severity of adverse reaction", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("278208ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "162760").build()).mapping(new ConceptMapBuilder("278369ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(snomedNp, "405162009").build()).answers(lifeThreatening, moderate, mild, severe).build());
}
Also used : Concept(org.openmrs.Concept) ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Example 17 with ConceptMapBuilder

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

the class ClinicalConsultationConcepts method installSexualActivity.

private void installSexualActivity(Concept other, Concept notApplicableConcept, Concept none) {
    install(new ConceptBuilder(Concepts.SEXUALLY_ACTIVE).datatype(booleanDatatype).conceptClass(question).name("3e38494a-26fe-102b-80cb-0017a47871b2", "SEXUALLY ACTIVE", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("9566bc8a-07d4-102c-b5fa-0017a47871b2", "SEXUAL ACTIVITY", Locale.ENGLISH, null).name("f6b929d8-d5db-102d-ad2a-000c29c2a5d7", "SEXUELLEMENT ACTIF", Locale.FRENCH, // locale-preferred
    null).name("3e384abc-26fe-102b-80cb-0017a47871b2", "ACTIF SEXUELLEMENT", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("b2583508-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2730").build()).mapping(new ConceptMapBuilder("759aaf12-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "SEXUALLY ACTIVE").build()).build());
    Concept iud = install(new ConceptBuilder("3ceb4d4e-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e3d0ef8-26fe-102b-80cb-0017a47871b2", "Intrauterine device", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("94adecd2-07d4-102c-b5fa-0017a47871b2", "IUCD", Locale.ENGLISH, null).name("94ae023a-07d4-102c-b5fa-0017a47871b2", "IUD", Locale.ENGLISH, null).name("1c1163ae-3643-4bd4-8cf2-1d948fd6ffdf", "Dispositif intra-utérin", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed14ddde-07fe-102c-b5fa-0017a47871b2", "A device (as a spiral of plastic or a ring of stainless steel) inserted and left in the uterus to prevent effective conception.", Locale.ENGLISH).mapping(new ConceptMapBuilder("75a805c2-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "INTRAUTERINE DEVICE").build()).mapping(new ConceptMapBuilder("b293ae12-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5275").build()).build());
    Concept norplant = install(new ConceptBuilder("3cdcf2e4-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(drug).name("7dcf6221-8df5-43ca-a800-fa6c2a9c362e", "Levonorgestrel", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("73c4b9d8-2d3e-494e-b4ce-4493212a4be3", "Microlut", Locale.ENGLISH, null).name("d8b4a143-ec63-412e-b9e0-e90842297b85", "Norplant system", Locale.ENGLISH, null).name("1d91ee71-7b2c-4857-b28e-eb45f446d18f", "Norplant", Locale.ENGLISH, null).name("7a09813f-6fbe-4067-9713-082575c6db13", "Plan B", Locale.ENGLISH, null).name("f638c3a6-d5db-102d-ad2a-000c29c2a5d7", "Implant contraceptif sous-cutané", Locale.FRENCH, // locale-preferred
    null).description("ecec44dc-07fe-102c-b5fa-0017a47871b2", "Norplant is 99% – 99.95% effective at preventing pregnancy, and is one of the most reliable, though not the most available, forms of birth control.", Locale.ENGLISH).mapping(new ConceptMapBuilder("d8f77ed9-da09-4dc7-9fb8-48d7ef3d65a6").type(sameAs).ensureTerm(ciel, "78796").build()).mapping(new ConceptMapBuilder("5b8cbd41-72e3-427b-b4ca-7d0c419bf5f1").type(sameAs).ensureTerm(rxNorm, "6373").build()).mapping(new ConceptMapBuilder("b214ee6a-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1718").build()).mapping(new ConceptMapBuilder("3a080495-6d56-4c3a-87db-8e90e44af37f").type(sameAs).ensureTerm(snomedCt, "109032009").build()).mapping(new ConceptMapBuilder("7577a260-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "NORPLANT").build()).build());
    Concept tubalLigation = install(new ConceptBuilder("3cdcf44c-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(procedure).name("10f365da-77c7-4b8f-978f-d6fd70ca1a70", "Tubal ligation", Locale.ENGLISH, // locale-preferred
    null).name("b618d501-3e46-4675-9d4f-9b6bab969778", "BTL", Locale.ENGLISH, null).name("33bdfbec-b51b-4b1a-8cef-26ecab94fcc6", "Bilateral tubal ligation", Locale.ENGLISH, null).name("7e556285-9204-4597-ac88-3e5d189a8599", "Ligation of fallopian tube", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("a0e32650-51c5-4eac-90af-a1ff035112f3", "Ligature des trompes", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("626b553b-bd87-4246-8485-b11a23f3f72c", "Interruption de la perméabilité des trompes utérines", Locale.FRENCH, null).name("2e08cd66-97df-40c7-a931-f5ec63a7954b", "Ligature des trompes", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("e739c2b4-4da3-4051-a8af-4f05d8c6cc06", "Interruption de la perméabilité des trompes utérines", locale_HAITI, null).name("0351252e-ac54-4647-be21-2b11c9efd33c", "Ligature", locale_HAITI, null).description("ecec4720-07fe-102c-b5fa-0017a47871b2", "The surgical procedure in fallopian tube to prevent pregnancy, a method of female sterilization.", Locale.ENGLISH).mapping(new ConceptMapBuilder("f13a3fbf-039c-469f-9e2d-1636ac790c4b").type(sameAs).ensureTerm(ciel, "1472").build()).mapping(new ConceptMapBuilder("7577a3c8-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "TUBAL LIGATION").build()).mapping(new ConceptMapBuilder("5a6d1d4b-c337-4b7a-8a4d-a6d13d47c3ca").type(sameAs).ensureTerm(snomedCt, "77543007").build()).mapping(new ConceptMapBuilder("10b160ee-2af7-47cb-86da-e69a94bbac69").type(sameAs).ensureTerm(imoProblemIT, "674775").build()).mapping(new ConceptMapBuilder("b214efe6-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1719").build()).build());
    Concept vasectomy = install(new ConceptBuilder("3cdcf74e-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(procedure).name("3e1ded66-26fe-102b-80cb-0017a47871b2", "Vasectomy", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("590b51b8-bced-4228-9ae3-5d7e4c8f289c", "Vasectomie", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("bed6486a-14cf-40da-b87d-da56368e55af", "Vasectomie", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecec49fa-07fe-102c-b5fa-0017a47871b2", "A method of male sterilization.", Locale.ENGLISH).mapping(new ConceptMapBuilder("7577a68e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "VASECTOMY").build()).mapping(new ConceptMapBuilder("1e2d18d2-f79f-4ed0-9bb4-13510b3f77f5").type(sameAs).ensureTerm(snomedCt, "22523008").build()).mapping(new ConceptMapBuilder("b214f2ca-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1721").build()).build());
    Concept depoProvera = install(new ConceptBuilder("3cd5094e-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(drug).name("93f47c52-07d4-102c-b5fa-0017a47871b2", "Depo-provera", Locale.ENGLISH, // locale-preferred
    null).name("3e12ebd2-26fe-102b-80cb-0017a47871b2", "Medroxyprogesterone acetate", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("93f48134-07d4-102c-b5fa-0017a47871b2", "Depoprovera", Locale.ENGLISH, null).name("f5b210fe-d5db-102d-ad2a-000c29c2a5d7", "Acétate de médroxyprogestérone", Locale.FRENCH, // locale-preferred
    null).description("ece19d16-07fe-102c-b5fa-0017a47871b2", "A synthetic steroid progestational hormone C24H34O4 that is used especially in the treatment of amenorrhea and abnormal uterine bleeding, in conjunction with conjugated estrogens to relieve the symptoms of menopause and to prevent osteoporosis, and as an injectable contraceptive.", Locale.ENGLISH).mapping(new ConceptMapBuilder("753e08ac-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "MEDROXYPROGESTERONE ACETATE").build()).mapping(new ConceptMapBuilder("b20b077e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "907").build()).build());
    Concept injectableContraceptives = install(new ConceptBuilder("3ceb5532-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(medSet).name("3e3d14d4-26fe-102b-80cb-0017a47871b2", "Injectable contraceptives", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("94acfcbe-07d4-102c-b5fa-0017a47871b2", "Injectable hormones", Locale.ENGLISH, null).name("f75c6936-d5db-102d-ad2a-000c29c2a5d7", "Contraception injectable", Locale.FRENCH, // locale-preferred
    null).description("ed14e5fe-07fe-102c-b5fa-0017a47871b2", "Injectable medicines which enable deliberate prevention of conception or impregnation.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b293b3ee-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5279").build()).mapping(new ConceptMapBuilder("75a80b4e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "INJECTABLE CONTRACEPTIVES").build()).setMembers(depoProvera).build());
    Concept diaphragm = install(new ConceptBuilder("3ceb52ee-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e3d1362-26fe-102b-80cb-0017a47871b2", "Diaphragm", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("93f0eede-07d4-102c-b5fa-0017a47871b2", "Cervical cap", Locale.ENGLISH, null).name("f75c360a-d5db-102d-ad2a-000c29c2a5d7", "Diaphragme", Locale.FRENCH, // locale-preferred
    null).description("ed14e3f6-07fe-102c-b5fa-0017a47871b2", "A molded cap, usually of thin rubber fitted over the uterine cervix to act as a mechanical contraceptive barrier.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b293b27c-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5278").build()).mapping(new ConceptMapBuilder("75a809f0-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "DIAPHRAGM").build()).build());
    Concept femaleSterilization = install(new ConceptBuilder("3ceb4ee8-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(procedure).name("3e3d106a-26fe-102b-80cb-0017a47871b2", "Female sterilization", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("eb6352dc-c830-4445-aeea-fcc3889c2110", "Stérilisation féminine", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("13274c1b-296c-4e77-b414-1affc41bdc0e", "Stérilisation féminine", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed14dfe6-07fe-102c-b5fa-0017a47871b2", "Permanent methods of family planning in which surgical procedure is done in female genital system to prevent pregnancy. Examples include tubal ligation, laparoscopic sterilization, salpingectomy and others", Locale.ENGLISH).mapping(new ConceptMapBuilder("e6187cdf-c3fd-4049-bfce-a69ec38e648c").type(sameAs).ensureTerm(snomedCt, "60890002").build()).mapping(new ConceptMapBuilder("b293af8e-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5276").build()).mapping(new ConceptMapBuilder("75a8072a-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "FEMALE STERILIZATION").build()).build());
    Concept condoms = install(new ConceptBuilder("3cce7a20-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(drug).name("3e0ba5ac-26fe-102b-80cb-0017a47871b2", "Condoms", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("3e0ba7dc-26fe-102b-80cb-0017a47871b2", "Preservatifs", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecd8bee4-07fe-102c-b5fa-0017a47871b2", "Methods for preventing pregnancy.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b1d9c59c-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "190").build()).mapping(new ConceptMapBuilder("50e1752c-3105-49a5-b0da-4d7926d45ecd").type(sameAs).ensureTerm(pih, "CONDOMS").build()).build());
    Concept oralContraception = install(new ConceptBuilder("3cd42786-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(medSet).name("3e11e0a2-26fe-102b-80cb-0017a47871b2", "Oral contraception", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("93ee52e6-07d4-102c-b5fa-0017a47871b2", "Birth control pills", Locale.ENGLISH, null).name("f5a61cc2-d5db-102d-ad2a-000c29c2a5d7", "Contraception orale", Locale.FRENCH, // locale-preferred
    null).description("ece05fa0-07fe-102c-b5fa-0017a47871b2", "Female contraception method.  Ultimately will make a good MedSet.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b2094a24-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "780").build()).mapping(new ConceptMapBuilder("7512366e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "ORAL CONTRACEPTION").build()).build());
    Concept naturalFamilyPlanning = install(new ConceptBuilder("3ceb5082-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e3d11dc-26fe-102b-80cb-0017a47871b2", "Natural family planning", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("956506b0-07d4-102c-b5fa-0017a47871b2", "Rhythm method", Locale.ENGLISH, null).name("f75c072a-d5db-102d-ad2a-000c29c2a5d7", "Planification familiale naturelle", Locale.FRENCH, // locale-preferred
    null).description("ed14e1e4-07fe-102c-b5fa-0017a47871b2", "A method of birth control that involves abstention from sexual intercourse during the period of ovulation which is determined through observation and measurement of bodily signs (as cervical mucus and body temperature).", Locale.ENGLISH).mapping(new ConceptMapBuilder("75a80888-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "NATURAL FAMILY PLANNING").build()).mapping(new ConceptMapBuilder("b293b100-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "5277").build()).build());
    Concept abstinence = install(new ConceptBuilder("3cdcf5e6-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(misc).name("3e1deafa-26fe-102b-80cb-0017a47871b2", "Abstinence", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("f63907c6-d5db-102d-ad2a-000c29c2a5d7", "Abstinence", Locale.FRENCH, // locale-preferred
    null).description("ecec487e-07fe-102c-b5fa-0017a47871b2", "Method of preventing pregnancy (fill in)", Locale.ENGLISH).mapping(new ConceptMapBuilder("b214f158-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1720").build()).mapping(new ConceptMapBuilder("7577a526-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "ABSTINENCE").build()).build());
    Concept sterilization = install(new ConceptBuilder("3ce69f06-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(procedure).name("3e381628-26fe-102b-80cb-0017a47871b2", "Sterilization", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("a385063c-968d-4d0d-98b4-6057ed3cd289", "Stérilisation", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("40cef535-d33c-44b2-98bc-6c9f9dd3fb2e", "Stérilizasyon", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecf52c8c-07fe-102c-b5fa-0017a47871b2", "Surgery to make person infertile.  This is used for procedure, but also used for diagnosis.  Not sure if this should be 2 concepts.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b2581abe-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2712").build()).mapping(new ConceptMapBuilder("759a9388-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "STERILIZATION").build()).build());
    Concept hysterectomy = install(new ConceptBuilder("159837AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(procedure).name("107314BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Hysterectomy", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("6a1b1a46-8008-4338-b8f5-89c879483ae7", "Hystérectomie", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("098475be-0055-4ca3-a255-78710f5ac755", "Hystérectomie", locale_HAITI, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("16408FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "A surgical procedure in which uterus is removed.", Locale.ENGLISH).mapping(new ConceptMapBuilder("216979ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "159837").build()).mapping(new ConceptMapBuilder("136767ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "236886002").build()).mapping(new ConceptMapBuilder("136768ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(narrowerThan).ensureTerm(ampath, "5276").build()).mapping(new ConceptMapBuilder("274526ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(imoProcedureIT, "667244").build()).build());
    install(new ConceptBuilder("3ccfbd0e-26fe-102b-80cb-0017a47871b2").datatype(coded).conceptClass(question).name("3e0d6c2a-26fe-102b-80cb-0017a47871b2", "Method of family planning", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("94b6ceba-07d4-102c-b5fa-0017a47871b2", "Method of birth control", Locale.ENGLISH, null).name("b24c6e61-98c4-4842-a7bc-9e6f30c89a8e", "Méthode de planification familiale", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("b1e2124c-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "374").build()).mapping(new ConceptMapBuilder("748ee136-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "METHOD OF FAMILY PLANNING").build()).answers(none, notApplicableConcept, abstinence, condoms, oralContraception, injectableContraceptives, diaphragm, iud, femaleSterilization, tubalLigation, vasectomy, hysterectomy, norplant, depoProvera, sterilization, naturalFamilyPlanning, other).build());
    install(new ConceptBuilder("9dc4818d-049b-4a39-bf3c-69b12ea18f34").datatype(text).conceptClass(question).name("0b6aea8a-15f5-102d-96e4-000c29c2a5d7", "Other family planning method, non-coded", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("7af5c5e1-b695-4773-a591-d63118a463bd", "Autre méthode de planification familiale (texte)", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ed1fe0bc-07fe-102c-b5fa-0017a47871b2", "Free-text to describe family planning method.", Locale.ENGLISH).mapping(new ConceptMapBuilder("759c3a9e-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "OTHER FAMILY PLANNING METHOD, NON-CODED").build()).mapping(new ConceptMapBuilder("b25a31a0-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "2996").build()).build());
}
Also used : Concept(org.openmrs.Concept) ConceptBuilder(org.openmrs.module.metadatadeploy.builder.ConceptBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Example 18 with ConceptMapBuilder

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

the class TestOrderConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    install(new ConceptNumericBuilder(Concepts.HEMATOCRIT).units("%").precise(true).hiNormal(50.0).lowAbsolute(0.0).lowNormal(35.0).datatype(numeric).conceptClass(test).name("3e148d20-26fe-102b-80cb-0017a47871b2", "Hematocrit", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("94b8dc5a-07d4-102c-b5fa-0017a47871b2", "Packed cell volume", Locale.ENGLISH, null).name("0b7ba816-15f5-102d-96e4-000c29c2a5d7", "Hct", Locale.ENGLISH, ConceptNameType.SHORT).name("93f3926a-07d4-102c-b5fa-0017a47871b2", "CRIT", Locale.ENGLISH, null).name("0b851fb8-15f5-102d-96e4-000c29c2a5d7", "HCT", Locale.ENGLISH, null).name("9562d11a-07d4-102c-b5fa-0017a47871b2", "PCV", Locale.ENGLISH, null).name("e552c9d0-a77e-4d89-8936-522d9fa0f06c", "Hématocrite", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ece3785c-07fe-102c-b5fa-0017a47871b2", "Percent of whole blood that is composed of red blood cells.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b20c2adc-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "1015").build()).mapping(new ConceptMapBuilder("75683d52-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "HEMATOCRIT").build()).mapping(new ConceptMapBuilder("c8d1d90d-ac94-4a03-8515-664fcd1d9f89").type(sameAs).ensureTerm(loinc, "20570-8").build()).build());
    install(new ConceptNumericBuilder(Concepts.HEMOGLOBIN).units("g/dl").precise(true).hiAbsolute(20.0).lowAbsolute(2.0).lowNormal(11.5).datatype(numeric).conceptClass(test).name("3e09b800-26fe-102b-80cb-0017a47871b2", "Hemoglobin", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("0b853dd6-15f5-102d-96e4-000c29c2a5d7", "HGB", Locale.ENGLISH, null).name("94aa1e22-07d4-102c-b5fa-0017a47871b2", "Hb", Locale.ENGLISH, null).name("0b7b1982-15f5-102d-96e4-000c29c2a5d7", "Hb", Locale.ENGLISH, ConceptNameType.SHORT).name("c90bd06f-0bda-48b9-8968-0614743602e8", "Hémoglobine", Locale.FRENCH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).description("ecd675d0-07fe-102c-b5fa-0017a47871b2", "The iron-containing respiratory pigment in red blood cells of vertebrates, consisting of about 6 percent heme and 94 percent globin.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b1c14288-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "21").build()).mapping(new ConceptMapBuilder("c3e2d313-086e-445f-9fe5-2e5715903a1e").type(sameAs).ensureTerm(loinc, "718-7").build()).mapping(new ConceptMapBuilder("73800682-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "HEMOGLOBIN").build()).build());
}
Also used : ConceptNumericBuilder(org.openmrs.module.metadatadeploy.builder.ConceptNumericBuilder) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)

Example 19 with ConceptMapBuilder

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

the class VaccinationConcepts method installNewVersion.

@Override
protected void installNewVersion() throws Exception {
    Concept vaccinationGiven = install(new ConceptBuilder("2dc6c690-a5fe-4cc4-97cc-32c70200a2eb").conceptClass(convSet).datatype(coded).name("1034BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Immunizations", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("107784BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Vaccinations", Locale.ENGLISH, null).description("986FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "Captures an immunization that has been administered to the patient, either before or during the encounter containing an observation of this concept.", Locale.ENGLISH).mapping(new ConceptMapBuilder("133795ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "33879002").build()).mapping(new ConceptMapBuilder("171250ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "984").build()).build());
    Concept vaccinationDate = install(new ConceptBuilder("1410AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").conceptClass(finding).datatype(date).name("1565BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Vaccination date", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("107781BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Immunization date", Locale.ENGLISH, null).name("86865BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Vaccination date", Locale.ENGLISH, ConceptNameType.SHORT).name("1566BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Date de vaccination", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("1567BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "tarehe ya kupewa chanjo/Kinga", locale_SWAHILI, ConceptNameType.FULLY_SPECIFIED).description("1379FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF", "The full date of a vaccination", Locale.ENGLISH).mapping(new ConceptMapBuilder("171662ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "1410").build()).build());
    Concept vaccinationSequenceNumber = install(// our copy of CIEL:1418
    new ConceptNumericBuilder("ef6b45b4-525e-4d74-bf81-a65a41f3feb9").conceptClass(finding).datatype(numeric).lowAbsolute(0d).precise(false).name("1577BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Immunization sequence number", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("107783BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Vaccination sequence number", Locale.ENGLISH, null).name("86873BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "immunization no", Locale.ENGLISH, ConceptNameType.SHORT).name("1578BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Numéro des vaccinations", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("171670ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "1418").build()).build());
    Concept vaccinationConstruct = install(// CIEL:1421, but with fewer answers
    new ConceptBuilder("74260088-9c83-41d5-b92b-03a41654daaf").conceptClass(finding).datatype(notApplicable).name("1585BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Immunization history", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("107785BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "vaccination history", Locale.ENGLISH, null).name("107786BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "vaccination hx", Locale.ENGLISH, null).name("86876BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "immunization hx", Locale.ENGLISH, ConceptNameType.SHORT).name("1586BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Historique vaccinale", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).name("110133BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB", "Historia ya Chanjo", locale_SWAHILI, ConceptNameType.FULLY_SPECIFIED).description("921f5876-a0fc-47a0-bd0f-ff818c5c1c9c", "Vaccations that this patient has already received (in the past or in the current visit)", Locale.ENGLISH).setMembers(vaccinationGiven, vaccinationSequenceNumber, vaccinationDate).mapping(new ConceptMapBuilder("136923ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(snomedCt, "425457005").build()).mapping(new ConceptMapBuilder("171673ABBBBBBBBBBBBBBBBBBBBBBBBBBBBB").type(sameAs).ensureTerm(ciel, "1421").build()).build());
    install(new ConceptBuilder("3cd4e004-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(procedure).name("93ee06ce-07d4-102c-b5fa-0017a47871b2", "BCG vaccine", Locale.ENGLISH, // locale-preferred
    null).name("3e12ca08-26fe-102b-80cb-0017a47871b2", "BACILLE CAMILE-GUERIN VACCINATION", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("9388e7c6-07d4-102c-b5fa-0017a47871b2", "BCG", Locale.ENGLISH, ConceptNameType.SHORT).name("93edfd82-07d4-102c-b5fa-0017a47871b2", "BCG", Locale.ENGLISH, null).name("f5b02afa-d5db-102d-ad2a-000c29c2a5d7", "VACCINATION DU BACILLE DE CALMETTE-GUÉRIN", Locale.FRENCH, // locale-preferred
    null).description("ece17228-07fe-102c-b5fa-0017a47871b2", "Deactivated tuberculous agent as basis for tuberculosis vaccination.", Locale.ENGLISH).mapping(new ConceptMapBuilder("b20a68dc-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "886").build()).mapping(new ConceptMapBuilder("753c8888-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "BACILLE CAMILE-GUERIN VACCINATION").build()).build());
    install(new ConceptBuilder("3cd42c36-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(procedure).name("3e11e7dc-26fe-102b-80cb-0017a47871b2", "Oral polio vaccination", Locale.ENGLISH, // locale-preferred
    ConceptNameType.FULLY_SPECIFIED).name("94b884e4-07d4-102c-b5fa-0017a47871b2", "ORAL POLIO VAX NO.3", Locale.ENGLISH, null).name("95636e22-07d4-102c-b5fa-0017a47871b2", "POLIO VAX NO.0", Locale.ENGLISH, null).name("95637ad4-07d4-102c-b5fa-0017a47871b2", "POLIO VAX NO.3", Locale.ENGLISH, null).name("9563721e-07d4-102c-b5fa-0017a47871b2", "POLIO VAX NO.1", Locale.ENGLISH, null).name("95637692-07d4-102c-b5fa-0017a47871b2", "POLIO VAX NO.2", Locale.ENGLISH, null).name("94b877d8-07d4-102c-b5fa-0017a47871b2", "ORAL POLIO VAX NO.0", Locale.ENGLISH, null).name("94b88048-07d4-102c-b5fa-0017a47871b2", "ORAL POLIO VAX NO.2", Locale.ENGLISH, null).name("94b87c1a-07d4-102c-b5fa-0017a47871b2", "ORAL POLIO VAX NO.1", Locale.ENGLISH, null).name("f5a682a2-d5db-102d-ad2a-000c29c2a5d7", "VACCINATION ORALE ANTIPOLIOMYÉLITE", Locale.FRENCH, // locale-preferred
    null).description("ece065ae-07fe-102c-b5fa-0017a47871b2", "Vaccination given for polio.", Locale.ENGLISH).mapping(new ConceptMapBuilder("8ad98af3-e438-4b7a-b667-922854aad62e").type(sameAs).ensureTerm(pih, "ORAL POLIO VACCINATION").build()).mapping(new ConceptMapBuilder("b2094e98-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "783").build()).build());
    // from OCL
    install(new ConceptBuilder("1423AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(drug).name("8ab170aa2be7433ab50e0e9ccd81369a", "PENTAVALENT PNEUMOVAX", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("878025f9e4d7428b9cbea96d8cf62558", "pneumovax", Locale.ENGLISH, ConceptNameType.SHORT).name("af7039b37b384238b51dca3446a506f5", "IMMUNIZATION, PENTAVALENT PNEUMOVAX", Locale.ENGLISH, null).name("73a0cb5b858d4234a8073704233c5efe", "VACCINATION, PENTAVALENT PNEUMOVAX", Locale.ENGLISH, null).mapping(new ConceptMapBuilder("553069d350d61b02e14f3c77").type(sameAs).ensureTerm(ciel, "1423").build()).mapping(new ConceptMapBuilder("19e25e62-cf4e-324e-9c07-0c0d56de6274").type(sameAs).ensureTerm(snomedCt, "12866006").build()).build());
    // from OCL
    install(new ConceptBuilder("83531AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(drug).name("9ea2957f48e645c48e95795db69130e1", "ROTAVIRUS VACCINE, LIVE", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("55306ca550d61b02e14f6cf7").type(sameAs).ensureTerm(ciel, "83531").build()).mapping(new ConceptMapBuilder("39edda7a-16fc-3e5a-ab41-38cb4874bed1").type(sameAs).ensureTerm(rxNorm, "253199").build()).build());
    // from OCL
    install(new ConceptBuilder("162586AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA").datatype(notApplicable).conceptClass(drug).name("406627b252a9401a86b143fa53f323f1", "Measles-Rubella vaccine", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("b0cb25bd523746998434cf4ad6751d2c", "rubeole-rougeole vaccine", Locale.FRENCH, ConceptNameType.FULLY_SPECIFIED).mapping(new ConceptMapBuilder("5530b2fd50d61b02e150bc8d").type(sameAs).ensureTerm(ciel, "162586").build()).build());
    install(new ConceptBuilder("3ccc6b7c-26fe-102b-80cb-0017a47871b2").datatype(notApplicable).conceptClass(drug).name("956a4d6e-07d4-102c-b5fa-0017a47871b2", "TD BOOSTER", Locale.ENGLISH, null).name("3e09b26a-26fe-102b-80cb-0017a47871b2", "DIPTHERIA TETANUS BOOSTER", Locale.ENGLISH, ConceptNameType.FULLY_SPECIFIED).name("f560f962-d5db-102d-ad2a-000c29c2a5d7", "INJECTION DE RAPPEL: DIPTHÉRIE TÉTANOS ", Locale.FRENCH, // locale-preferred
    null).description("ecd66e50-07fe-102c-b5fa-0017a47871b2", "Vaccination against diptheria and tetanus (IM).", Locale.ENGLISH).mapping(new ConceptMapBuilder("b1c13504-4864-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "17").build()).mapping(new ConceptMapBuilder("737fedbe-4943-102e-96e9-000c29c2a5d7").type(sameAs).ensureTerm(pih, "DIPTHERIA TETANUS BOOSTER").build()).build());
// how to handle "Others" for vaccinations
}
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 20 with ConceptMapBuilder

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

the class ConceptsFromMetadataSharing method baseConcept.

private Concept baseConcept(String name) {
    Concept concept = new Concept();
    concept.addName(new ConceptName(name, Locale.ENGLISH));
    concept.addConceptMapping(new ConceptMapBuilder(uuid()).type(sameAs).ensureTerm(pih, name).build());
    return concept;
}
Also used : Concept(org.openmrs.Concept) ConceptMapBuilder(org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder) ConceptName(org.openmrs.ConceptName)

Aggregations

ConceptMapBuilder (org.openmrs.module.metadatadeploy.builder.ConceptMapBuilder)25 Concept (org.openmrs.Concept)21 ConceptBuilder (org.openmrs.module.metadatadeploy.builder.ConceptBuilder)12 ConceptName (org.openmrs.ConceptName)4 ConceptNumericBuilder (org.openmrs.module.metadatadeploy.builder.ConceptNumericBuilder)4 ConceptClass (org.openmrs.ConceptClass)2 ConceptDatatype (org.openmrs.ConceptDatatype)2 ConceptMapType (org.openmrs.ConceptMapType)2 ConceptSource (org.openmrs.ConceptSource)2