Package org.apache.sling.maven.jspc.classloader

## Class DynamicClassLoaderManagerFactory

- java.lang.Object
- - org.apache.sling.maven.jspc.classloader.DynamicClassLoaderManagerFactory

    public class DynamicClassLoaderManagerFactory
    extends Object

This is the service factory for the dynamic class loader manager.

### Constructor Summary

Constructors
`DynamicClassLoaderManagerFactory​(org.osgi.framework.BundleContext ctx, org.osgi.service.packageadmin.PackageAdmin pckAdmin)` Create a new service instance

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `addUnresolvedPackage​(String pckName)` Notify that a package is not found during class loading.
`void` `addUsedBundle​(org.osgi.framework.Bundle bundle)` Notify that a bundle is used as a source for class loading.
`boolean` `hasUnresolvedPackages​(org.osgi.framework.Bundle bundle)` Check if an exported package from the bundle has not been found during previous class loading attempts.
`boolean` `isBundleUsed​(long bundleId)` Check if a bundle has been used for class loading.

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### DynamicClassLoaderManagerFactory

    public DynamicClassLoaderManagerFactory​(org.osgi.framework.BundleContext ctx,
                                            org.osgi.service.packageadmin.PackageAdmin pckAdmin)

Create a new service instance

Parameters:
  `ctx` - The bundle context.
  `pckAdmin` - The package admin.

### Method Detail

#### isBundleUsed

    public boolean isBundleUsed​(long bundleId)

Check if a bundle has been used for class loading.

Parameters:
  `bundleId` - The bundle id.
Returns:
  `true` if the bundle has been used.

#### addUsedBundle

    public void addUsedBundle​(org.osgi.framework.Bundle bundle)

Notify that a bundle is used as a source for class loading.

Parameters:
  `bundle` - The bundle.

#### addUnresolvedPackage

    public void addUnresolvedPackage​(String pckName)

Notify that a package is not found during class loading.

Parameters:
  `pckName` - The package name.

#### hasUnresolvedPackages

    public boolean hasUnresolvedPackages​(org.osgi.framework.Bundle bundle)

Check if an exported package from the bundle has not been found during previous class loading attempts.

Parameters:
  `bundle` - The bundle to check
Returns:
  `true` if a package has not be found before