result = resolveBundle(bsn, range, strategy);
else {
String pkgName = properties.get(CapabilityType.PACKAGE.getTypeName());
String modeName = properties.get(CapabilityType.MODE.getTypeName());
ResolverMode mode = (modeName != null) ? ResolverMode.valueOf(modeName) : null;
if (pkgName != null)
result = resolvePackage(pkgName, range, strategy, mode, properties);
else
throw new IllegalArgumentException("Cannot resolve bundle: neither bsn nor package specified.");