public Class<?> resolveClass(BundleInstantiationSpecification spec) {
        Bundle bundle = getBundle(spec.bundle);
        if (bundle != null) {
            return resolveFromBundle(spec, bundle);
        } else {
            if (jdiscOsgi.isFelixFramework() && ! spec.bundle.equals(spec.classId)) {
                // Bundle was explicitly specified, but not found.
                throw new IllegalArgumentException("Could not find bundle " + spec.bundle + " to create a component with class '"
                                                     + spec.classId.getName() + ". " + bundleResolutionErrorMessage(spec.bundle));
            }
            return resolveFromThisBundleOrSystemBundle(spec);
        }
    }
@author Tony Vaagenes
@author bratseth
@author gjoranv
container-core/src/main/java/com/yahoo/osgi/OsgiImpl.java