Package org.jruby.embed.osgi.internal
Class OSGiLoadService
java.lang.Object
org.jruby.runtime.load.LoadService
org.jruby.embed.osgi.internal.OSGiLoadService
Load scripts and java classes directly from the OSGi bundles.
bundle:/symbolic.name/
- Author:
- hmalphettes
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jruby.runtime.load.LoadService
LoadService.LoadPathMethods, LoadService.SuffixType -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final RubyInstanceConfig.LoadServiceCreatorFields inherited from class org.jruby.runtime.load.LoadService
extensionPattern, jarFiles, librarySearcher, loadedFeatures, loadPath, mainScript, mainScriptPath, runtime, sourcePattern -
Constructor Summary
ConstructorsConstructorDescriptionOSGiLoadService(Ruby runtime) Default constructor Optional constructor (why?) -
Method Summary
Modifier and TypeMethodDescriptionprotected LibrarySearcher.FoundLibrarycreateLibrary(String baseName, String loadName, LoadServiceResource resource) Support for 'bundle:/' to look for libraries in osgi bundles.protected LoadServiceResourcefindFileInClasspath(String name) Support for 'bundle:/' to look for libraries in osgi bundles or classes or ruby files.protected StringresolveLoadName(LoadServiceResource foundResource, String previousPath) protected LibrarySearcher.FoundLibrarysearchForLoad(String searchFile) Replaces findLibraryBySearchState but split off for load.protected LibrarySearcher.FoundLibrarysearchForRequire(String searchFile) Methods inherited from class org.jruby.runtime.load.LoadService
addPath, addPaths, addPaths, autoloadRequire, checkEmptyLoad, classpathFilenameFromURL, debugLogFound, debugLogFound, debugLogTry, featureAlreadyLoaded, featureAlreadyLoaded, findLibraryWithClassloaders, getClassPathResource, getLoadedFeatures, getLoadPath, getLoadPathEntry, getMainScript, getMainScriptPath, getPathForLocation, getWrapperSelf, init, isJarfileLibrary, isRequireable, load, load, loadFromClassLoader, provide, reflectedLoad, require, searchForRequire, setMainScript, tearDown, tryLoadingLibraryOrScript, warnCircularRequire
-
Field Details
-
OSGI_BUNDLE_CLASSPATH_SCHEME
- See Also:
-
OSGI_DEFAULT
-
-
Constructor Details
-
OSGiLoadService
Default constructor Optional constructor (why?)- Parameters:
runtime-
-
-
Method Details
-
searchForRequire
-
searchForLoad
Description copied from class:LoadServiceReplaces findLibraryBySearchState but split off for load. Needed for OSGiLoadService to override.- Overrides:
searchForLoadin classLoadService
-
findFileInClasspath
Support for 'bundle:/' to look for libraries in osgi bundles or classes or ruby files.MRI: rb_find_file
- Overrides:
findFileInClasspathin classLoadService- Parameters:
name- the file to find, this is a path name- Returns:
- the correct file
-
createLibrary
protected LibrarySearcher.FoundLibrary createLibrary(String baseName, String loadName, LoadServiceResource resource) Support for 'bundle:/' to look for libraries in osgi bundles.- Overrides:
createLibraryin classLoadService
-
resolveLoadName
- Overrides:
resolveLoadNamein classLoadService
-