private void copyBootClasspathLibraries(File karafHome, ExamSystem subsystem) throws MalformedURLException,
IOException {
BootClasspathLibraryOption[] bootClasspathLibraryOptions =
subsystem.getOptions(BootClasspathLibraryOption.class);
for (BootClasspathLibraryOption bootClasspathLibraryOption : bootClasspathLibraryOptions) {
UrlReference libraryUrl = bootClasspathLibraryOption.getLibraryUrl();
FileUtils.copyURLToFile(
new URL(libraryUrl.getURL()),
createFileNameWithRandomPrefixFromUrlAtTarget(libraryUrl.getURL(), new File(karafHome + "/lib"),
new String[]{ "jar" }));
}
}