Skip to content

4. Containercreationalgorithm

Andreas Schörk edited this page Nov 1, 2018 · 9 revisions

Find initial set of classes used to start the Standalone-Weld-Container

Leveled creation

  1. Given Initial set of classes IC
    • Identify Set of Managed Beans MB in IC
    • Find Producers PMB in MB
    • Find Injects INJ_MB in MB
    • Identify Not fillable Injects EMPTYI in INJ_MB
    • Identify Injects AMBIG_INJ in INJ_MB filled by more than one
    • Identify Set of Candidates to Add
      • Added Elements ADDED_MB by @Additional* - Annotation with Producers P_ADDED_MB
      • Superclasses which could be managed beans SCMB in MB with Producers PSCMB
      • Elements EMPTYIMB of EMPTYI which can be managed Beans (not interfaces, not abstract)
    • For each I in EMPTYI
      • Find candidates to fill
        • if there is one class which would fill add this to NEW_IC
        • if there is more than one
          • prefer ADDED_MB over SCMB over EMPTYIMB
          • if not unique producing yet --> _ADDED_MB is not

Clone this wiki locally