Uploaded image for project: 'OpenMRS Core'
  1. OpenMRS Core
  2. TRUNK-165

Remove Need for ConceptSet Manipulation from API

    XMLWordPrintable

Details

    • New Feature
    • Status: Closed
    • Should
    • Resolution: Fixed
    • None
    • OpenMRS 1.7.0
    • None
    • None
    • Undetermined

    Description

      Currently ConceptSet is treated and exposed like any other domain object. We want to hide this behind the API.

      Add a method to the Concept class to get direct (immediate) members of a set like:

      if (concept.isSet())
        List<Concept> concept.getMembers();
      

      and add a method to ConceptService to get all members (turning any child sets into their members):

      if (concept.isSet))
        List<Concept> Context.getConceptService()
          .getAllConceptMembers(concept);
      

      Nowhere does the API consumer need to know or be concerned about ConceptSet. ConceptSet disappears from the API (domain objects and service methods). Whether or not concept_set_derived is used becomes an internal performance issue hidden within the API.

      Decided on this dev call.

      Gliffy Diagrams

        Attachments

          1. openmrs_1921_added_new_api_methods.patch
            13 kB
          2. openmrs-1921.patch
            4 kB
          3. openmrs-1921-3.patch
            13 kB

          Activity

            People

              zabilcm Zabil C.M [X] (Inactive)
              burke Burke Mamlin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: