List<Class<? extends IPlugin>> pluginClasses = new ArrayList<>();
classesInDir.stream().filter(IPlugin.class::isAssignableFrom).sequential()
.forEach(c -> pluginClasses.add((Class<? extends IPlugin>) c));
if (pluginClasses.size() + getObjects().size() > HARD_LIMIT) {
throw new TooManyPluginsException(pluginClasses.size(), HARD_LIMIT);
}
pluginClasses.forEach(this::internalPluginLoad);
}