use of org.eclipse.linuxtools.docker.core.IDockerConnectionSettingsProvider in project linuxtools by eclipse.
the class DefaultDockerConnectionSettingsFinder method getKnownConnectionSettings.
@Override
public List<IDockerConnectionSettings> getKnownConnectionSettings() {
List<IDockerConnectionSettings> result = new ArrayList<>();
IConfigurationElement[] configs = getConfigurationElements();
for (IConfigurationElement config : configs) {
try {
// $NON-NLS-1$
Object obj = config.createExecutableExtension("provider");
if (obj instanceof IDockerConnectionSettingsProvider) {
List<IDockerConnectionSettings> settings = ((IDockerConnectionSettingsProvider) obj).getConnectionSettings();
if (settings != null && !settings.isEmpty()) {
result.addAll(settings);
}
}
} catch (CoreException e) {
// continue, perhaps another configuration will succeed
}
}
return result;
}
Aggregations