61 List<PluginDescriptor> currentPlugins =
extManager.
getPlugins().stream().filter(w -> w.getPluginState().equals(PluginState.STARTED))
62 .map(PluginWrapper::getDescriptor).collect(Collectors.toList());
68 .sorted(Comparator.comparing(aMethod -> -authnMethodLevels.get(aMethod.getAcr()))).collect(Collectors.toList());
71 for (AuthnMethod aMethod : list) {
72 String acr = aMethod.getAcr();
73 AuthnMethodStatus ams =
new AuthnMethodStatus();
75 ams.setName(Labels.getLabel(aMethod.getUINameKey()));
76 ams.setEnabled(mappedAcrs.keySet().contains(acr));
78 List<Pair<String, String>> plugins =
new ArrayList<>();
79 for (PluginDescriptor de : currentPlugins) {
80 String
id = de.getPluginId();
82 plugins.add(
new Pair<>(
id, Labels.getLabel(
"adm.method_plugin_template",
new String[] {id, de.getVersion()})));
85 if (plugins.size() == 0) {
86 plugins.add(
new Pair<>(null, Labels.getLabel(
"adm.method_sysextension")));
88 ams.setPlugins(plugins);
89 ams.setSelectedPugin(mappedAcrs.get(acr));
List< AuthnMethod > getAuthnMethodExts()
Definition: ExtensionsManager.java:180
ExtensionsManager extManager
Definition: AuthnMethodsViewModel.java:47
List< AuthnMethodStatus > methods
Definition: AuthnMethodsViewModel.java:52
ConfigurationHandler confHandler
Definition: AuthnMethodsViewModel.java:44
MainSettings getSettings()
Definition: MainViewModel.java:70
boolean pluginImplementsAuthnMethod(String acr, String plugId)
Definition: ExtensionsManager.java:155
Map< String, Integer > getAcrLevelMapping()
Definition: ConfigurationHandler.java:222
List< PluginWrapper > getPlugins()
Definition: ExtensionsManager.java:192
Map< String, String > getAcrPluginMap()
Definition: MainSettings.java:110