org.jvnet.hk2.osgiadapter
Class OSGiDirectoryBasedRepository
java.lang.Object
com.sun.enterprise.module.common_impl.AbstractRepositoryImpl
com.sun.enterprise.module.common_impl.DirectoryBasedRepository
org.jvnet.hk2.osgiadapter.OSGiDirectoryBasedRepository
- All Implemented Interfaces:
- Repository
public class OSGiDirectoryBasedRepository
- extends DirectoryBasedRepository
Only OSGi bundles are recognized as modules.
- Author:
- Sanjeeb.Sahoo@Sun.COM
| Methods inherited from class com.sun.enterprise.module.common_impl.AbstractRepositoryImpl |
add, addLibrary, find, findAll, findAll, getJarLocations, getLocation, getName, initialize, remove, removeLibrary, removeListener, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
OSGiDirectoryBasedRepository
public OSGiDirectoryBasedRepository(java.lang.String name,
java.io.File repository)
OSGiDirectoryBasedRepository
public OSGiDirectoryBasedRepository(java.lang.String name,
java.io.File repository,
boolean isTimerThreadDaemon)
loadJar
protected ModuleDefinition loadJar(java.io.File jar)
throws java.io.IOException
- This class overrides this mthod, because we don't support the following cases:
1. external manifest.mf file for a jar file
2. jar file exploded as a directory.
Both the cases are supported in HK2, but not in OSGi.
- Overrides:
loadJar in class AbstractRepositoryImpl
- Parameters:
jar - bundle jar
- Returns:
- a ModuleDefinition for this bundle
- Throws:
java.io.IOException
newModuleDefinition
protected ModuleDefinition newModuleDefinition(java.io.File jar,
java.util.jar.Attributes attr)
throws java.io.IOException
- Overrides:
newModuleDefinition in class AbstractRepositoryImpl
- Throws:
java.io.IOException
Copyright © 2011 Oracle Corporation. All Rights Reserved.