final ScanUtil.ScanHandler scan = ScanUtil.read(scanXml);
final Archive packageArchive = packageArchive(scan.getPackages(), loader, location);
final Archive classesArchive = classesArchive(scan.getPackages(), scan.getClasses(), loader);
if (packageArchive != null && classesArchive != null) {
return new CompositeArchive(classesArchive, packageArchive);
} else if (packageArchive != null) {
return packageArchive;
}
return classesArchive;
} catch (final IOException e) {