Package io.jmix.core

Class JmixModulesAwareBeanSelector

java.lang.Object
io.jmix.core.JmixModulesAwareBeanSelector

@Component("core_JmixModulesAwareBeanSelector") public class JmixModulesAwareBeanSelector extends Object
Helps to select a bean that belongs to the lower module in the hierarchy of @JmixModule dependencies (where core is on top and an application is at bottom).
  • Constructor Details

    • JmixModulesAwareBeanSelector

      public JmixModulesAwareBeanSelector()
  • Method Details

    • selectFrom

      @Nullable public <T> T selectFrom(Collection<T> beans)
      Returns a bean that belongs to the lower module in the hierarchy of @JmixModule dependencies.
      Parameters:
      beans - collection of beans to select from
      Returns:
      a bean instance or null if the input collection is empty