Package org.kie.osgi.compiler
Class OsgiKieModule
- java.lang.Object
-
- org.drools.compiler.kie.builder.impl.AbstractKieModule
-
- org.kie.osgi.compiler.OsgiKieModule
-
- All Implemented Interfaces:
Serializable,org.drools.compiler.kie.builder.impl.InternalKieModule,org.kie.api.builder.KieModule
public class OsgiKieModule extends org.drools.compiler.kie.builder.impl.AbstractKieModule- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.drools.compiler.kie.builder.impl.InternalKieModule
org.drools.compiler.kie.builder.impl.InternalKieModule.CompilationCache, org.drools.compiler.kie.builder.impl.InternalKieModule.CompilationCacheEntry, org.drools.compiler.kie.builder.impl.InternalKieModule.LocalLogger, org.drools.compiler.kie.builder.impl.InternalKieModule.MalformedKieModuleException
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static OsgiKieModulecreate(URL url)static OsgiKieModulecreate(URL url, org.kie.api.builder.ReleaseId releaseId, org.kie.api.builder.model.KieModuleModel kieProject)static OsgiKieModulecreate(org.kie.api.builder.ReleaseId releaseId, org.kie.api.builder.model.KieModuleModel kieProject, org.osgi.framework.Bundle bundle)byte[]getBytes()byte[]getBytes(String pResourceName)longgetCreationTimestamp()FilegetFile()Collection<String>getFileNames()ClassLoadergetModuleClassLoader()org.drools.core.io.internal.InternalResourcegetResource(String fileName)booleanisAvailable(String pResourceName)static booleanisOsgiBundleUrl(String str)Determines if the provided string is OSGi bundle URL or not.static StringparseBundleId(String url)Parses OSGi bundle ID from the provided URL.StringtoString()-
Methods inherited from class org.drools.compiler.kie.builder.impl.AbstractKieModule
addDTableToCompiler, addKieDependency, addResourceToCompiler, addResourceToCompiler, buildKnowledgePackages, cacheKnowledgeBuilderForKieBase, cacheResultsForKieBase, checkStreamMode, createBuilderConfiguration, createKieBase, createResourceProvider, getClassesMap, getCompilationCache, getJarDependencies, getKieDependencies, getKieModuleModel, getKnowledgeBuilderForKieBase, getKnowledgePackagesForKieBase, getKnowledgeResultsCache, getPackage, getPomAsStream, getPomModel, getReleaseId, getResourceConfiguration, getUnresolvedDependencies, hasResource, loadResourceConfiguration, setPomModel, setUnresolvedDependencies, updateResource
-
-
-
-
Method Detail
-
getBytes
public byte[] getBytes()
-
getResource
public org.drools.core.io.internal.InternalResource getResource(String fileName)
-
isAvailable
public boolean isAvailable(String pResourceName)
-
getBytes
public byte[] getBytes(String pResourceName)
-
getModuleClassLoader
public ClassLoader getModuleClassLoader()
- Specified by:
getModuleClassLoaderin interfaceorg.drools.compiler.kie.builder.impl.InternalKieModule- Overrides:
getModuleClassLoaderin classorg.drools.compiler.kie.builder.impl.AbstractKieModule
-
getFileNames
public Collection<String> getFileNames()
-
getFile
public File getFile()
-
getCreationTimestamp
public long getCreationTimestamp()
-
create
public static OsgiKieModule create(URL url)
-
create
public static OsgiKieModule create(URL url, org.kie.api.builder.ReleaseId releaseId, org.kie.api.builder.model.KieModuleModel kieProject)
-
create
public static OsgiKieModule create(org.kie.api.builder.ReleaseId releaseId, org.kie.api.builder.model.KieModuleModel kieProject, org.osgi.framework.Bundle bundle)
-
parseBundleId
public static String parseBundleId(String url)
Parses OSGi bundle ID from the provided URL. The URL may not be coming from OSGi, in which case "null" is returned- Parameters:
url- URL- Returns:
- parsed bundle ID, or null if the url is not OSGi bundle URL
-
isOsgiBundleUrl
public static boolean isOsgiBundleUrl(String str)
Determines if the provided string is OSGi bundle URL or not.- Parameters:
str- string to check- Returns:
- true if the string is OSGi bundle URL, otherwise false
-
-