public VBox call() throws Exception {
if (!target.exists() && !target.mkdirs())
throw new IllegalStateException(target + " does not exit and cannot create");
final VBox box = new VBox(context, resource.toURI());
for (String f : ImmutableSet.<String>builder()
.addAll(Arrays.asList("MediaRegistry.xml", "VirtualBox.xml", "Manifest.xml", "Provisioning.xml", "Profile.xml"))
.addAll(box.getManifest().getFile()).build()) {
FileUtils.copyURLToFile(getClass().getResource("/" + templateName + "/" + f), new File(target, f));
}
LOGGER.info("created " + target);
return new VBox(context, target.toURI());
}